LFS 6.3 - Chapter 8.4 - Cannot install grub

Rafael Lopez rafa2005ar at gmail.com
Thu Jun 19 11:23:41 PDT 2008

2008/6/19, Dan Nicholson <dbn.lists at gmail.com>:
> Are you bind mounting the /dev partition when you enter the chroot? If
> you can't see /dev/hd* from within the chroot, then neither can grub
> and it can't determine your partition layout. Grub keeps your list of
> partitions in the file /boot/grub/device.map.
> To just have grub write the device.map file, run the command "echo
> quit | grub --batch".
> --
> Dan
> --
> http://linuxfromscratch.org/mailman/listinfo/lfs-support
> FAQ: http://www.linuxfromscratch.org/lfs/faq.html
> Unsubscribe: See the above information page

Hi you there. Thank you for your support !!

I´m not sure what exactly is unsderstood by "bind mounting" (yes, I'm
such a newby....).
But I can explain what I do when going to work on my LFS project at
presente stage of building.
What I do is to follow a procedure taken from the hint "How to resume
your work after a break at different LFS stages" at
in paragraph "From section 6.62. Cleaning Up to The End" to resume the
building environment:

1. Restart computer and boot from LFS LiveCD
2. Mount lfs partition
        export LFS=/mnt/lfs
        mkdir -pv $LFS
        mount /dev/hda1 $LFS
2a. Mount /home
        mount /dev/hda3 /home
3. Mount swap partition
        swapon /dev/hda2
4. Mount the virtual kernel filesystems
        mount -vt proc proc $LFS/proc
        mount -vt sysfs sysfs $LFS/sys
5. Entering the chroot environment
        chroot "$LFS" /usr/bin/env -i \
        HOME=/root TERM="$TERM" PS1='\u:\w\$ ' \
         PATH=/bin:/usr/bin:/sbin:/usr/sbin \
        /bin/bash --login
6. Populating /dev
        mount -nvt tmpfs none /dev
        mkdir -v /dev/pts
        mkdir -v /dev/shm
        mount -vt devpts -o gid=4,mode=620 none /dev/pts
        mount -vt tmpfs none /dev/shm
7. Entering your working directory
        cd /sources

Is said procedure performing any "bind mounting" of /dev? I guess not.

Looking around a little I found out that I should be using <mount
--bind olddir newdir> somewhere along the said procedure, most
probably inmediatly BEFORE entering chroot.
What is gonna be olddir?. And newdir?

Thanks a lot, indeed, in advance.
Bye by now, Rafael

More information about the lfs-support mailing list