MIPs Multilib network boot panics when looking for init

Michael J. Hammel cross-lfs at graphics-muse.org
Wed Jan 18 16:53:03 PST 2006


I'm kinda stuck on this one - was hoping someone could point me in the
right direction.  The boot fails trying to launch an init program.  I've
tried the defaults (/sbin/init and friends) and also tried init=/tools-
mips/bin/bash (the fully qualified location for the bash program in the
temporary tools directory) but they all give me the same error.  It
seems like the loader isn't finding the libraries it needs.  I tried
symlinking /lib{,32,64} and /usr/lib{,32,64} to their counterparts
under /tools-mips, but that didn't change anything.

I seem to have everything in place for a NFS based rootfs boot as far as
CLFS is concerned, but the kernel panics when trying to launch init:

[4294669.328000] IP-Config: Complete:
[4294669.329000]       device=eth0, addr=172.22.251.219,
mask=255.255.255.0, gw=255.255.255.255,
[4294669.333000]      host=172.22.251.219, domain=, nis-domain=(none),
[4294669.334000]      bootserver=172.22.250.84,
rootserver=172.22.251.154, rootpath=/mnt/lfs-mips
[4294669.337000] Looking up port of RPC 100003/2 on 172.22.251.154
[4294669.339000] Looking up port of RPC 100005/1 on 172.22.251.154
[4294669.347000] VFS: Mounted root (nfs filesystem) readonly.
[4294669.348000] Freeing unused kernel memory: 192k freed
[4294669.358000] Kernel panic - not syncing: No init found.  Try passing
init= option to kernel.

/sbin/init exists in the mount point:
mjhammel(tty5)$ ls -l /mnt/lfs-mips/sbin/init
-rwxr-xr-x  1 root root 44336 Jan 18 16:43 /mnt/lfs-mips/sbin/init

And it appears to be the right kind of file (built with -meb -mabi=64 -
mtune=sb1 -march=mips64 for a Broadcom Bigsur board:
mjhammel(tty5)$ file /mnt/lfs-mips/sbin/init
/mnt/lfs-mips/sbin/init: ELF 64-bit MSB MIPS32 executable, MIPS, version
1 (SYSV), for GNU/Linux 2.6.0, dynamically linked (uses shared libs),
stripped

The symlinks for the gcc lib are in place:
mjhammel(tty5)$ l -L /mnt/lfs-mips/usr/lib{,32,64}/libgcc*
-rw-r--r--  1 lfs lfs 387163 Jan 18 16:05 /mnt/lfs-
mips/usr/lib32/libgcc_s.so
-rw-r--r--  1 lfs lfs 387163 Jan 18 16:05 /mnt/lfs-
mips/usr/lib32/libgcc_s.so.1
-rw-r--r--  1 lfs lfs 545503 Jan 18 16:05 /mnt/lfs-
mips/usr/lib64/libgcc_s.so
-rw-r--r--  1 lfs lfs 545503 Jan 18 16:05 /mnt/lfs-
mips/usr/lib64/libgcc_s.so.1
-rw-r--r--  1 lfs lfs 340137 Jan 18 16:05 /mnt/lfs-
mips/usr/lib/libgcc_s.so
-rw-r--r--  1 lfs lfs 340137 Jan 18 16:05 /mnt/lfs-
mips/usr/lib/libgcc_s.so.1

And these are also the right kinds of files:
mjhammel(tty5)$ file -L /mnt/lfs-mips/usr/lib{,32,64}/libgcc*
/mnt/lfs-mips/usr/lib/libgcc_s.so:     ELF 32-bit MSB MIPS32 shared
object, MIPS, version 1 (SYSV), not stripped
/mnt/lfs-mips/usr/lib/libgcc_s.so.1:   ELF 32-bit MSB MIPS32 shared
object, MIPS, version 1 (SYSV), not stripped
/mnt/lfs-mips/usr/lib32/libgcc_s.so:   ELF 32-bit N32 MSB MIPS32 shared
object, MIPS, version 1 (SYSV), not stripped
/mnt/lfs-mips/usr/lib32/libgcc_s.so.1: ELF 32-bit N32 MSB MIPS32 shared
object, MIPS, version 1 (SYSV), not stripped
/mnt/lfs-mips/usr/lib64/libgcc_s.so:   ELF 64-bit MSB MIPS32 shared
object, MIPS, version 1 (SYSV), not stripped
/mnt/lfs-mips/usr/lib64/libgcc_s.so.1: ELF 64-bit MSB MIPS32 shared
object, MIPS, version 1 (SYSV), not stripped

And the temporary binutils (CLFS 6.3) was built with the specified
options (so they look under /tools, or rather /tools-mips in my case):
/configure --prefix=$(WD) \
            --libdir=$(WD)/lib64 --with-lib-path=$(WD)/lib \
            --build=$(LFS_HOST) --host=$(LFS_TARGET) --target=
$(LFS_TARGET) \
            --disable-nls --enable-shared --enable-64-bit-bfd 

where $(WD) = /tools-mips, as was sysvinit:

      sed -e 's at root@0 at g' \
         -e "s@/dev/initctl@$(LFSMP)&@g" \
         -e 's@\(mknod \)-m \([0-9]* \)\(.* \)p@\1\3p; chmod \2\3 at g' \
         -e "s@/usr/lib@$(WD)/lib@" \
         src/Makefile.orig > src/Makefile 

where LFSMP = /mnt/lfs-mips

What else should I look for here?

-- 
Michael J. Hammel <cross-lfs at graphics-muse.org>




More information about the cross-lfs mailing list