Home arrow Latest Tips
Latest Tips
Web Server Protection Against Exploits with mod_security PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Sunday, 05 February 2012
If you have problems with exploits to your web server apps (php apps for example, like phpMyAdmin, rouncube, PHPBB) then there is a sollution to those problems. An usefull tool for protecting your web server against such exploits or against spam is mod_security, a module for Apache web server.

So install on your system tje following module Apache:

  mod_security

You must install on your server Apache, mod_security module and then you must configure both.
Last Updated ( Sunday, 05 February 2012 )
 
Protect an Apache Web Server Against Spiders DDoS PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Wednesday, 07 December 2011
To protect an Apache Web Server against spiders DDoS or HTTP brute force attacks by limiting number of HTTP POSTs per second use the following Apache module:

  mod_evasive

You must install it on your Apache Web server and then configure it.
Last Updated ( Sunday, 05 February 2012 )
 
Copy Files in Linux Preserving Hard Links PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Monday, 17 October 2011
Let's say you want to move data from a partition to another, preserving hard links, for backup purpose. There's an easy way to do that with rsync -H option:

  rsync -avH /var/ /mnt/hdd_packup/

 
Benchmark a hard drive in Linux PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Friday, 14 October 2011
To benchmark a hard drive in linux we will use hdparm utility:

  hdparm -tT /dev/sda

Replace /dev/sda with your drive name. You can use this command with RAID arrays too:

  hdparm -tT /dev/md0

Last Updated ( Friday, 14 October 2011 )
 
Execute a program periodialy and see changes in output of the program PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Friday, 14 October 2011
Let's say we want to see changes from a file by executing cat periodicaly on our terminal.

In order to do that we use watch command:

  watch cat /proc/stat

This command will read /proc/stat file at every 2 seconds and will refresh/redisplay the content of /proc/stat file.
 
Install htop on CentOS Linux PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Friday, 14 October 2011
We will download htop rpm package from

  http://pkgs.repoforge.org/htop/

and we will install it:

  wget http://pkgs.repoforge.org/htop/htop-0.9-1.el6.rf.x86_64.rpm
  rpm -i htop-0.9-1.el6.rf.x86_64.rpm

If your version is 32 bit, use 32 bit package instead.

In order to install any rpm package, the rpm package must be installed first (if you know what I mean). If you do not have rpm installed, use:

  yum install rpm
Last Updated ( Friday, 14 October 2011 )
 
Kate Quick Tips PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Wednesday, 17 August 2011
Here are some usefull Kate editor quick tips:

F11 toggle on/of line numbers.
Ctrl+G go to line number (you must input line number).
Ctrl+K delete entire line.
 
Today Quick Tip: Created Files or Directories With a Particular Read-Write Permission PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Saturday, 30 April 2011
If we want for example to create some files or directories from command line and all of them to have Owner Read, Write and Execute permisions, Read and Write permisions for group and no permissions for others we will use umask command. After that command all files or directories created will have Owner= RWX,   Group=RW, Other= no rights.

  umask 017

or:

  umask u=rwx,g=rw,o=

To use proper permissions see the next table:
umask permissions
0 - read, write, execute
1 - read, write
2 - read, execute
3 - read
4 - write, execute
5 - write
6 - execute only
7 - no rights

 

Last Updated ( Saturday, 30 April 2011 )
 
Today Quick Tip: Identify your Linux Distribution PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Tuesday, 19 April 2011
To identify your linux distribution on an already installed server run a ls command:

  ls -d /etc/*release /etc/*version

If any file is found you can display it with cat:

  cat /etc/redhat-release

If you think you are on debian run:

  cat /etc/debian_version

You can also try:

  cat /proc/version
  cat /etc/issue
  cat /etc/issue.net
  cat /etc/motd
  lsb_release -a
  cat /etc/[A-Za-z]*[_-][rv]e[lr]*

Last Updated ( Tuesday, 19 April 2011 )
 
Today Quick Tip: Start a service in Ubuntu PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Wednesday, 06 April 2011

To start for example mysql server we will use service command:

  service mysql start

The old way of starting a service was:

  /etc/init.d/mysql start

(but is becoming obsolete).

 
Today Quick Tip: Change Keyboard Settings/mapping in Debian Linux PDF  
Digg Reddit Stumble Upon Facebook Twitter Google Technorati Bookmark
Friday, 18 March 2011

To change keyboard settings / mapping in Debian Linux use dpkg-reconfigure app:

dpkg-reconfigure console-data

Last Updated ( Friday, 18 March 2011 )
 

Misc

Linux Tips

Polls

What is your favorite Linux Distribution ? (we just added Mint and reset the pool data)