Linux

How to monitor log files logwatch

Logwatch installation and montoring log files

How to install logfiles in linux? How to monitor log files in linux? To install logwatch, download the source from below location. http://sourceforge.net/projects/sentrytools/ Install logwatch in Debian Linux apt-get install logwatch Install logwatch in Fedora Linux yum install logwatch Install logwatch in RedHat Enterprise Linux up2date logwatch To customize logwatch go to /usr/share/doc/logwatch-*/ directory and read the file HOW TO  ..

How to find gateway ipaddress in server

How to find gateway ip address using route command

Linux provide many way to to find the gateway IP Address, Lets see some example one by one. Find gateway IP Address using netstat command # netstat -nr OUTPUT: ======= Kernel IP routing table Destination Gateway Genmask   ..

Advantages of ext4 and why

Journaling file system ext4

What is ext4? The ext4 file system is a journaling file system which is a branch of ext3. Ext3 has been so valuable in terms of stability and usability to Linux that the developers decided to fork ext3 to ext4 instead of incorporating the features of ext into ext3. Those  ..

How to enable mod rewrite httpd

Apache enable mod rewrite

1. Login to your server. 2. Open your httpd.conf file. In Redhat you can find it at /etc/httpd/conf/httpd.conf 3. Edit httpd.conf, Search and change the following # vi /etc/httpd/conf/httpd.conf # LoadModule rewrite_module modules/mod_rewrite.so 4.Remove the # at the beginning of the line. Should look like this   ..

How to block ping ICMP packets in server

Block ICMP or ping using iptables

Linux disable or block ping packets all together You can setup kernel variable to drop all ping packets. Type the following command at shell prompt: # echo "1" > /proc/sys/net/ipv4/icmp_echo_ignore_all The above command will disable the ping request by setting up the kernel variable (ICMP) to drop packets Enable ping request # echo  ..

What is dev null

Devnull is a software device

what do you mean /dev/null in linx operating system? /dev/null - is a software device At times it might be necessary for you to ignore the output of a command which you execute you executed. This can be done by adding "> /dev/null 2>&1" at the end of a command. The above commnad  ..

How to lock or unlock user account

Disable or Enable a user account

The passwd command is used to create a password or to change password of a user account, The same password command is used for locking or unlocking a user account. The passwd command can also used by any user to change his or her username or password. How to lock an  ..

Enable acl without restaring server

Oracle setfacl operation not supported

# rpm -q acl Check the filesystem is mounted with acl # grep acl /etc/fstab /dev/sda6 /opt/oracle ext3 defaults,acl 1 2 How to remount a filesystem # mount -o remount /opt/oracle How to check the filesystem is mounted with acl # mount | grep acl /dev/sda6 on /opt/oracle type ext3 (rw,acl) Before  ..

How to find and remove log files directories

Find where does log files present

How to locate or find the unwanted log files and remove / clean those log files directories Find where does log files are present? The server's disk spce is consumed lot by log files, storing the unwanted logs is not a good idea for maintaining a server. In the application servers  ..

How to execute a command as another user

Run a script or command as another user

Some time there might be a requirement that a user have to execute a command or a script as another user. In such situation you can use visudo to give sudo access to the particula user or multiple user. Add the below entry in /etc/sudoers file. visudo # user1 ALL=(user2)   ..

Change permission of directories only

Chmod only directories

Find public_home directories and change the directory permission # find public_html/ -type d -exec chmod 775 {} \; The above command will find only directories and change the permission to 755 # find public_html/ -type d -exec chmod 755 {} + + at the end means that many filenames will be passed  ..

Error httpd dead but subsys locked

Daemon dead but subsys locked

Error: service httpd status, results in httpd dead but subsys locked If you are receiving the error httpd dead but subsys locked, while restarting apache on Linux server then the error usally means that it has broken LoadModule in the httpd.conf. Following are the possible fixes for this error: 1) Delete the file  ..

Modifying existing user home directory home directory

Usermod change existing home directory

You can alter user account information by editing /etc/passwd file. # vi /etc/passwd You can change the users home directory in the /etc/passwd file and copy the files to new location. It is recommended that you use usermod to avoid any syntax errors: usermod : Utility to modify existing user  ..

Extract files using unrar rar

How to use unrar and rar in linux

Here I will show you how to extract .rar files in linux For extracting rar files in linux first you have to install rar in linux. Follow the below steps to rar install linux. In Redhat or Fedora core Linux: # yum install unrar In Debian Linux, use apt-get as follows to install  ..

Cp ask for overwriting

Override the overwriting while copying

In linux operating system when you try to copy files from one directory to another directory, the cp(copy) command will ask for overwriting if the file already exists. Even if you use force option it will ask for overwriting. you can get out of this problem by two ways. 1) Use unalias   ..

< Previous 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 Next >

Tech Bluff