Junipor交換機 ssh_exchange_identification: Connection closed by remote host
阿新 • • 發佈:2019-02-19
可根據以下步驟使其ssh服務恢復正常:
Step1 check the files are present in the directory by login in to the switch and you should be in the shell
root@SUNNY:RE:0% ls /etc/ssh/ssh*
/etc/ssh/ssh_host_dsa_key /etc/ssh/ssh_host_rsa_key
/etc/ssh/ssh_host_dsa_key.pub /etc/ssh/ssh_host_rsa_key.pub
/etc/ssh/ssh_host_key /etc/ssh/ssh_known_hosts
/etc/ssh/ssh_host_key.pub
root@SUNNY:RE:0% ls /config/ssh*
/config/ssh_host_dsa_key /config/ssh_host_key
/config/ssh_host_dsa_key.pub /config/ssh_host_key.pub
/config/ssh_host_ecdsa_key /config/ssh_host_rsa_key
/config/ssh_host_ecdsa_key.pub /config/ssh_host_rsa_key.pub
Step 2 Make two directory under the /etc/ by following command
root@SUNNY:RE:0% cd /etc
root@SUNNY:RE:0% mkdir test1
root@SUNNY:RE:0% mkdir test2
root@SUNNY:RE:0% ls ----- by issuing this command you will be able to see the directory test under /etc
fbtab newsyslog.conf.sys sshd_netconf
fstab notices stunnel.conf
ftpusers pam.conf syslog.conf
gettytab pam.conf.sys termcap
group passwd termcap.small
group.sys profile test1
test2
step3 copy the files under /etc/ssh/ssh* to the directory test1 and also copy /config/ssh* to directory test2
root@SUNNY:RE:0% cp /etc/ssh/ssh* /etc/test1
root@SUNNY:RE:0% cp /config/ssh* /etc/test2
root@SUNNY:RE:0% ls /etc/test1
root@SUNNY:RE:0% ls /etc/test2
Step4 then you have to create a directory under the /var/
root@SUNNY:RE:0% cd /var/
root@SUNNY:RE:0% mkdir empty
重啟交換機:
request system reboot
後可正常登陸