Need help writing a simple bash script
Posted on 2010-09-22
I need to collect iostat information every 15 minutes, and also print the timestamp for each collection interval. I am planning to write a simple shell script that will output iostat to a file and also collect the timestamp for each iostat interval...I will then add this to crontab to run every 15 mins...this is what I have so far:
iostat -xn 3 10 >> /syb/homedir/monitoring/iostat.txt
I'm not used to writing scripts but I want is for my script to append iostat to a file upon every execution and also print timestamp...
Any help is welcome!