NSLU2-Linux
view · edit · print · history

First you need to have RedBoot access - you can either AddASerialPort or TelnetIntoRedBoot.

If you have an 8MB image file, then you need to SplitAnImageIntoPartsUsingSlugTool. When the ramdisk.gz comes from an image that uses a FIS directory, the procedure below will not work. It is however still possible to test an updated kernel by loading it into RAM before reflashing. A proper ramdisk.gz will have the following signature when classified by file:

Linux Compressed ROM File System data, big endian

Once you have the vmlinuz and ramdisk.gz files, you need to load them onto a TFTP server or HTTP server on the same LAN as the slug (192.168.1.X for serial example, 192.168.0.X if using TelnetIntoRedBoot). How to do that is left as an exercise for the reader.

You should also note the checksum of each file using the cksum command.

The following assumes that the IP address of your slug is 192.168.1.77 and the IP address of your TFTP or HTTP server is 192.168.1.2 - change the addresses in the following command to suit your LAN IP address allocations. It also assumes that you have put the files in the root directory of your TFTP server or HTTP server.

First, you need to tell the slug about your LAN:

ip_address -l 192.168.1.77 -h 192.168.1.2

Then you load the ramdisk into RAM at 0x01000000 (this is where the bootloader expects to find it).

If you have a TFTP server, use this command:

load -r -v -b 0x01000000 ramdisk.gz

If you have a HTTP server, use this command:

load -r -v -b 0x01000000 -m http /ramdisk.gz

If you find that the system hangs during loading, then remove the -v option. Its only purpose is to show a 'rotating dash' during loading.

Then verify the checksum of the ramdisk:

cksum

Then you load the kernel into RAM at 0x01d00000 (this is where the bootloader expects to find it).

If you have a TFTP server, use this command:

load -r -v -b 0x01d00000 vmlinuz

If you have a HTTP server, use this command:

load -r -v -b 0x01d00000 -m http /vmlinuz

Then verify the checksum of the kernel:

cksum

The last step is to start execution of the kernel:

exec 0x01d00000

This should boot the kernel, which should load the ramdisk. Note that during this procedure you have not modified the flash memory at all, so you will have to do this all again if you cycle the power. This is a good thing if the image is broken (as the slug will just reboot from the good image in flash). It is strongly suggested that you always test an image in RAM before flashing it (unless you know for sure that the image is good).

view · edit · print · history · Last edited by pepijn.
Based on work by peecock41, tman, snhenson, ka6sox, and rwhitby.
Originally by rwhitby.
Page last modified on March 25, 2006, at 03:08 PM