Hi, ich möchte mit rsync die Daten auf meinen Web-Server HEINZ (heinz.fasel.de) (Suse7.3) auf einer anderen Suse GERD (suse8.0) sichern. Vorgehen (nach : http://www.vertexnet.de/docu/rsync/ und http://www.uni-karlsruhe.de/~ssh/pubkey.html ) Überprüfe ob rsync auf beiden Rechnern installiert ist. GERD: Schlüssel erstellen: ssh-keygen -t rsa1 wird /root/.ssh/heinz.id_dsa erstelle : /root/.ssh/config mit folgenden Inhalt: Host *.fasel.de User root Compression yes Protocol 2 RSAAuthentication yes StrictHostKeyChecking no ForwardAgent yes ForwardX11 yes IdentityFile /root/.ssh/heinz.id_dsa kopiere heinz.id_dsa.pub nach authorized_keys HEINZ: kopiere die authorized_keys von GERD nach /root/.ssh/authorized_keys auf HEINZ authorized_keys auch nach authorized_keys2 kopiert Teste mit /usr/bin/rsync -e "ssh -l root" -avzp --delete /home/roessler/ root@gerd:/home/roessler2/ Das klappt wunderbar, nur ... Mein Problem : Es wird immer noch das Passwort abgefragt. Irgendwas habe ich übersehen! Danke Ingo ################################################################# gerd:~/.ssh # ssh -V OpenSSH_3.0.2p1, SSH protocols 1.5/2.0, OpenSSL 0x0090603f gerd:~/.ssh # cat /etc/ssh/sshd_config Port 22 Protocol 2,1 ListenAddress 0.0.0.0 # HostKey for protocol version 1 HostKey /etc/ssh/ssh_host_key # HostKeys for protocol version 2 HostKey /etc/ssh/ssh_host_rsa_key HostKey /etc/ssh/ssh_host_dsa_key # Lifetime and size of ephemeral version 1 server key KeyRegenerationInterval 3600 ServerKeyBits 768 # Logging SyslogFacility AUTH LogLevel INFO #obsoletes QuietMode and FascistLogging # Authentication: LoginGraceTime 600 PermitRootLogin yes StrictModes yes LoginGraceTime 600 PermitRootLogin yes StrictModes yes RSAAuthentication yes PubkeyAuthentication yes AuthorizedKeysFile %h/.ssh/authorized_keys2 # rhosts authentication should not be used RhostsAuthentication no # Don't read the user's ~/.rhosts and ~/.shosts files IgnoreRhosts yes # For this to work you will also need host keys in /etc/ssh/ssh_known_hosts RhostsRSAAuthentication no # similar for protocol version 2 HostbasedAuthentication yes # To disable tunneled clear text passwords, change to no here! PasswordAuthentication yes PermitEmptyPasswords no # Uncomment to disable s/key passwords ChallengeResponseAuthentication no X11Forwarding yes X11DisplayOffset 10 PrintMotd yes #PrintLastLog no KeepAlive yes Subsystem sftp /usr/lib/ssh/sftp-server ################################################################## heinz:~/.ssh # ssh -V OpenSSH_2.9p2, SSH protocols 1.5/2.0, OpenSSL 0x0090602f heinz:~/.ssh # cat /etc/ssh/ssh_config Host * # ForwardAgent no # ForwardX11 no # RhostsAuthentication no # RhostsRSAAuthentication yes RSAAuthentication yes PasswordAuthentication yes # FallBackToRsh no # UseRsh no # BatchMode no # CheckHostIP yes # StrictHostKeyChecking yes # IdentityFile ~/.ssh/identity IdentityFile ~/.ssh/id_dsa # IdentityFile ~/.ssh/id_rsa # Port 22 Protocol 1,2 # Cipher blowfish # EscapeChar ~
Hallo auch: Am Dienstag, 25. März 2003 11:05 schrieb Ingo Rößler:
Hi,
ich möchte mit rsync die Daten auf meinen Web-Server HEINZ (heinz.fasel.de) (Suse7.3) auf einer anderen Suse GERD (suse8.0) sichern. Vorgehen (nach : http://www.vertexnet.de/docu/rsync/ und http://www.uni-karlsruhe.de/~ssh/pubkey.html )
Überprüfe ob rsync auf beiden Rechnern installiert ist.
GERD: Schlüssel erstellen: ssh-keygen -t rsa1
wird /root/.ssh/heinz.id_dsa
erstelle : /root/.ssh/config mit folgenden Inhalt:
Host *.fasel.de User root Compression yes Protocol 2 RSAAuthentication yes StrictHostKeyChecking no ForwardAgent yes ForwardX11 yes IdentityFile /root/.ssh/heinz.id_dsa
kopiere heinz.id_dsa.pub nach authorized_keys
HEINZ: kopiere die authorized_keys von GERD nach /root/.ssh/authorized_keys auf HEINZ authorized_keys auch nach authorized_keys2 kopiert
Teste mit /usr/bin/rsync -e "ssh -l root" -avzp --delete /home/roessler/ root@gerd:/home/roessler2/ Das klappt wunderbar, nur ...
Mein Problem :
Es wird immer noch das Passwort abgefragt.
Irgendwas habe ich übersehen!
Danke Ingo
#################################################################
gerd:~/.ssh # ssh -V OpenSSH_3.0.2p1, SSH protocols 1.5/2.0, OpenSSL 0x0090603f
heinz:~/.ssh # ssh -V OpenSSH_2.9p2, SSH protocols 1.5/2.0, OpenSSL 0x0090602f
Tja, du verwendest 2 verschiedene ssh-versionen, damit hatte ich seltsamerweise auch schon mal Ärger. Obwohl die laut allen Beschreibungen kompatibel sein soltten, konnte ich schon in 2 Fällen die Passwortabfrage erst verhindern, nachdem ich beide Kisten auf exact die gleiche ssh-Version gezogen hatte. Warum? K.A.! (vielleicht erleuchtet uns beide hier jemand?) Aber zum besseren debug: Du kannst auch einen ssh-Verbindungsaufbau "verbose" testen. Dadurch erhälst du recht gute Infos darüber, ob der nach dem Schlüssel sucht, ihn findet, etc...(ssh -v gerd/heinz) Vielleicht kannst du den Output mal posten. Bernd
participants (2)
-
Bernd Tannenbaum
-
Ingo Rößler