Linux mpstat Command

What is mpstat? mpstat is used to monitor cpu utilization on your system. It will be more useful if your system has multiple processors. The first processors will signed as CPU 0. The second one will be signed CPU 1 and so on. The mpstat command writes to standard output activities for each available processor,…

Some Linux commands I use often

Get the total size of some files: du -ch /path/patern* | grep total Get the total number of files being backed up using the log of the RMAN job: grep -i ‘input datafile file number=’ rman_BKUP.log | wc -l Use grep to display the next 2 lines after the pattern you’re looking for (-A= AFTER…

X11 forwarding request failed on channel 0

I got this error while trying to redirect my display to the local host. marius$ ssh -X oracle@rac1 Warning: the ECDSA host key for ‘rac1’ differs from the key for the IP address ‘192.168.100.101’ Offending key for IP in /Users/marius/.ssh/known_hosts:10 Matching host key in /Users/marius/.ssh/known_hosts:13 Are you sure you want to continue connecting (yes/no)? yes…

Find missing sequence files

Some of my archive logs were missing from my standby site; with this I found which was missing: for nr in $(seq 1 5); do printf -v fle “*6493_841385922.dbf” ${nr}; if ! [ -e  “${fle}” ]; then echo “${fle}” missing; fi;  done