You are here

Linux chroot - things to remember

Uditha Atukorala's picture

When you are creating a chroot jail, before you chroot make sure that you have mount the following;

1 - /proc
# mount -o bind /proc /mnt/chroot/proc

2 - /sys
# mount -o bind /sys /mnt/chroot/sys

3 - /dev
# mount -o bind /dev /mnt/chroot/dev

Finally when you are done,

# chroot /mnt/chroot /bin/bash