Bootstrap / recover Ubuntu Linux using chroot

Especially if you have a dedicated server from Server4You the option below might be what you are looking for to e.g. reinstall another linux kernel version using the recovery boot option:
mdadm --assemble --run /dev/md/0
mdadm --assemble --run /dev/md/1
mdadm --assemble --run /dev/md/2
mkdir /mnt/chroot
mount /dev/md/2 /mnt/chroot
mount /dev/md/0 /mnt/chroot/boot
mount /dev/sda1 /mnt/chroot/boot/efi
mount --bind /proc /mnt/chroot/proc
mount -t sysfs sys /mnt/chroot/sys
mount -o bind /dev /mnt/chroot/dev
mount -t devpts devpts /mnt/chroot/dev/pts
chroot /mnt/chroot

1 comment:

  1. Absolutely fantastic job you have done here.This is so nice.Thanks for sharing.
    clipping path