UpSlug is a (Linux / MacOS? X / but not Windows - Windows users use SercommFirmwareUpdater) tool to flash your NSLU2 from an external computer on the same subnet (direct Ethernet access is needed; it won't work if you have routers or NAT devices between you and the NSLU2, though WiFi? via a wireless router is OK).
UpSlug has been verified to work with the NAS200, but you will have to use a NAS200 image of course, and you will have to use the -f option because NAS200 images don't have the SerComm signature (if you make a mistake, you can always do it again because the Redboot area in memory will not be overwritten as long as you use -u, not -U). This is great if you flashed the NAS200 with a bad image but you can still access Redboot through the serial port or via Telnet. Unfortunately it will not save you if you bricked your NAS200 by typing "flash" at the command prompt.
UpSlug2 is a completely rewritten version of this tool which is more robust and flexible, though it still requires an ethernet connection to the NSLU2.
Instructions to build are found here
The release at the time this page was last updated is 1.17 (of upslug.c).
UpSlug must be run as root or with the sudo command.
Switch the nslu2 into Upgrade mode
If you want to upgrade your slug without letting your NSLU2 reach the "running" state, you need to enter RedBoot upgrade mode. There are two ways to do this. First, you can interrupt RedBoot in the normal way described here and then type upgrade at the RedBoot prompt. If this fails (it can be difficult to get the timing right):
After these steps the slug will be in upgrade mode - the ready/status LED will flash alternately red and green. This continues until the slug is reset by the upload software.
UpSlug status and problems
The changes in release 1.14 of upslug.c are believed to fix the following problems:
Verification of the flash image is non-functional in this version, however this is fixed in 1.17 and later.
1.16 (and later) also fixes a problem on heavily loaded networks when responses from the NSLU2 may get dropped.
Even in 1.17 there are probably still errors in the protocol handling. UpSlug2 should fix all of these since the protocol return codes are verified correctly.
During download upslug outputs a progress indicator every 128KBytes. The indicator is a hexadecimal digit, thus the indicator goes through 4 cycles 0 to f for the 8MByte flash image.
The data is transmitted in 512 byte packets. If the NSLU2 does not acknowledge receipt of a packet it is retransmitted and a single * character is output.
Because the erase takes a long time a number of * characters are output initially (while upslug waits for response to the first write packet), then upslug outputs the message Writing flash and starts outputting progress digits.
If NSLU2 response packets are duplicated (resulting in an out of sequence response) upslug will output a + character and continue looking for the expected response packet (changed in 1.16).
The importance of upgrade mode
With the current OpenSlug, new (> v4.20 beta) Unslung versions the NSLU2 must be in upgrade mode before UpSlug can see it. This is because OpenSlug does not currently listen for the packets used in the upgrade protocol.
Problems with upslug
The following entries refer to problems with upslug which should now all be fixed. Please report any occurence of these problems with the latest (1.17) version, as well as any new problems!
This tool has worked consistently for several people. The support for multiple slugs seems to work as well.
Please post any issues that you have with this tool here
Verifying File Contents...
Error: File not large enough, use --upload-force to override
The image being loaded is built by oe.
I tracked this message down to the first call to
My slug was hosed after upslug crashed (blinking red light; I presume it was waiting for more data) but after spending a couple minutes emerging TFTP and fiddling with ifconfig (to move my server to the 192.168.0.* subnet where it was visible to the slug) I got unslung installed using the TFTP instructions. My thanks to all of you for figuring out all these methods! (mikeb)
Switching from a wireless NIC to a wired one fixed it. (dharple)
I'm not sure how we can do that...
[jbowler: UpSlug2 does this by checking the hardware ID - this comes out of the tail of the RedBoot partition when it is written by LinkSys?. This may cause UpSlug2 to fail to recognise some slugs, if they have a different ID.]
Got upslug to work
Even I used version 1.13 I still got Erasing Flash...upslug: Resource temporarily unavailable
I decided to fix it myself since my NSLU2 is not bootable anyway. I made some changes and it worked. upslug restored the firmware without any trouble. The major change is to ignore the error and let it continue to write.
I hacked upslug.c a little bit, below are the changes:
I compiled upslug under Redhat 7.2 and used it to flash firmware for my NSLU2 and it worked. I tar and gzip binary and source files to http://ctsai.erinna.com/upslug.tar.gz(approve sites). Would someone merge my changes to the source!
(jbowler: these changes, plus others, are in upslug 1.14)
For upslug -r to work, the download process must be running. /etc/rc.d/rc.1 should start it, but - at least in my environment - this is commented out. I did this a long time ago because I don't like the idea of an unsecured service that will reboot (and reflash) hardware. I think this is also true in the current release. In any case, if upslug reports
Finding Slugs... 0 found upslug: no slugs found, turkey problems?
and you have routes and cables properly configured, telnet into the slug and do a ps | grep download. If it's not running, ru /sbin/download to start it.
I tried using upslug2, and it didn't work for me. Upslug couldn't find the slug. I had the two machines connected directly via the ethernet port (no hub or router), and the slug was flashing red/green.
view · edit · print · history · Last edited by bcrowell.
Based on work by Jac Goudsmit, anonymous, dharple, tlhackque, ironstorm, frankvh, vapier, Phil Endecott, jbowler, tman, ilg, ChrisE, C Tsai, Cory Sharp, rwhitby, MikeB, devil26, dyoung, ka6sox, g2, jkpeters_37, and kolla.
Originally by rwhitby.
Page last modified on February 13, 2009, at 11:17 PM