LFS 6.0 - Is it necessary to populate dev every time you enter the chroot env.

Yes, prior entering you have to check that: $LFS/proc $LFS/sys is mounted.

Do the fake mounts:
mount -f -t ramfs ramfs $LFS/dev
mount -f -t tmpfs tmpfs $LFS/dev/shm
mount -f -t devpts -o gid=4,mode=620 devpts $LFS/dev/pts

enter chroot:
chroot "$LFS" /tools/bin/env -i \
    HOME=/root TERM="$TERM" PS1='\u:\w\$ ' \
    PATH=/bin:/usr/bin:/sbin:/usr/sbin:/tools/bin \
    /tools/bin/bash --login +h

mount ramfs:
mount -n -t ramfs none /dev

start udev:
/tools/sbin/udevstart

create symlinks:
ln -s /proc/self/fd /dev/fd
ln -s /proc/self/fd/0 /dev/stdin
ln -s /proc/self/fd/1 /dev/stdout
ln -s /proc/self/fd/2 /dev/stderr
ln -s /proc/kcore /dev/core
mkdir /dev/pts
mkdir /dev/shm

mount kernel file systems:
mount -t devpts -o gid=4,mode=620 none /dev/pts
mount -t tmpfs none /dev/shm

that should get you started again. However I suggest to build LFS without interruption for the first time. Try to keep the Computer running until you are finnished. There are too much things that can go wrong.
--
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page

Reply via email to