Before you can chroot into the remaster environment, we have to map some special directories from the installed linux environment into the knoppix live environment. The directories are special because the kernel makes them upon bootup to manage things like devices, processes and system resources. Since we are using our installed linux system's kernel inside our knoppix live system's filesystem, we need to map these special directories from one into the other before entering the chroot environment so that we have access to devices like the network card for network access to do things like install new packages.
To map the special directories we use the following commands
mount --bind /dev /share/knoppix_remaster/source/KNOPPIX/dev
mount --bind /proc /share/knoppix_remaster/source/KNOPPIX/proc
mount --bind /sys /share/knoppix_remaster/source/KNOPPIX/sys
To be able to resolve network addresses via DNS (like you do most of the time), you need to have a DNS server address in your /etc/resolv.conf file. Since the knoppix live environment is just using the installed linux system's kernel and devices, you need to also copy the /etc/resolv.conf from the installed system to the knoppix live filesystem before entering the chrooted environment with the following command
cp /etc/resolv.conf /share/knoppix_remaster/source/KNOPPIX/etc/dhcpc/resolv.conf
One more problem that you might have is that while working in the chrooted environment, you might see the error
/dev/null: Permission DeniedIf you see this error, it's probably because the partition that you chose to put your remaster directory on doesn't allow for device nodes to be created on it. To fix this problem (while not chrooted into the knoppix live environment) issue the following command (use the appropriate mount point for your system)
mount -o remount,dev /shareNow once you chroot yourself again, you shouldn't see the error.
Don't forget to unmap the special directories and delete the resolv.conf file from your knoppix live environment after leaving the chrooted environment.
![[logo]](logo.png)