Troubleshout Open file limit

Show no of open files sorted by PID - lsof | awk '{ print $2; }' | uniq -c | sort -rn | head Check individual file limits of a process - cat /proc/<PID>/limits to obtain a precise count of the open files at given instant of time - ls /proc/<PID>/fd | wc -l This will list all open files with given process - lsof -p <PID> In some cases you might have to look at the open file limit of the process which started your process. [Read More]

Check Cron executed or not.

Many a times it happens we schedule some cron job to get executed, we do check as well whether command gets executed properly or not. And even though we tried the command your cron fail to execute. There are two possibilities either cron is not configured properly or some how command is failed. Now in this case how do we check if cron is getting executed or not. Does it gets logged some where when is last cron executed? [Read More]

Setup firewall with UFW on ubuntu

It is very easy to setup firewall using UFW on ubuntu server. First you need to check if you have UFW installed on your machine. If it is installed you can check the status of the same using $ sudo ufw status Status: inactive In case it is installed but not enabled. If it is not installed then it will throw command not found error. If it is active then it will show out put similar like below output. [Read More]