Wednesday, August 22, 2018

No hostkey alg error on RED Hat Linux 7

No hostkey alg  error on RED Hat Linux 7

After new RED Hat Linux 7 installation when admin tried to ssh from Jump server getting error like “No hostkey alg “

#ssh servername(RHELclinet)
Error :“ no hostkey alg”

Step 1:
vi /etc/ssh/sshd_config
Then remove comment from following highlighted entry

# HostKey for protocol version 1
HostKey /opt/dcx/openssh/etc/ssh_host_key
# HostKeys for protocol version 2
HostKey /opt/dcx/openssh/etc/ssh_host_rsa_key
HostKey /opt/dcx/openssh/etc/ssh_host_dsa_key
PidFile /var/run/

Step 2:
Generate RSA and DSA keys using following command.
# ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key ;ssh-keygen -t dsa -f /etc/ssh/ssh_host_dsa_key

Step 3: 
Then restart sshd using following command.
#service sshd restart

Step 4:
Try ssh from remote jump server it must work
#ssh servername(RHELclinet)
By using above mentioned steps we sorted out “No hostkey alg “ error.

No comments:

Post a Comment