- 論壇徽章:
- 0
|
如何不用每次都輸入密碼自動(dòng)運(yùn)行
我是看這里的how-to:
http://killyridols.net/rsyncssh.shtml
自己試了好幾次總是提示輸入密碼,
使用命令:
rsync -avr -e ssh anyone@backuphost:~/test/*.test $HOME/test
如果把服務(wù)器端的sshd_config中
PasswordAuthentication 設(shè)定為no
在執(zhí)行命令后會(huì)提示Permission denied (publickey,gssapi-with-mic)
但是我想要使用公開(kāi)key,不用每次都輸入密碼,利用cron讓系統(tǒng)自動(dòng)聯(lián)接遠(yuǎn)程服務(wù)器
不知道誰(shuí)能幫助我一下,
到底該注意哪些設(shè)定?
服務(wù)器端sshd_config的設(shè)定:
AuthorizedKeysFile .ssh/authorized_keys
客戶端ssh_config的設(shè)定
Compression yes
Protocol 2
RSAAuthentication yes
StrictHostKeyChecking no
ForwardAgent yes
ForwardX11 yes
IdentityFile ~/.ssh/id_dsa
IdentityFile ~/.ssh/identity
IdentityFile ~/.ssh/id_rsa |
|