Linux Magazine #2 2023: Hoe je chroot kunt gebruiken voor systeemherstel
- August 7, 2023
- 0
Listing: Koppel mappen in chroot
sudo mount /dev/sda2 /mnt/rescue/boot sudo mount /dev/sda1 /mnt/rescue/boot/efi
Listing: resolv.conf van de host kopiëren
sudo mount -t proc proc /mnt/rescue/proc sudo mount -t sysfs sys /mnt/rescue/sys sudo mount -o bind /dev /mnt/rescue/dev sudo mount -t devpts pts /mnt/rescue/dev/pts sudo cp /etc/resolv.conf /mnt/rescue/etc/resolv.conf
Listing: Ontkoppel mappen en bestanden
sudo umount /mnt/rescue/dev/pts sudo umount /mnt/rescue/dev sudo umount /mnt/rescue/sys sudo umount /mnt/rescue/proc sudo rm /mnt/rescue/etc/resolv.conf