![]() ![]() For more info about Cron, please see my previous article. Most people will just want a simple weekly or daily backup, and what we have shown you can easily accomplish that. In the above cron it is scheduled to perform automatic backup on daily at 2:30 PM. # crontab -eģ0 2 * * * rsync -avz -e "ssh -i /home/user/.ssh/id_rsa" /root/test/ :/backup/destination/directory/Īfter you are done configuring Cron, press escape, and then type “:wq” (without the quotes) and press enter. Now set cron jop for automate this process on scheduled time. ![]() Still if your are getting problem, please make sure you have set proper permission to read from the source “ /root/test/” and to write to the target “ :/backup/destination/directory/” also make sure ssh session is establishing between the two hosts without password. # rsync -avz -e "ssh -i /home/user/.ssh/id_rsa" /root/test/ :/backup/destination/directory/ Rsync should now complete without prompting for a password. Now you should be able to SSH into the remote machine without password. Suggested Read : Steps To Setup SSH Login Without Password ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |