Ssh-copy-id ceph@osd-0 /bin/ssh-copy-id: ERROR: failed to open ID file ‘/home/ceph/.pub’: No such file or directory

ceph

I can ssh successfully my ceph osd nodes but when i am trying to copy ssh id i am getting below error can anyone guide why i am getting below errors.

[ceph@monitor ~]$ ssh-copy-id ceph@osd-0

/bin/ssh-copy-id: ERROR: failed to open ID file '/home/ceph/.pub': No such file or directory
(to install the contents of '/home/ceph/.pub' anyway, look at the -f option)
[ceph@monitor ~]$

Best Answer

your local public key is not found in /home/ceph/.pub

By default, your SSH keys are in /home/user/.ssh/key[.pub]

You can specify the right key to use with the -i (i for 'identity') option :

ssh-copy-id user@server -i /file/to/use