LeapFrog Pollux Platform: Mount NFS Directory

From eLinux.org
Revision as of 18:14, 23 August 2010 by Reggie (talk | contribs) (mount nfs shares from host PC on your leapster explorer)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

This is a tutorial to setup a static IP address on your explorer, the explorer g_ether gadget and then use this to mount an NFS folder from your host PC on your explorer. doing this will enable you to test applications/scripts without having to copy anything to your explorer, its going to be fairly slow so your mileage may vary.

1. setup a network between the explorer and your host system

You can start the explorer and have it default to a static IP address by simply holding down the brightness button at boot time. Simply edit /etc/init.d/networking, look for any place there is an IP address and replace it with yours, you should also change the bit after the slash to set your netmask), edit lines 32 and 41:

 ifconfig usb0

and make them look like this:

 ifconfig usb0 netmask

Now plug in a mini usb cable and Reboot and as soon as you see: Emerald Base: Starting /etc/init.d/networking ... Emerald Base: /etc/init.d/networking: Holding brightness: forcing static IP

on the console then it is safe to let go.

You can make this permanent so that you don't have to hold down brightness by removing the avahi flag:

 rm /flags/avahi

now reboot and you will get your static IP address assigned

2. Configure the host

Once this is done you need to configure the host:

I'm using ubuntu 10.04, it has a automatic configuration, I've set mine so that auto usb0 has the ipv4, method setting of 'local-link only' and in auto eth2 I have hardcoded the ip address to, netmask, gateway of

to setup the nfs stuff, follow this simple tutorial:


3. Configure the explorer

then on the explorer you need to edit /usr/bin/mountnfs, change:

 mount -o nolock `get-ip host`:/home/lfu/nfsroot/LF /LF


 mount -o nolock /mnt

once you've done that, do:

 modprobe nfs
 cd /mnt

and you should see the contents of your /home dir

4. things to note

obviously you can set whatever folder you like on the host as an nfs share and mount it to any folder you like on the explorer or make a new dir, just make sure you edit /etc/exports on the host and /usr/bin/mountnfs accordingly, so for instance if I want to use /home/didj then on the host machine I would edit /etc/exports and either edit the existing one or add the line:

 /home/didj    *(rw,sync,no_root_squash)

and edit /usr/bin/mountnfs, either add another line or edit the existing one:

 mount -o nolock /LF/test

you could quite easily at this stage make a /LF/test/bin folder, add that to your path environment variable and run any script/app you have made/compiled for the explorer without having to copy it to the first.

next up will be mounting a rootfs via NFS :)