Missing openssh-client or ssh-copy-id command not found

Hi All,
I wanted to share keys between two ipfire boxes, but when I get to ssh-copy-id it says command not found.
I guess that’s inside openssh-client, but that’s not available for install…
Maybe there is a security reason, and I am on the wrong trail.
I was going to test an automated backup of the data on Extra HD between the two, and I need to be able to do ssh without pwds.
Any ideas?
Thanks in advance,

Hi @gian

Both the server and client are set up in IPFire but the install process has not installed the ssh-copy-id script from the contrib directory in the source tarball.

scp is available in IPFire so you should be able to use that to copy files where you want to.

This might help:

The problem is that that page tells you to use ssh-copy-id and that script is not installed in IPFire.

I misread the page. It uses ssh-copy-id from the client computer to copy the keys to IPFire

I will check the history of openssh in IPFire and see when ssh-copy-id stopped being installed and why and look at having it added back in.
I suspect an error occurred somewhere in the past to remove ssh-copy-id

ssh-copy-id has never been installed in openssh in IPFire since it was included back in 2008 or so

1 Like

The image in the Wiki is from my Mac.

So I am fairly sure I used ssh-copy-id from the client side and all was OK. Which may mean that ssh-copy-id doesn’t need to be on the IPFire (Host) side.

My notes are from 2018 so I could be very wrong!

Thanks, Adolf,
but I wanted to use rsync, that’s why I was interested in ssh without password.

Hi GianLuca,

My suggestion for using scp was for copying the ssh keys across.

Another alternative to get the ssh keys swapped between your IPFire systems is to use a USB key as an ExtraHD

Once you have the keys shared using the usb key, or scp, then you can use rsync as you want to.

Hi Jon,

That is totally correct if you want to copy your keys into IPFire.

My understanding of @gian requirement is that he has two IPFire systems and he wants to copy the keys from each one to the other one which would then need the ssh-copy-id on the IPFire machines.

1 Like
  1. On a client machine running a reasonably current linux distro, run “which ssh-copy-id”
  2. login to target IPFire machine as root.
  3. “mkdir ~/bin” (/root/bin), if not already present
  4. “cd ~/bin”
  5. “sftp [user@target-linux-client]”
  6. “get [result of step 1]”
  7. exit sftp session
  8. edit the first line of ~/bin/ssh-copy-id so that the “shebang” reflects IPFire’s location of “sh” (/bin/sh)
  9. save and exit editor

Note: I’ve performed all these steps on my firewall, but haven’t actually tried to copy any keys.

1 Like

Ugh! someday I’ll learn to read! Thank you!

So, if I got it right, I should create an authorized_keys file containing id_rsa.pub, and scp it to the destination Ipfire host.
However, I was not able to find root’s .ssh folder, so where should I place it?

You need to create it.