Showing posts from 2014

How to find files In Linux

In this article i will explain you to how to find files in Linux.

Find at current location
# find  . -name abc.txt   

Find file name case insensitively
# find / -iname abc.txt   

Find the file in / .
# find / -name *.txt       

Find the file where 'pass' in /etc
# find /etc -name *pass*   

Find the file in /data created by macho
# find / -user macho       

Find the file in /data which is not created by macho
# find / -not -user macho   

Find the file with uid of 500
# find / -user macho -uid 500   

Matches if mode is exactly 755
# find / -perm 755       

Matches if anyone can write
# find / -perm +222       

Matches if everyone can write
# find / -perm -222       

Matches if other can write
# find / -perm -002          

Files with a size of exactly 10M
# find / -size 10M       

Files with a size of above 10M
# find / -size +10M       

Files with a size of less than 10M
# find / -size -10M       

When file was last read (min)
# find / -amin 10       

When file d…

A free tool to analyze AIX and Linux performance

One of the tools I use to monitor performance on IBM AIX 5.3 and Linux is NMON. Using nmon, you can monitor CPU, memory, network, disk, filesystems, NFS and Top Processes.

Install Nmon

CentOS users need to install nmon from rpmforge/repoforge repository. It is not present in Epel.

CentOs 4 :
i386     rpm -ivh

x86_64   rpm -ivh

CentOs5 :
i386     rpm -ivh

x86_64   rpm -ivh

CnetOs6 :
i686     rpm -ivh

x86_64   rpm -ivh

sudo yum install nmon
sudo apt-get install nmon

Usage :

$ nmon

Audit Your Linux Security With Lynis

Installation :

yum install lynis

Ubuntu :
apt-get install lynis

Install from source :
Create Directory
mkdir /usr/local/lynis

cd /usr/local/lynis
tar -xvf lynis-1.3.9.tar.gz

cd lynis-1.3.9.

Usage :
lynis -c

Vishal Vyas

For More :

GoAccess a Real time Web Server Log Analyzer

Installation :

# yum install ncurses-devel glib2-devel GeoIP*
# cd /opt
# wget
# tar zxvf goaccess-0.5.tar.gz
# cd goaccess-0.5
# ./configure
#  make
# make install

To generate full statistics we can run GoAccess as:
 # goaccess -f /var/log/httpd/access_log -a

Select a log format and press F10

To generate an HTML report:
#goaccess -f  /var/log/httpd/access_log -a > report.html

To generate a CSV file:
# goaccess -f access.log -o csv > report.csv

Vishal Vyas

For more information and usage please visit