Copying files to a backup server via scp
Hello. The question is from the category "it works for everyone, but it doesn't work for me".
Setting up copying files to a backup server via scp.
In cron.d:
SHELL=/bin/sh
30 0 * * * root /root/scp
To /root/scp:
scp -r /home/aaa/* [email protected]:/var/www/aaa/
Created ssh keys. If you run the script from the command line, you do not need a password.
In /var/log/cron:
Jun 28 00:30:01 sss CROND[11806]: (root) CMD (/root/scp)
But the files are not copied. What could be the problem, please tell me?
0
1 answers
Instead of' scp
' in the /root/scp
file, insert what it says 'which scp
'
1
Author: ArcherGodson, 2013-06-28 11:21:44