The most important command: chroot

“A chroot is an operation that changes the apparent root directory for the current running process and their children. A program that is run in such a modified environment cannot access files and commands outside that environmental directory tree. This modified environment is called a chroot jail.”

I always have a spare USB device with an Arch Linux bootable iso just in case my system does not boot or after a package update that totally breaks my system.

In August 2022 there was a major GRUB bug that caused many systems failing to boot. At that time I was not in a home setting so chroot from a USB literally saved me.

Another case was using ibt=off in /etc/default/grub that turns off the Indirect Branch Tracking security feature, after a bug affected Nvidia drivers.

https://github.com/NVIDIA/open-gpu-kernel-modules/issues/256

https://wiki.archlinux.org/title/chroot


Leave a comment

Discover more from /root

Subscribe now to keep reading and get access to the full archive.

Continue reading