NSLU2-Linux
view · edit · print · history

The SlugOS (DebianSlug, OpenSlug) Binary

Current Version: 3.10
Aliases: OpenSlug and DebianSlug

Introduction

The binary is intended to be loaded ('flashed') into the flash ROM of a supported device. The original target for SlugOS is the LinkSys NSLU2, but more experienced users might flash one of the following devices:

SlugOS will not work on anything else.

Because the binary flash image only contains a minimal set of programs necessary to boot SlugOS, one of the following devices is needed in order to install packages onto the device and make SlugOS useful:

  • External Hard Disk
  • Flash Disk
  • NFS Export from another Linux machine

NOTE: Flashing the ROM of an NSLU2 removes the original Linksys supported code. Data on any hard disk or flash disk is retained, unchanged, but programs on the disk from other distributions (such as UnSlung) will almost certainly not be usable after the change.

NOTE: Synology DS101: By 13 Jun 2006, Flash ROM isn't supported, so writing a permanent kernel and root fs is currently not possible. However, user may try to boot the DS101 with a new kernel by uploading it to the RedBoot over serial cable or from a tftp-server on every boot.

NOTE: If you are upgrading from a previous version of SlugOS please refer to: UpgradingOpenSlugToANewRelease.

Available packages

SlugOS is built using the OpenEmbedded build system. This system currently includes over 1000 separate packages of which approximately 100 are known to build for SlugOS and are included in the SlugOS feeds. Please note that many packages have not been fully tested, so if you encounter any problems, please report them to the custom firmware mailing list.

The SlugOS operating system

SlugOS 3.10 is based on Linux 2.6.16. It is a 'regular' Linux operating system and should be familiar territory for anyone who has used any similar operating system. It is a full Linux operating system. You should either be confident that you can set up such an operating system or be prepared to spend some time learning. This wiki does not contain enough to teach you how to set up the operating system.

Prerequisites

  • Windows, Linux or MacOS computer
    • OS-specific Flashing Software (details below)
    • An SSH client -- SSH is the only way to make the initial connection to SlugOS
  • Ethernet Network
  • An NSLU2 (or compatible device)
  • SlugOS Binary image

Windows

  1. Install Sercomm's Win32 Update Utility.
    • This tool can locate the slug on the network even if it isn't on the same subnet, and even when the Linksys tool cannot locate the slug.
    • If you are running Windows XP or Vista, make sure your Windows Firewall is off
  2. Install an SSH client, such as PuTTY.

Linux

  1. Install UpSlug2 using a package for your distro, or build it from the sources. The UpSlug2 page has more information about available binary packages and setup instructions.
  2. Make sure your distribution has an SSH client, such as OpenSSH or Dropbear. Any Linux distro should have one of these.

Mac OS X

  1. Install UpSlug2 from source, as described in the UpSlug2 on Mac OS X page.
  2. Mac OS X already includes an ssh client from OpenSSH.

Preparing the NSLU2

If your NSLU2 is already in use on a network the basic network settings will be retained. The basic network settings are:

  1. The ethernet boot protocol - either a static IP address or DHCP.
  2. The hostname and (if specified) domain name.
  3. For a static IP address the address and the related servers. With DHCP this information is provided by the DHCP server.

If you have not used the NSLU2 you may find it convenient to use the Linksys setup software to initialize the above information and to verify that the machine is working correctly. Linksys technical support will be unable to help you once you have flashed SlugOS.

If you flash a machine which has not been used before the network setup will be as follows:

  1. The network will be configured via DHCP if a DHCP server is present
  2. otherwise it will have a static IP address which will be 192.168.1.77

If you have a DHCP server running, for instance a router, you can determine the assigned IP address from its DHCP clients table.

Flashing the NSLU2

  1. Download the SlugOS image from http://www.slug-firmware.net
  2. Put the NSLU2 into Upgrade Mode
    1. Disconnect any disks and/or devices from the USB ports.
    2. Power off the NSLU2
    3. Press and hold the reset button (accessible through the small hole on the back just above the power input).
    4. Press and release the power button to power on the NSLU2.
    5. Wait for 10 seconds watching the ready/status LED. After 10 seconds it will change from amber to red. Immediately release the reset button.
    6. The NSLU2 ready/status LED will flash alternately red/green (there is a 1 second delay before the first green).
  3. Flash the NSLU2 by using UpSlug2 or the Win32 Sercomm Utility

NOTE: Slugs produced October 2006 or later will not display a red status LED color, but instead a darker orange nuance, which may not be clearly distinguishable depending on the light conditions. Carrying out the procedure in a darkened room makes it easier to tell when the light changes. The procedure to enter the upgrade mode is just the same as described above, but you have to eye the status LED more carefully to get the right moment for releasing the reset button.

NOTE: If you decide not to flash the image the NSLU2 can be rebooted by disconnecting the power. If the ready/status LED does not turn green after step (4) it will remain red for several seconds then flash amber. This happens if you do not release the reset button in time - pull the power, reconnect it and repeat from step (2).

NOTE: Once the NSLU2 is in upgrade mode it will remain in this state until either the power is disconnected or a new image has been flashed. If the flash fails the NSLU2 will (eventually) return to upgrade mode - the flash can be retried from UpSlug2 or the Sercomm utilty.

NOTE: You can monitor the progress of the flash by watching your UpSlug2 session. You can also keep an eye on the Ethernet led on the NSLU2 - any activity you see is the transmission of the binary.

NOTE: If you run this tool over wifi and it fails with the error "no NSLU2 machines found in upgrade mode" then try connecting to the network with a wire.

After Flashing / Initialization

  1. After a successful flash the NSLU2 will reboot. SlugOS uses the ready/status LED to indicate boot progress. The LED sequence is described in more detail in OpenSlugLEDsDuringBoot. (Note: The first boot will take some time, around five minutes.)
    • Amber: control is within the RedBoot boot loader or the early stage of the Linux kernel boot.
    • Red: the NSLU2 will beep when the LED turns red. This happens at the middle stage of the kernel boot when the LED driver is loaded.
    • Flashing amber: initial user space boot.
    • Alternate amber/green: final user space boot.
    • Green: the system has booted and log in should be possible.
  2. Once the ready/status LED is green, SSH into the NSLU2 as 'root'
  3. Follow the SlugOS initialization as described in InitialisingOpenSlug
  4. Install Packages and Enjoy!

After Initialization

After the initialization you can use ipkg to download and install software.

NOTE: If you want to serve the NSLU2's disks to a Windows network, you'll want to install and configure Samba by following the instructions at GettingStartedWithSamba.

NOTE: If you want to serve NFS from the slug follow the instructions at InstallNFS.

view · edit · print · history · Last edited by kyle.
Based on work by thx1011, Tobias Balle-Peresen, fcarolo, anonymous, marXman, Mannkind, Shaunp, hwdb, Peter Hartzler, Alex Chan, rwhitby, eFfeM, and repvik.
Originally by rwhitby.
Page last modified on February 07, 2010, at 08:16 PM