schedule vmstat command and store output in a text file
Dear Experts,
i want to ask you some question while sharing what i did to achieve that.
i want to know memory and cpu usage for my linux RedHat enterprise linux server.
can i get all this information with command cc ( running vmstat command after every 60 seconds 100 times ).
i want to store this file output in a text file like
vmstat -n 60 100 >> cpu_and_memory.txt ( i have seen and it works fine).
to schedule all above work through crontab i wrote a shell script
*/usr/bin/vmstat -n 3 6 >> /opt/cpu_and_memory_usage.txt ( contents of a shell script*
and i scheduled in crontab ( 00 18 * * /opt/process_usage.sh )*
but no out put is generated.
how do i proceed.