Redhat hit Sh-copy-id command error:-bash:ssh-copy-id:command not found
SSH access to multiple Linux servers without a password,
Which enters a Linus, copies it to host, appears
Will not be the user's permissions issue, under Root execution:
[Email protected] hadoop]# Ssh-copy-id
/usr/bin/ssh-copy-id:error:no identities found
Why does it appear like this? (At present, I have not resolved, if you know the reason for hope to tell you!) )
After a long day, I got a few options:
1. Perform the following to remove the problem of minimizing the installation.
Yum-y Install Openssh-clients
Results:
[email protected]. ssh]# yum-y Install Openssh-clients
Loaded Plugins:product-id, Refresh-packagekit, security, Subscription-manager
Updating certificate-based repositories.
Setting up Install Process
Nothing to do
[email protected]. ssh]# exit
Exit
[email protected]. ssh]$ Sh-copy-id
Bash:sh-copy-id:command not found
It's still not working.
2 Another method was found, namely:
1. If the Ssh-copy-id function does not exist on the remote server, as follows
[email protected]. ssh]# ssh-copy-id-i id_rsa.pub [email protected] |
-bash:ssh-copy-id:command not found |
Can try to use the command to solve, directly copy the local PubKey content to the remote server;
The following is performed in host2 or Host6
Cat ~/.ssh/id_*.pub | SSH [email protected] ' cat >> Ssh/authorized_keys '
It can be both.
Reproduced in: Multiple Linux servers ssh mutual access without password: http://kling.blog.51cto.com/3320545/1132800
Redhat hit Sh-copy-id command error:-bash:ssh-copy-id:command not found