crontab -eand then enter:
5 8 * * * /bin/bash /home/user1/Dropbox/backups/scripts/svndump.sh > /tmp/cron.logto the end of file and save it. However, the cron job never runs and the log file was never created. I tried on root user as well and also without any luck. In the end I have found out this is actually a bug on the Ubuntu system ( not sure other distros though ) from Ubuntu Help:
When adding a new entry to a blank crontab, forgetting to add a newline at the end is a common source for the job not running. If the last line in the crontab does not end with a newline, no errors will be reported at edit or runtime, but that line will never run. See man crontab for more information. This has already been suggested as a bug.So what I did was to add a few new lines to the end of “crontab -e” output and then restart the cron server:
service cron restartNow my cron job works perfectly. I have my backup runs everyday and it uploads to dropbox automatically, I don’t need to worry about lose data anymore.