I find that the easiest thing to do when setting up a chroot, is to # mkdir $MYCHROOT/dev # cp /dev/MAKEDEV $MYCHROOT/dev/ # cd $MYCHROOT/dev/ # ./MAKEDEV generic
and bingo, all the usual suspects, all set up in your chroot :) Kerry wrote: > Hi all > > I came across this recently: > > Need to have a /dev/null in your chroot? It wasn't obvious to me at > first > > Here's how : > > # mkdir /home/httpd/vhosts/chroot/dev > # chmod 0511 /home/httpd/vhosts/chroot/dev > # mknod /home/httpd/vhosts/chroot/dev/null c 1 3 > # chmod 666 /home/httpd/vhosts/chroot/dev/null > > > Not that I need it but a few parts I don't quite understand... In the > second line what does the "0" do? I haven't come across a four digit > octal on a chmod command. > > Also I kinda get what the mknod command after checking the man pages and > understand what the "c" argument is doing but what is the "1 3" doing? > > Thanks > Kerry > > > >
