–> echo previous process id to file:
echo $! >> /path/to/pid-file/file.pid
–> Force reboot when reboot command does not work [this is a abrupt reboot and DOES NOT gracefully shutdown]:
echo 1 > /proc/sys/kernel/sysrq // enable use of sysrq echo b > /proc/sysrq-trigger // reboot
–> List files/directories according to the datetime:
ls -lt
–> Check ram usage:
free -m
cat /proc/meminfo
–> Information of your Linux box:
uname -a [shows you latest kernel version number and architecture (x86_64 or i386)]
cat /etc/redhat-release (redhat & centOS specific)
rpm -qa | grep kernel [check your kernel version]