ssh-copy-id error

created at 11-27-2021 views: 7


[root@jenkins .ssh]# ssh-copy-id -i root@
The authenticity of host ' (' can't be established.
RSA key fingerprint is a7:78:59:bd:6b:a5:02:3c:6e:85:9a:4c:7b:08:77:48.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '' (RSA) to the list of known hosts.
Permission denied (publickey,password).


When multiple pairs of public and private keys are used, this problem often occurs due to improper operation sequence. The correct operation steps are as follows:

  • ssh-copy-id -i root@
  • Modify the content of the config configuration file as follows:
    PreferredAuthentications publickey
    IdentityFile ~/.ssh/id_rsa_driver
    user root
created at:11-27-2021
edited at: 11-27-2021: