Bash script and cron job
Please let me know the steps are correct.
First, I create a bash script file called my_compress.sh in /usr/local/bin
The contents look like this:
find /u1/database/prod -type f -print | grep -v 'gz' | xargs gzip
I then make my_compress.sh an executable file by
chmod +x my_compress.sh
I want to add this to the cron job to run every hour so
0 * * * * /usr/local/bin/my_compress.sh
Also to comment out other existing jobs in the cron table do I just add a # in front of them and close the cron file by pressing CTRL C?