Linux From Scratch (LFS)

(V039a-20210507). This site is managed by VauLSMorg (vlsm.org) since 2020.
May the fork() be with Jolan Tru! --- operatingsystems (@T) vlsm dot org.

View on GitHub

HOME ABOUT WEB GITHUB TOP BOTTOM PREV NEXT


LFS: Chapter 7 part 3 - 4.

ssh -p 6023 lfs@localhost

su -

ls -al $LFS/


Mounting and Populating /dev

mount -v --bind /dev $LFS/dev

mount -v --bind /dev/pts $LFS/dev/pts
mount -vt proc proc $LFS/proc
mount -vt sysfs sysfs $LFS/sys
mount -vt tmpfs tmpfs $LFS/run

if [ -h $LFS/dev/shm ]; then
  mkdir -pv $LFS/$(readlink $LFS/dev/shm)
fi


Entering the Chroot Environment

df
sleep 1
ls -F /dev/ 
sleep 1
ls -F $LFS/dev/

chroot "$LFS" /usr/bin/env -i          \
    HOME=/root                         \
    TERM="$TERM"                       \
    PS1='(lfs chroot) \u:\w\$ '        \
    PATH=/bin:/usr/bin:/sbin:/usr/sbin \
    MAKEFLAGS='-j6'                    \
    /bin/bash --login +h


Testing

sleep 1
df
sleep 1
ls -F /dev/
echo "#####      This SHOULD NOT exists!    ##### #####"
ls -F /mnt/lfs/dev/


Go back to where-ever you came from (eg. chapter 7 part 5, or more)


ENDOFPAGE

HOME ABOUT WEB GITHUB TOP BOTTOM PREV NEXT