0

I broke the sshd installation on a remote host and now ssh doesn't startup. I can mount the file system on the host through a rescue system.

The rescue system is debian based and the host system is centos I'm currently investigating repairing using yum:

apt-get install yum
chroot /mnt/rescue yum install --installroot=/mnt/rescue/ openssl

But I'm running into problems as $releasever isn't defined, and it doesn't recognize mirrorlist.txt (no valid mirrors)

I'm wondering if there are any other options, e.g. placing a lightweight standalone ssh programme e.g. dropbear in /etc/init.d which will allow a login upon the next reboot? Or should I persist with the yum approach?

4
  • 2
    How exactly is it broken? What did you change.
    – Zoredache
    Mar 14, 2014 at 18:33
  • 2
    That looks somewhat odd. You shouldn't need to install yum or use --installroot. Rather mount -t proc none /mnt/rescue/proc; mount -o bind /dev /mnt/rescue/dev; chroot /mnt/rescue /bin/bash; yum install openssl However, yum may depend on openssl so if that is what you fubar'ed you may not be able to use this. Mar 14, 2014 at 19:36
  • @MarkWagner that comment has gotten me in to the right context. Do you want to write it up as an answer?
    – EoghanM
    Mar 15, 2014 at 8:24
  • @Zoredache serverfault.com/questions/580854
    – EoghanM
    Mar 15, 2014 at 8:44

0

You must log in to answer this question.

Browse other questions tagged .