Dedibox is a French collocation service part of the Iliad group. They rent dedicated servers at a very good price. In the standard offer, servers can be installed with standard operating systems: UNIX or Windows. “UNIX” includes all major distributions like Ubuntu, CentOS, Fedora, Slackware or Gentoo).
I maintain my server hosted @ Dedibox but I’m running OpenBSD. From the *BSD family, only FreeBSD is supported. OpenBSD not but it runs perfectly! [Note: The procedure to install OpenBSD on a Dedibox is here]
Dedibox proposes a nice administrative console where the owner can access a lot of useful options about his server(s). One of them is the remote-reboot.
Today, my server became unreachable. I logged on the console and activated the remote reboot. Nothing… Once again… Nothing… <stress>
Amongst other options, Dedibox proposes a KVM over IP but the server is used for personal purpose, I try keep the cost as low as possible! When a boot problem occurs, I’m completely blind (Linux support netconsole but not OpenBSD, unfortunately – or I’m not aware of!).
In such case, the last hope option is to switch the server in “rescue mode”. In this mode, the server boots a light Ubuntu distribution over the network without altering the disks.
I booted my server, got a temporary root password and let’s investigate! First, the disk was properly detected, it’s not a hardware failure:
# dmesg | grep sda [ 7.340000] sda4: <openbsd: sda5 sda6 sda7 sda8 sda9 sda10 sda11 >
OpenBSD uses the UFS file system. I was able to boot all the file systems in read only (UFS was supported in the booted Linux kernel):
# mkdir /tmp/ufs # mount -t ufs -o ro,ufstype=44bsd /dev/sda5 /tmp/ufs
All partitions were successfully mounted manually. Next step, to check the file systems consistency. But fsck.ufs was not installed by default. I googled for more information and found the missing packages:
Let’s copy then to the rescue linux and install then:
# dkpg -i libbsd0_0.0.1-1_i386.deb libufs2_7.0-2_i386.deb \ libufs2_7.0-2_i386.deb
Last operation was to run fsck.ufs on all the file systems. By security (incompabitility between the tool and the file system), I first checked /tmp. It worked perfectly. Indeed, one file system was marked as bad and prevented the system to boot normally. It was fixed without problem. A last reboot and the server is now back in business!