[bb xm rev. C with ubuntu 12.04] - NFS rootfs mount not working

Hi all,

I know this is a common problem but I have not been able to find a solution so far.

I installed ubuntu 12.04 on my sd card, using RobertCNelson scripts. All works fine from SD card.

Now I need to have the rootfs on my host pc and I want BB xm kernel mounting it via nfs at boot time.

The kernel itself is downloaded by u-boot via tftp. Same goes for the initrd.img. This initrd.img is a custom one. I picked the original one found on sd card after running RobertCNelson installation script and I updated it in order to contain the smsc95xx module, needed for usb-ethernet card.

The nfs share is working fine. I can mount it from another ubuntu host with the command: sudo mount -t nfs -o ro /home/daniele/nfs-test

By the way, this is the relevant part of my /etc/exports file:


This is my uEnv.txt file:

Hi Daniele,

The first thing that comes to mind is whether you have CONFIG_ROOT_NFS
built into your kernel.[1]

This may be of help:

And also this:

Here's what I do to boot my beagle bone over NFS:

dcache off
setenv ipaddr
setenv serverip
tftpboot 0x80007fc0
setenv bootargs console=ttyO0,115200n8 root=/dev/nfs
nfsroot= rw ip=
bootm 0x80007fc0

Maybe you can find some clues in the above.


[1] In menuconfig:
    File systems ->
      Network File Systems ->
        * NFS Client Support
        * (I then have version 3 and 4 turned on)
        * Root File System on NFS

Make the above options built-in, _not_ modules.

Hi Alan,

thanks for the prompt reply.

I managed to fix this problem. I recompiled the kernel enabling as built-in the smsc95xx driver (CONFIG_USB_NET_SMSC95XX=y). Then I removed initrd from boot process editing the uEnv.txt.

By the way it’s true what your link suggests. Ubuntu with rootfs over nfs doesn’t like initrd, even if it contains proper drivers for mounting rootfs.

I leave my uEnv.txt as a reference, maybe it can helps someone else.