NSLU2-Linux
view · edit · print · history

Preamble

Maintenance mode is a concept that is only found when using Unslung 3.x -> 4.x custom firmware, not the standard Linksys firmware or OpenSlug.

If you're running standard Linksys firmware, then you can always just use the basic web interface for firmware upgrades - there is no need to worry about Maintenance Mode.

If you're running OpenSlug, you're on your own. ;-)

What is Maintenance Mode?

With Unslung installed in an NSLU2, upgrades must be done with no hard drives attached. When the NSLU2 has no hard drives attached, additional preparations must be made to allow upgrading to a new firmware via the web interface. With these additional preparations in place, it will make sure the flash memory isn't used for anything else, which could otherwise conflict with writing the new firmware to it. This is Maintenace Mode.

Once you are running the custom Unslung firmware, you need to be aware of Maintenance Mode, or use another method such as RedBoot Upgrade Mode to install new firmware.

Maintenance Mode was removed from Unslung starting with version 5.x and replaced with Upgrade Mode.

The 4.x cosmetic issue:

Unslung 4.x might show "Maintenance Mode" and the little "Exit Maintenance mode" button on the firmware webpage when running with a hard disk - this is a cosmetic bug. Please ignore this. There is no need to try to exit the maintenance mode.

More technical background:

Maintenance mode (the real one, not the pseudo-one which the web pages says is in place just because you are running from external rootfs) is a pivot to a ramdisk copy of the jffs2 rootfs, which then allows the jffs2 to become idle and to be reflashed.

The stock firmware doesn't require maintenance mode in order to do the upgrade, but Unslung firmware does. This is because the stock firmware is always running from a ramdisk. That's why we get 10MB more free RAM running Unslung firmware. The cost of getting that extra RAM in normal usage is an extra hurdle when upgrading.

One of the big additions in Unslung 4.x was the replacement of switchbox with a direct pivot_root in the jffs2 /linuxrc. This freed up at least another 1MB of RAM over and above the 10MB or so of RAM that the Unslung firmware already freed up compared to the Linksys firmware.

However, it seems that the removal of switchbox has meant that the firmware upgrade maintenance mode simply doesn't work in Unslung 4.x (it fails for an unknown reason somewhere in the middle of the Linksys upgrade.cgi binary for which we have no source code - so we have no way of debugging or fixing it).

Everything else in Unslung 4.x works as expected - it's just that firmware upgrades cannot be done via the web interface (they can still be done by one of the other couple of methods). So we still recommend all Unslung 3.x users upgrade to Unslung 4.x, so that they can take advantage of the extra RAM which is made available to packages. But stay away from maintenance mode in Unslung 4.x (don't enter it, and don't exit it - just leave it alone).

Since freeing up RAM whilst still retaining Linksys run-time functionality is a key goal of the Unslung firmware, then the assertion from the development team is that the benefit of 1MB more RAM for packages is worth the inconvenience of giving up the web-based firmware upgrade system (and requiring the use of one of the other firmware upgrade mechanisms).

Important:

Before you upgrade your firmware, make sure to follow the README instructions by the letter. This will include booting without disk attached, and then going into Maintenance mode. The README doesn't contain any advice to exit Maintenance mode, because it is never necessary.

(source : adapted from http://groups.yahoo.com/group/nslu2-linux/message/6754)

view · edit · print · history · Last edited by barrym.
Based on work by barrym and kaste.
Originally by roo_at_magma_ca.
Page last modified on June 10, 2005, at 04:11 PM