So just installed Vixie-cron on my new Sabayon 8 install and created a nice backup script but it doesnt work. I thought all was well until I wanted to use a double ampersand in between commands in my script. The only part of the script is the second section AFTER the ampersand.
So I have resulted in a cut down simple one liner to test if it really works and still no joy.
Here is the code in script.sh:
/bin/echo "Testing123" && /bin/echo "Why wont you work" > /var/log/ScriptOutpu_`date +\%Y\%m\%d`.log
Crontab looks like this:
00 18 * * * /usr/local/scripts/script.sh
I am running the script as root so even tried adding the root id in the cron string. Still doesnt work. The only thing that does work is the second part of the script. The part after the double ampersand. Not the "Testing123" part.
Any clues would be great guys.