Remote SSH ไม่ได้ครับ จากเครื่องนึงไปอีกเครื่องไม่ได้
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
ssh -l root 192.168.0.13 แล้วมัน Err. แบบนี้ แก้ไขไงครับ
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that the RSA host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
ca:01:48
0b:0e:fb:21:ca:0d:1d:af
9e:cc:80.Please contact your system administrator.
Add correct host key in /root/.ssh/known_hosts to get rid of this message.
Offending key in /root/.ssh/known_hosts:4
RSA host key for 192.168.0.13 has changed and you have requested strict checking.
Host key verification failed.
paokrab:
แสดงว่าเครื่องปลายทางมีการลงเครื่องใหม่ใช่ไหมครับ จาก error นี่ก้อต้องลบบรรทัดที่ 4 ในไฟล์ /root/.ssh/known_hosts ครับ แล้วลอง ssh ใหม่ มันจะถามว่าจะรับ key ไหมให้ตอบ yes นะครับ
rapin:
อ้างจาก: paokrab ที่ 18 ธันวาคม 2006, 13:30:20
แสดงว่าเครื่องปลายทางมีการลงเครื่องใหม่ใช่ไหมครับ จาก error นี่ก้อต้องลบบรรทัดที่ 4 ในไฟล์ /root/.ssh/known_hosts ครับ แล้วลอง ssh ใหม่ มันจะถามว่าจะรับ key ไหมให้ตอบ yes นะครับ
ใชครับพี่งลง centos 4.4 ไป อ้อตอนนี้ใช้ Vandyke SecureCRT รีโมทจากเครื่อง window เข้าไปได้ แต่ remote จาก ลีนุกส์ผ่าน shel ไม่ได้เลยครับ err. ตามนั้นเลย
rapin:
+++++++++++++++++++++++++++++++++++++++++++
Port 22
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
ServerKeyBits 1024
LoginGraceTime 600
KeyRegenerationInterval 3600
PermitRootLogin yes
IgnoreRhosts yes
IgnoreUserKnownHosts yes
StrictModes yes
X11Forwarding no
PrintMotd yes
SyslogFacility AUTH
LogLevel INFO
RhostsRSAAuthentication no
RSAAuthentication yes
PasswordAuthentication yes
PermitEmptyPasswords no
AllowUsers root administrator
Subsystem sftp /usr/libexec/openssh/sftp-server
+++++++++++++++++++++++++++++++++++++++++++
ตอนนี้ผมปรับ /etc/ssh/sshd_config เป็นแบบนี้ครับผลคือ
1. หากเปิด HostKey /etc/ssh/ssh_host_rsa_key จะ Remote ผ่าน shel ของเคร่ื่องลีนุกส์ได้ linux remote to linux
2. หากปิดข้อหนึ่ง ไว้จะทำข้อหนึ่งรีโมทย์ไม่ได้ แต่สามารถรีโมทย์จากเครื่อง windows to linux(centos 4.4)ได้ เวลา restart service ก็มี message แบบนี้
/etc/init.d/sshd restart
Stopping sshd: [ OK ]
Starting sshd:Disabling protocol version 2. Could not load host key
[ OK ]
3. อยากให้ Remote ได้ทั้งสองข้อทำไงครับ
paokrab:
เปิดไว้ครับ แต่ต้องลบบรรทัดที่4 ไฟล์ /root/.ssh/known_hosts รึยังครับ ลบที่เครื่องต้นทางที่เป็น linux นะครับ