131-network error

James Robertson jwrober at gmail.com
Fri Aug 28 14:13:03 PDT 2009

Spahn, Daniel wrote:
> -----Original Message-----
> From: alfs-discuss-bounces at linuxfromscratch.org [mailto:alfs-discuss-bounces at linuxfromscratch.org] On Behalf Of James Robertson
> Sent: Friday, August 28, 2009 4:09 PM
> To: alfs-discuss at linuxfromscratch.org
> Subject: 131-network error
> I am new to jhalfs, so please bear with me.  I am working on using 
> jhalfs to build a custom server personal "distro" for my IT shop.  I am 
> starting with stock jhalfs 2.3.2 running commands for the 6.5 book on a 
> stock 6.4 host to start off with.
> I get this error at step 131-network
> Building target 131-network
> make: *** [131-network] Error 2
> make: *** [mk_BOOT] Error 2
> when I look at the logs\131-network file I see this error
> unable to open device '/sys/class/net/*'
> I can ls that on my host though
> ls -l /sys/class/net
> total 0
> lrwxrwxrwx 1 root root 0 2009-08-28 15:01 eth0 -> 
> ../../devices/pci0000:00/0000:00:0a.0/net/eth0
> lrwxrwxrwx 1 root root 0 2009-08-28 09:09 lo -> ../../devices/virtual/net/lo
> lrwxrwxrwx 1 root root 0 2009-08-28 09:09 sit0 -> 
> ../../devices/virtual/net/sit0
> How can I see what the CHROOT environment sees with respect to this?  I 
> see in the Makefile where the mounts happen for chroot
> devices: ck_LFS ck_UID
>         sudo mount -v --bind /dev $(LFS)/dev
>         sudo mount -vt devpts devpts $(LFS)/dev/pts
>         sudo mount -vt tmpfs shm $(LFS)/dev/shm
>         sudo mount -vt proc proc $(LFS)/proc
>         sudo mount -vt sysfs sysfs $(LFS)/sys
> Any ideas?
> Thanks
> James
> Usually when I see that in other linuxes, it means I didn't mount/bind /dev. In the chroot look at the contents of /sys/class and see if the net folder was named something else. What is your host OS?
Host O/S is LFS 6.4.  I did some more digging after I sent my initial 
email.  I ran "make devices" and then "make all" again and it worked 
this time.  I am not sure why the "devices" target was not ran on the 
initial run.  By manually running the make devices target, the mount 
commands ran to get what I needed in the CHROOT for the udev commands in 

I think the Makefile needs some adjustments...

The all target does not seem to ever run the devices target.  The only 
target I can see that does is the chroot target.  And that target runs 
the same command as the environment variable CHROOT1 that would be used 
to compile ch6 packages.  My thinking is we need jhalfs to add "devices" 
and "teardown" to the all target like this:

all:    ck_UID mk_SETUP mk_LUSER mk_SUDO mk_CHROOT devices mk_BOOT 
create-sbu_du-report mk_CUSTOM_TOOLS mk_BLFS_TOOL teardown

Alternatively we could add the devices target to the mk_BOOT target:

mk_BOOT: mk_CHROOT devices

I am going to run a complete test tonight with the first idea to see 
what happens.


More information about the alfs-discuss mailing list