I configured a cronjob (running a bash script) with crontab -e
which locally copies some data from one hard drive to another (rsync
) and after that compares them (diff
).
I executed the script manually to see if everything runs as planned. It copied 7 GB and took about 30 min. When it is started as cronjob it takes 4h, again copying 7 GB.
The data and script had not been changed since the manual call and the cronjob call of the script.
- May it be that cronjobs run as daemons with very little priority?
- If so, how can I change that?
rsync
had to copy more? How are you checking that both cases copied 7G? Did the manual and the automatic copy both use the exact same command and the exact same source and target directories? Are you copying across a network? – terdon Mar 10 '16 at 11:37