I'm having issues setting up cron scripts that log into a server automatically via ssh.
I created the automatic ssh login using this:
http://www.ccp4.ac.uk/peter/programming/automatic_ssh_login.html
i followed this how to in order to set the the cron job:
http://www.tech-geeks.org/contrib/mdrone/cron&crontab-howto.htm
I tested the scrip manually but it still requires me to enter the password for the ssh login. But if i manually type it in the console it logs me into the server instantly without a password.
So how do you get the auto ssh login to work inside of scripts?
How do i check to see if my cron job has been added?
here is the scrip i am trying to run
Here is the code that i injected into the crontab
0 * * * * /etc/periodic/hourly/*
I created the automatic ssh login using this:
http://www.ccp4.ac.uk/peter/programming/automatic_ssh_login.html
i followed this how to in order to set the the cron job:
http://www.tech-geeks.org/contrib/mdrone/cron&crontab-howto.htm
I tested the scrip manually but it still requires me to enter the password for the ssh login. But if i manually type it in the console it logs me into the server instantly without a password.
So how do you get the auto ssh login to work inside of scripts?
How do i check to see if my cron job has been added?
here is the scrip i am trying to run
Code:
#!/bin/bash
rsync -v -r -z -u --exclude '.DS_Store' user@myserver:/media/extra/backups/projects/ /Users/myusername/Documents/Projects/
Here is the code that i injected into the crontab
0 * * * * /etc/periodic/hourly/*