diff options
-rw-r--r-- | BitKeeper/etc/logging_ok | 2 | ||||
-rw-r--r-- | conf/distro/openslug.conf | 8 | ||||
-rw-r--r-- | conf/distro/unslung.conf | 4 | ||||
-rw-r--r-- | packages/cpio/files/install.patch | 61 | ||||
-rw-r--r-- | packages/linux/openslug-kernel-2.6.9/alignment.patch | 0 | ||||
-rw-r--r-- | packages/linux/openslug-kernel-2.6.9/usbnet.patch | 0 | ||||
-rw-r--r-- | packages/linux/openslug-kernel_2.6.9.bb | 4 | ||||
-rw-r--r-- | packages/nslu2-binary-only/unslung-rootfs-2.3r25/NOTES | 0 | ||||
-rw-r--r-- | packages/nslu2-binary-only/unslung-rootfs-2.3r25/README | 497 | ||||
-rw-r--r-- | packages/nslu2-binary-only/unslung-rootfs-2.3r25/unsling | 86 | ||||
-rw-r--r-- | packages/nslu2-binary-only/unslung-standard-rootfs_2.3r25.bb | 8 | ||||
-rw-r--r-- | packages/openslug-init/openslug-init-0.10/kern_header.c | 0 | ||||
-rw-r--r-- | packages/openslug-init/openslug-init-0.10/sysconfsetup | 34 | ||||
-rw-r--r-- | packages/openslug-init/openslug-init_0.10.bb | 29 |
14 files changed, 368 insertions, 365 deletions
diff --git a/BitKeeper/etc/logging_ok b/BitKeeper/etc/logging_ok index 7acd06a985..3cc3b0e206 100644 --- a/BitKeeper/etc/logging_ok +++ b/BitKeeper/etc/logging_ok @@ -1,3 +1,4 @@ +ByronT@jbt-portable. CodeWhacker@rant-central.com CoreDump@handhelds.org CoreDump@mhcln01.hentges.local @@ -6,6 +7,7 @@ a0868066@lta0868066.ent.ti.com anon@tim.rpsys.net br1@null.(none) buildroot@mithis.com +byrontodd@christy-todds-computer.local chris@chrislaptop.(none) chriz@i74-copy.(none) cwiiis@chris.(none) diff --git a/conf/distro/openslug.conf b/conf/distro/openslug.conf index 60e9976d49..73860298d7 100644 --- a/conf/distro/openslug.conf +++ b/conf/distro/openslug.conf @@ -2,8 +2,8 @@ #@NAME: OpenSlug #@DESCRIPTION: OpenSlug Linux Distribution for the NSLU2 -TARGET_FPU ?= "soft" -TARGET_OS ?= "linux" +TARGET_FPU = "soft" +TARGET_OS = "linux" USE_NLS ?= "no" @@ -14,13 +14,13 @@ IMAGE_FSTYPES = "jffs2" OPENSLUG_DEVICE_TABLE = "${@bb.which(bb.data.getVar('BBPATH', d, 1), 'files/device_table-nslu2.txt')}" EXTRA_IMAGECMD_jffs2 = "--pad --big-endian --eraseblock=0x20000 -D ${OPENSLUG_DEVICE_TABLE}" -OPENSLUG_EXTRA_DEPENDS += "virtual/kernel module-init-tools" +OPENSLUG_EXTRA_DEPENDS += "virtual/kernel module-init-tools mtd-utils" OPENSLUG_EXTRA_RDEPENDS += "kernel-module-usbnet kernel-module-usbserial \ kernel-module-usbcore kernel-module-usb-storage kernel-module-ohci-hcd \ kernel-module-pegasus kernel-module-p8022 kernel-module-kaweth \ kernel-module-ehci-hcd \ kernel-module-scsi-mod kernel-module-sd-mod kernel-module-ext3 kernel-module-jbd \ -module-init-tools" +module-init-tools mtd-utils" OPENSLUG_EXTRA_INSTALL += "${OPENSLUG_EXTRA_RDEPENDS}" diff --git a/conf/distro/unslung.conf b/conf/distro/unslung.conf index a389155b55..8108b2b767 100644 --- a/conf/distro/unslung.conf +++ b/conf/distro/unslung.conf @@ -4,8 +4,8 @@ FEED_URIS_unslung = "unslung##http://ipkg.nslu2-linux.org/feeds/unslung/unstable" -TARGET_FPU ?= "soft" -TARGET_OS ?= "linux" +TARGET_FPU = "soft" +TARGET_OS = "linux" INHERIT += " package_ipk nslu2_flashimg" diff --git a/packages/cpio/files/install.patch b/packages/cpio/files/install.patch index e69de29bb2..3554156ffc 100644 --- a/packages/cpio/files/install.patch +++ b/packages/cpio/files/install.patch @@ -0,0 +1,61 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- cpio-2.5/Makefile.in~install.patch ++++ cpio-2.5/Makefile.in +@@ -70,6 +70,7 @@ + # Prefix for each installed man page, normally empty or `g'. + manprefix = + ++DESTDIR = + + # Where to install the cpio and mt executables. + bindir = @bindir@ +@@ -123,19 +124,19 @@ + $(CC) -c $(CPPFLAGS) $(DEFS) -I$(srcdir) $(CFLAGS) $< + + install:: installdirs all $(srcdir)/cpio.1 $(srcdir)/mt.1 +- $(INSTALL_PROGRAM) cpio $(bindir)/$(binprefix)cpio +- test ! -f mt || $(INSTALL_PROGRAM) mt $(bindir)/$(binprefix)mt +- -test ! -f rmt || $(INSTALL_PROGRAM) rmt $(libexecdir)/rmt +- -$(INSTALL_DATA) $(srcdir)/cpio.1 $(mandir)/$(manprefix)cpio.$(manext) +- -test ! -f mt || $(INSTALL_DATA) $(srcdir)/mt.1 $(mandir)/$(manprefix)mt.$(manext) ++ $(INSTALL_PROGRAM) -D cpio $(DESTDIR)$(bindir)/$(binprefix)cpio ++ test ! -f mt || $(INSTALL_PROGRAM) -D mt $(DESTDIR)$(bindir)/$(binprefix)mt ++ -test ! -f rmt || $(INSTALL_PROGRAM) -D rmt $(DESTDIR)$(libexecdir)/rmt ++ -$(INSTALL_DATA) -D $(srcdir)/cpio.1 $(DESTDIR)$(mandir)/$(manprefix)cpio.$(manext) ++ -test ! -f mt || $(INSTALL_DATA) -D $(srcdir)/mt.1 $(DESTDIR)$(mandir)/$(manprefix)mt.$(manext) + + installdirs: +- $(srcdir)/mkinstalldirs $(bindir) $(libexecdir) $(mandir) $(infodir) ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(bindir) $(DESTDIR)/$(libexecdir) $(DESTDIR)/$(mandir) $(DESTDIR)/$(infodir) + + uninstall:: +- cd $(bindir); rm -f $(binprefix)cpio $(binprefix)mt +- -rm -f $(libexecdir)/rmt +- cd $(mandir); rm -f $(manprefix)cpio.$(manext) $(manprefix)mt.$(manext) ++ cd $(DESTDIR)$(bindir); rm -f $(binprefix)cpio $(binprefix)mt ++ -rm -f $(DESTDIR)$(libexecdir)/rmt ++ cd $(DESTDIR)$(mandir); rm -f $(manprefix)cpio.$(manext) $(manprefix)mt.$(manext) + + check: + @echo No tests are supplied. +@@ -186,14 +187,14 @@ + + install-info: $(INFO_DEPS) + for file in *.info*; do \ +- $(INSTALL_DATA) $$file $(infodir)/$$file; \ ++ $(INSTALL_DATA) -D $$file $(DESTDIR)$(infodir)/$$file; \ + done + + uninstall:: uninstall-info + + uninstall-info: + for file in *.info*; do \ +- rm -f $(infodir)/$$file; \ ++ rm -f $(DESTDIR)$(infodir)/$$file; \ + done + + clean: diff --git a/packages/linux/openslug-kernel-2.6.9/alignment.patch b/packages/linux/openslug-kernel-2.6.9/alignment.patch new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/linux/openslug-kernel-2.6.9/alignment.patch diff --git a/packages/linux/openslug-kernel-2.6.9/usbnet.patch b/packages/linux/openslug-kernel-2.6.9/usbnet.patch new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/linux/openslug-kernel-2.6.9/usbnet.patch diff --git a/packages/linux/openslug-kernel_2.6.9.bb b/packages/linux/openslug-kernel_2.6.9.bb index 5b566b9efc..d1a59d85ce 100644 --- a/packages/linux/openslug-kernel_2.6.9.bb +++ b/packages/linux/openslug-kernel_2.6.9.bb @@ -2,13 +2,15 @@ SECTION = "kernel" DESCRIPTION = "Linux kernel for the Linksys NSLU2 device" LICENSE = "GPL" MAINTAINER = "Chris Larson <kergoth@handhelds.org>" -PR = "r1" +PR = "r2" KERNEL_SUFFIX = "openslug" SRC_URI = "ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-2.6.9.tar.bz2 \ file://nslu2_2.6.9.patch;patch=1 \ file://double_cpdo.patch;patch=1 \ + file://alignment.patch;patch=1 \ + file://usbnet.patch;patch=1 \ file://defconfig \ file://x1205-rtc.c \ file://nslu2-io.c \ diff --git a/packages/nslu2-binary-only/unslung-rootfs-2.3r25/NOTES b/packages/nslu2-binary-only/unslung-rootfs-2.3r25/NOTES new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/nslu2-binary-only/unslung-rootfs-2.3r25/NOTES diff --git a/packages/nslu2-binary-only/unslung-rootfs-2.3r25/README b/packages/nslu2-binary-only/unslung-rootfs-2.3r25/README index 1c1c9c1385..15b4acb970 100644 --- a/packages/nslu2-binary-only/unslung-rootfs-2.3r25/README +++ b/packages/nslu2-binary-only/unslung-rootfs-2.3r25/README @@ -1,41 +1,21 @@ -UNSLUNG-3.x family release README +UNLUNG-3.x Family Release README INSTALLATION -Unslung is a replacement firmware image for the Linksys NSLU2 which is -designed to allow you to make changes to the root filesystem -(including the installation of downloadable packages) while still -providing (almost) all the standard product functionality. +You must follow the steps in this README *exactly*. Do not skip any steps, and +do not skip ahead thinking you know what you are doing and don't need to follow +instructions step by step. -This is intended to be a way of distributing and loading new packages -for the NSLU2, with minimal changes to the standard user interface and -firmware. +If at any time you have any questions concerning the installation or operation +of Unslung firmware, your first port of call should be the NSLU2-Linux wiki at: -Note that you must follow the steps in this README *exactly*. Do not -skip any steps, and do not skip ahead thinking you know what you are -doing and don't need to follow instructions step by step. + http://www.nslu2-linux.org -If at any time you have any questions concerning the installation or -operation of Unslung firmware, your first port of call should be the -NSLU2-Linux wiki at: - - http://www.nslu2-linux.org - -In partiticular, there is a Frequently Asked Questions page, and also -quite a few Information and HowTo pages. Read them all before asking -questions on the mailing list or the IRC channel. - -The changes in the UNSLUNG 3.x firmware from the standard Linksys -2.3R25 can be found at: - - http://www.nslu2-linux.org/wiki/Unslung/UnslungStandard - -For more information about the Unslung firmware, including details on -how to build it from source code yourself, look at: - - http://www.nslu2-linux.org/wiki/Unslung +If you are looking for further Unslung notes - including ipkg usage, diversion +script details, or ChangeLog information, please consult the associated NOTES +file. ------------------------------------------------------------------------------- -There are three parts to completing the installation of the UNSLUNG firmware: +There are three parts to completing the installation of the Unslung firmware: 1 - PRE-INSTALLATION CONSIDERATIONS 2 - FIRMWARE INSTALLATION DETAILS @@ -44,377 +24,184 @@ There are three parts to completing the installation of the UNSLUNG firmware: PRE-INSTALLATION CONSIDERATIONS -1) It is strongly recommended that you test telnet Redboot access - first. See http://www.nslu2-linux.org/wiki/HowTo/TelnetIntoRedBoot - -2) Because you can now make changes to the root filesystem in the - internal flash storage, you no longer need to have an external - disk to use the Unslung firmware (except if you want to install - more than what can fit in the meagre spare space in the internal - flash storage). - -3) If you do want to use an external disk as the target for package - installation, then it is absolutely required that the disk is (or has - previously been) formatted by the NSLU2. It is possible to upgrade - from Unslung 1.x or Unslung 2.x to Unslung 3.x without reformatting - your disk. The unsling script will not touch anything in /unslung - or /opt on your disk, so make sure all your file modifications are - in those directories, as you were warned in the README file in - Unslung 1.x and Unslung 2.x :-) - - -FIRMWARE INSTALLATION DETAILS - -0) Please verify that any disks you are going to connect to the NSLU2 - are recognized and working properly *before* updating your - firmware. - - - The only exception to this, of course, are those enclosures - that the stock firmware does not support, but the Unslung - firmware does support. - -1) Shutdown the NSLU2, and remove any disks that you may have plugged - into the NSLU2. Power back up the NSLU2. - - - Firmware upgrades must always be performed with *no* hard disks - or flash disks attached. - -2) If you are installing Unslung 3.x onto an NSLU2 unit with Linksys - standard firmware *or* Unslung 1.x or 2.x, go to step 2-a. If you - are installing Unslung 3.x onto an NSLU2 unit with version 3.x already - installed, go to step 2-b. - - 2-a) Flash unslung-standard-3.x.bin as you normally would flash new - firmware (using the web interface "Upgrade Firmware" page). - - 2-b) You must put the NSLU2 into maintenance mode before you can - use the web interface to flash a new version. Just click the - "Enter Maintenance Mode" link on the web interface "Upgrade - Firmware" page, wait for the NSLU2 to reboot, and then flash - the new firmware in the normal manner. - - - The NSLU2 will reboot after the flashing is complete. - -3) Shutdown the NSLU2 (again), attach disk(s), and power it back up. - -4) Verify your NSLU2 is working normally again at this point - in the - web interface. In particular, you should ensure that all your disks are - still recognized as they were before you updated the firmware. - -5) Shutdown the NSLU2 and unplug *ALL* attached disks. - - - You must NOT have any disk plugged into the NSLU2 when you reboot - to perform the next part of installation - the "Unslinging". - - -'UNSLINGING' DETAILS - -0) Power up the NSLU2 without any disks connected. - - - This only has to be done when you update the firmware, and - because Unslung 3.x now runs completely from the internal flash - memory, it is no longer necessary to "unsling" to an external - disk unless you wish to store downloadable packages on that disk - - which you will probably want to do, because the internal flash - memory only has enough spare room for one or two very small packages. - - ***** To reiterate, you should not have a disk plugged in at this stage. - If you powered up your NSLU2 with a disk attached, shutdown the NSLU2, - unplug the disks, and power up again. - -1) Enable telnet by going to "http://192.168.1.77/Management/telnet.cgi", - and press the enable button. - - - If you had previously changed the IP address of your NSLU2 from - 192.168.1.77 to something else, then you should use that new IP - address to enable telnet. Also note that you should use the - username "admin" and password "admin" for the web interface at this - point (as no disks are attached, the default username and password - is the only way to access the Management web pages). - - - Make sure you have **** NO DISKS ATTACHED AT THIS TIME **** - - - If you plug a disk in before you complete the telnet connection, - then the NSLU2 will pick up the Linksys password from the disk, - and you will not be able to telnet into it. So don't have any - disks attached at this point. - - ***** Make sure you have **** NO DISKS ATTACHED AT THIS TIME **** - -2) OK, now that you don't have any disks attached, you can proceed and - telnet into the NSLU2 using the username root and password uNSLUng. - -3) Identify which drive you wish you "unsling", and plug it in. - Wait a minute or two while the disk is mounted. - - - If the disk has not been previously formatted on the NSLU2, then - now is the time to do that. Make sure that the drive is recognized - in the web interface. - -4) In the telnet session, run "/sbin/unsling". - - - Starting with Unslung 3.x, the external disk is no longer used for - the root filesystem, so only a few documentation files will be - copied to the "conf" partition (not the "data" partition). - - - Once you "unsling" to an external disk on a particular port (Disk 1 - or Disk 2), it is important that you keep that disk continually - plugged into that same port whenever the NSLU2 is turned on. - - ***** Unsling will not change the password on your disk, so if you had - previously changed the password on a disk, then your password will not - be changed. Also note that simply editing the /etc/passwd file is not - enough to permanently change a password. See the NSLU2 wiki for - more details. - -5) Reboot. - -***** Congratulations, you're now Unslung! ***** - -Make sure you add an entry to the "The Unslung 3.x" table in the Yahoo -group. Just use the next free integer for your Unslung number. - -If you make no further changes, your NSLU2 will continue to operate -normally. But to customize things, you'll be downloading packages and -adding stuff to the /unslung directory on the external disk (or even -in the internal flash memory) using diversion scripts. +1) It is strongly recommended that you test telnet Redboot access first. See + http://www.nslu2-linux.org/wiki/HowTo/TelnetIntoRedBoot -Read further to expand the capabilities of your uNSLUng NSLU2! Enjoy! + - Redboot is the bootloader that runs when the device is first started, + loading things into memory and starting Linux. By testing your + ability to telnet into Redboot, you are ensuring that if you injure + your NSLU2 with a bad flash (or with a bad diversion script) you + should be able to follow the "How To Recover From A Bad Flash" + instructions at ---------------------------------------------------------------------------------- + http://www.nslu2-linux.org/wiki/HowTo/RecoverFromABadFlash -If you "unsling" an external disk, then downloaded packages will be -installed onto that external disk. The number of packages that you -can install is only limited by the size of the "conf" partition on the -external disk. And if you run out of room on the "conf" partition, -you can always put symlinks across to the "data" partition too. +2) Because you can now make changes to the root filesystem in the internal + flash storage, you no longer need to have an external disk to use the + Unslung firmware (except if you want to install more than what can fit in + the meagre spare space in the internal flash storage). -If you are experienced with the Linux operating system, then you can -also make changes directly to the root filesystem, and these changes -are persistent across reboots. - -You are advised to use diversion scripts (see below) on an external -disk to modify the behaviour of the NSLU2 rather than editing system -files directly (as this will allow you to upgrade the Unslung firmware -in the future without having to make all your changes again). - -If you do need to edit system files directly, then you can use the -"resling" script to save and load your modified system files. - -DIVERSION SCRIPT DETAILS - -Diversion scripts go into /unslung (which is normally a symbolic link -to the unslung directory on the conf partition of an external disk). -You can divert as many or as few scripts as you like. Simply add the -name of the standard rc script into /unslung and it will be run. - -For example, I have a script /unslung/rc.local: - -#! /bin/sh -/opt/bin/do_foo -return 1 - -That will run at the beginning of the normal /etc/rc.d/rc.local, and then -the rest of the factory rc.local will be executed. If I do NOT want to run -the factory rc.local, my script would be - -#!/bin/sh -/opt/bin/do_foo -return 0 - -That is, if the diversion script returns with something other than 0, it will -run the rest of the factory script. - -Note that any variable definitions or function declarations are allowed to -happen before the diversion script is called. This allows you to use the -variables and functions defined by the factory script. - -PACKAGE INSTALLATION - -0) Note that you must have network connectivity to the package - repository at http://ipkg.nslu2-linux.org before proceeding. - You must also confirm that your DNS server address is set in the - web interface, or the NSLU2 will not be able to find the site. -1) Run "ipkg update" on the NSLU2. -2) Run "ipkg list" to see the available packages. -3) Run "ipkg install <package-name>" to install them. - -ADDITIONAL INFORMATION: - -1) The unsling firmware and associated scripts will never touch any - files under /unslung or /opt, so please store all your additional - files there. - -2) The diversion of startup scripts is done at the lowest granularity, - so you can, for instance, just divert the rc.xinetd script if you - want, and leave all the others unchanged. - -3) The diversion mechanism allows you to add to, or replace, the Linksys - script functionality. - -4) Note that telnet is not enabled by default - there is an openssh - package available to replace telnet access with secure shell - access. The rationale behind not enabling it by default is to - ensure that an NSLU2 with Unslung firmware has the same network - footprint as the standard firmware. - -5) This simple diversion script will enable telnet on boot - - [ Store the following in /unslung/rc.xinetd ] - - #!/bin/sh - echo "telnet stream tcp nowait root /usr/sbin/telnetd" > /etc/inetd.conf - # Additional lines must append (using >>), ie: - # echo "ftp stream tcp nowait root /usr/sbin/ftpd -a=passwd" >> /etc/inetd.conf - return 1 - -6) The Unslung firmware will automatically execute any scripts - which are in /opt/etc/init.d - and this is where any packages - put their startup scripts so that they execute on each boot. - -CHANGELOG: - -1.11: - -First public release - -1.12: - -Added a symlink to slingbox for gzip. Added flashfs (as simple utility for preserving -user files across hard disk formats during beta testing). - -1.13: - -Added LD_LIBRARY_PATH to /etc/profile (only works for telnet and ssh -access, not for serial or diversion scripts). - -1.14: - -Added Unslung Doc link to the User Guide page. - -2.3: - -Moved development to OpenEmbedded. - -2.4: - -Updated to the latest ipk binary instead of the simple script. - -2.5: - -Added the real wget (instead of using the busybox version). This is -so we can support .netrc files for commercial packages. - -2.6: - -Fixed the unsling script so it removes conflicting files on an upgrade. - -2.7: +3) If you do want to use an external disk as the target for package + installation, then it is absolutely required that the disk is (or has + previously been) formatted by the NSLU2. It is possible to upgrade from + UNSLUNG 1.x or UNSLUNG 2.x to UNSLUNG 3.x without reformatting your disk. + The unsling script will not touch anything in /unslung or /opt on your + disk, make sure all your file modifications are in those directories, as + you were warned in the README file in UNSLUNG 1.x and UNSLUNG 2.x :-) -Began development of the -able variant. +4) If you want to use a flash disk as the target for package installation, + ensure that it is larger than 256mb, plugged into port 1, and formatted + via the Linksys web interface. -2.8: +5) Please verify that any disks you are going to connect to the NSLU2 are + recognized and working properly *before* updating your firmware (including + any shares and data you had previously stored.) If not, DO NOT CONTINUE. + You may want to check out "How To Troubleshoot A Drive Missing Condition" + at: -Added the patch for genesys enclosures. + http://www.nslu2-linux.org/wiki/HowTo/TroubleshootADriveMissingCondition -2.9: + - The only exception to this, of course, are those enclosures that the + stock firmware does not support, but the Unslung firmware does + support. -Reorganised the various variants into a more consistent scheme. +6) If you are upgrading your firmware, you should make a configuration backup + via the Linksys web interface. The configuration backup can be found + under "Administration", "Advanced", and then "Backup." The top section of + that webpage is titled "Config Backup" and "Download" should be used to + save your NSLU2 Users, Groups and Shares setup to a disk file. -2.10: -Added the ext3flash-on-disk1 functionality. +FIRMWARE INSTALLATION DETAILS -2.11: +1) Shutdown the NSLU2, and remove any disks that you may have plugged into the + NSLU2. Power back up the NSLU2. -Added the README to /opt/doc. + - Firmware upgrades must always be performed with *no* hard disks or flash + disks attached. This CANNOT be emphasized enough. Are you sure you + unplugged the disks before powering up? If so, you may continue. -2.12: +2) If you are installing UNSLUNG 3.x onto an NSLU2 unit with Linksys standard + firmware *or* UNSLUNG 1.x or 2.x, go to step 2-a. If you are installing + Unslung 3.x onto an NSLU2 unit with version 3.x already installed, go to + step 2-b. -First public release of 2.x firmware. + 2-a) Flash unslung-standard-3.x.bin as you normally would flash new + firmware (using the web interface "Upgrade Firmware" page). -3.1: + 2-b) You must put the NSLU2 into maintenance mode before you can use the + web interface to flash a new version. Just click the "Enter + Maintenance Mode" link on the web interface "Upgrade Firmware" page, + wait for the NSLU2 to reboot, and then flash the new firmware in the + normal manner. -Added jffs2 functionality. + - During firmware flashing, the top LED - Ready/Status - flashes red and + green (approximately 5 minutes), and you should receive a Javascript + message that indicates that the flash of the firmware was successful. -3.2: + - The NSLU2 will reboot after the flashing is complete. -Incorporated switchbox functionality. +3) Shutdown the NSLU2 (again), attach disk(s), and power it back up. -3.3: +4) Verify your NSLU2 is working normally again at this point in the web + interface. In particular, you should ensure that all your disks are still + recognized as they were before you updated the firmware (including + any shares and data you had previously stored.) If not, DO NOT CONTINUE. + You may want to check out "How To Troubleshoot A Drive Missing Condition" + at: -Added ramdisks for /dev and /var to reduce internal flash writes. + http://www.nslu2-linux.org/wiki/HowTo/TroubleshootADriveMissingCondition -3.4: + - If you are not "unslinging", you can stop at this point. The only + reason for not unslinging would be in the case of a re-flash of the + SAME firmware. Even if this is a point firmware upgrade, you will + need to unsling. -Replaced flashfs script with new resling script. + ***** If you do not choose to do the unslinging procedure described below, + DO NOT install packages unless you are SURE you know what you are + doing! "Bricking" your NSLU2 by not unslinging is not just a + possibility, it is a probability. -3.5: +5) Shutdown the NSLU2 and unplug *ALL* attached disks. -Added code to reinitialise /etc/mtab on boot. + - You must NOT have any disk plugged into the NSLU2 when you reboot to + perform the next part of installation - the "Unslinging". -3.6: -Mounted /dev and /var jffs2 directories as /dev.state and /var.state -so that they can be used for persistent changes which are used to -populate the ramdisks on the next boot. +'UNSLINGING' DETAILS -3.7: +1) Power up the NSLU2 without any disks connected. -Added "Pluggable Personalities" - now runs diversion scripts from both -the internal jffs2 area and also from an external drive attached at -boot time. + - This only has to be done when you update the firmware, and because + UNSLUNG 3.x now runs completely from the internal flash memory, it is + no longer necessary to "unsling" to an external disk unless you wish + to store downloadable packages on that disk - which you will probably + want to do, because the internal flash memory only has enough spare + room for one or two very small packages. -3.8: + ***** To reiterate, you should not have a disk plugged in at this stage. + If you powered up your NSLU2 with a disk attached, shutdown the + NSLU2, unplug the disks, and power up again. -Enabled mounting of external drives earlier in the boot process, so -that the rc, rc.sysinit, and rc.1 scripts can be diverted by external -diversion scripts on an attached drive. +2) Enable telnet by going to "http://192.168.1.77/Management/telnet.cgi", and + press the enable button. -3.9: + - If you had previously changed the IP address of your NSLU2 from + 192.168.1.77 to something else, then you should use that new IP + address to enable telnet. Also note that you should use the username + "admin" and password "admin" for the web interface at this point (as + no disks are attached, the default username and password is the only + way to access the Management web pages). -Moved a number of -able kernel features (such as USB devfs support) -into -standard. + - Make sure you have **** NO DISKS ATTACHED AT THIS TIME **** -3.10: + - If you plug a disk in before you complete the telnet connection, then + the NSLU2 will pick up the Linksys password from the disk, and you + will not be able to telnet into it. So don't have any disks attached + at this point. -Added support for unslung-start and unslung-stop diversion scripts, -and package shutdown scripts (K??foo). + - Make sure you have **** NO DISKS ATTACHED AT THIS TIME **** -3.11: +3) OK, now that you don't have any disks attached, you can proceed and telnet + into the NSLU2 using the username root and password uNSLUng. -Added NFS kernel support (both client and server, and both V2 and V3 -protocols). +4) Identify which drive you wish you "unsling", and plug it in. Wait a minute + or two while the disk is mounted. -3.12: + - If the disk has not been previously formatted on the NSLU2, then now is + the time to do that. Make sure that the drive is recognized in the + web interface. -Added basic maintenance mode support. If /.ramdisk exists in the -jffs2 filesystem, then the jffs2 filesystem is copied into a ramdisk -on boot, and run from there. This allows for updating firmware using -the web interface. +5) In the telnet session, run "/sbin/unsling". -3.13: + - Starting with UNSLUNG 3.x, the external disk is no longer used for the + root filesystem, so only a few documentation files will be copied to + the "conf" partition (not the "data" partition). -Added recovery mode support. If a viable root filesystem cannot be -found, then switchbox drops into a basic recovery shell, with a telnet -daemon running as 192.168.1.77 with no password. This behaviour can -also be forced with a /.recovery file in the jffs2 filesystem. + - Once you "unsling" to an external disk on a particular port (Disk 1 or + Disk 2), it is important that you keep that disk continually plugged + into that same port whenever the NSLU2 is turned on. -3.14: + ***** Unsling will not change the password on your disk, so if you had + previously changed the password on a disk, then your password will + not be changed. Also note that simply editing the /etc/passwd file + is not enough to permanently change a password. See -Added web control of maintenance mode. You have to enable maintenance -mode and reboot before the firmware upgrade page allows you to enter a -filename for the new firmware. + http://www.nslu2-linux.org/wiki/HowTo/ChangePasswordsFromTheCommandLine -3.15: +6) Reboot. -Added confirmation dialog boxes to the maintenance mode web control. +***** Congratulations, you're now Unslung! ***** -3.16: +Make sure you add an entry to the "The UNSLUNG 3.x" table in the Yahoo group. +Just use the next free integer for your Unslung number. -First public release of 3.x firmware. +If you make no further changes, your NSLU2 will continue to operate normally. +But to customize things, you'll be downloading packages and adding stuff to the +/unslung directory on the external disk (or even in the internal flash memory) +using diversion scripts. -3.17: +Read the NOTES file to expand the capabilities of your uNSLUng NSLU2! -Fixed syslog issue. Added FP patches. +Enjoy! diff --git a/packages/nslu2-binary-only/unslung-rootfs-2.3r25/unsling b/packages/nslu2-binary-only/unslung-rootfs-2.3r25/unsling index e69de29bb2..c38774cd7d 100644 --- a/packages/nslu2-binary-only/unslung-rootfs-2.3r25/unsling +++ b/packages/nslu2-binary-only/unslung-rootfs-2.3r25/unsling @@ -0,0 +1,86 @@ +#!/bin/sh + +# Set or seach for target disk + +if [ $# -gt 1 ] ; then + echo "Usage: $0 [flash|hdd|flash-data|hdd-data]" + exit 1 +fi + +if [ $# -eq 1 ] ; then + if [ "$1" = "flash-data" ] ; then + targ=/share/flash/data + elif [ "$1" = "hdd-data" ] ; then + targ=/share/hdd/data + elif [ "$1" = "flash" ] ; then + targ=/share/flash/conf + elif [ "$1" = "hdd" ] ; then + targ=/share/hdd/conf + else + echo "Usage: $0 [flash|hdd|flash-data|hdd-data]" + exit 1 + fi +elif [ -d /share/hdd/conf/lost+found ] ; then + targ=/share/hdd/conf +elif [ -d /share/flash/conf/lost+found ] ; then + targ=/share/flash/conf +else + echo "Cannot locate target disk" + exit 1 +fi + +# Check it's a real mount point + +if grep $targ /proc/mounts >/dev/null 2>&1 ; then + echo "Target disk is $targ" +else + echo "Error: $targ is not a mounted disk" + exit 1 +fi + +# Start at the root directory + +cd / + +# Ensure /opt is there. + +if [ ! -d $targ/opt ] ; then + echo "Creating new /opt directory on target disk." + mkdir -p $targ/opt +else + echo "Preserving existing /opt directory on target disk." +fi + +if [ -d /opt -a ! -h /opt ] ; then + echo "Copying existing /opt directory from root disk to target disk." + tar cf - opt | ( cd $targ ; tar xf - ) + mv /opt /opt.old +fi + +echo "Linking /opt directory from target disk to root disk." +rm -f /opt ; ln -s $targ/opt /opt + +# Ensure /usr/lib/ipkg is there. + +if [ ! -d $targ/usr/lib/ipkg ] ; then + echo "Creating new /usr/lib/ipkg directory on target disk." + mkdir -p $targ/usr/lib/ipkg +fi + +if [ ! -f $targ/usr/lib/ipkg/status -a -d /usr/lib/ipkg -a ! -h /usr/lib/ipkg ] ; then + echo "Copying existing /usr/lib/ipkg directory from root disk to target disk." + tar cf - usr/lib/ipkg | ( cd $targ ; tar xf - ) +else + echo "Preserving existing ipkg database on target disk." +fi + +if [ -d /usr/lib/ipkg -a ! -h /usr/lib/ipkg ] ; then + echo "Saving /usr/lib/ipkg directory on root disk in /usr/lib/ipkg.old" + rm -rf /usr/lib/ipkg.old + mv /usr/lib/ipkg /usr/lib/ipkg.old +fi + +echo "Linking /usr/lib/ipkg directory from target disk to root disk." +rm -f /usr/lib/ipkg ; ln -s $targ/usr/lib/ipkg /usr/lib/ipkg + +exit 0 diff --git a/packages/nslu2-binary-only/unslung-standard-rootfs_2.3r25.bb b/packages/nslu2-binary-only/unslung-standard-rootfs_2.3r25.bb index 9c0bed3af1..cec0b3740c 100644 --- a/packages/nslu2-binary-only/unslung-standard-rootfs_2.3r25.bb +++ b/packages/nslu2-binary-only/unslung-standard-rootfs_2.3r25.bb @@ -1,6 +1,6 @@ SECTION = "base" -PR = "r40" +PR = "r41" UNSLUNG_VERSION = "3.18-beta" UNSLUNG_VARIANT ?= "standard" @@ -11,6 +11,7 @@ FILESPATH = "${@base_set_filespath([ '${FILE_DIRNAME}/unslung-rootfs-${PV}/${UNS SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r25.tar.bz2 \ file://README \ + file://NOTES \ file://linuxrc \ file://unsling \ file://resling \ @@ -37,8 +38,8 @@ SRC_URI = "http://nslu.sf.net/downloads/nslu2-linksys-ramdisk-2.3r25.tar.bz2 \ file://remount-noatime.patch;patch=1 \ file://initialise-mtab.patch;patch=1 \ file://mount_usbdevfs.patch;patch=1 \ - file://maintmode.cgi file://upgrade-maint.htm file://upgrade-nomaint.htm \ file://tmp-permissions.patch;patch=1 \ + file://maintmode.cgi file://upgrade-maint.htm file://upgrade-nomaint.htm \ " S = "${WORKDIR}/nslu2-linksys-ramdisk-2.3r25" @@ -70,6 +71,7 @@ do_compile () { install -d ${S}/opt/doc install -m 755 ${WORKDIR}/README ${S}/opt/doc/README + install -m 755 ${WORKDIR}/NOTES ${S}/opt/doc/NOTES ln -s /opt/doc ${S}/home/httpd/html/Unslung # Remove the libraries, because they are in nslu2-linksys-libs now @@ -90,7 +92,7 @@ do_compile () { } do_install () { - ( cd ${S} ; tar -c -v -f - --exclude '*\~*' --exclude '.patches' . ) | ( cd ${D} ; tar xvf - ) + ( cd ${S} ; tar -c -v -f - --exclude '.pc' --exclude 'patches' . ) | ( cd ${D} ; tar xvf - ) } PACKAGES = "${PN}" diff --git a/packages/openslug-init/openslug-init-0.10/kern_header.c b/packages/openslug-init/openslug-init-0.10/kern_header.c new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/packages/openslug-init/openslug-init-0.10/kern_header.c diff --git a/packages/openslug-init/openslug-init-0.10/sysconfsetup b/packages/openslug-init/openslug-init-0.10/sysconfsetup index e69de29bb2..1b5b901708 100644 --- a/packages/openslug-init/openslug-init-0.10/sysconfsetup +++ b/packages/openslug-init/openslug-init-0.10/sysconfsetup @@ -0,0 +1,34 @@ +#!/bin/sh +if [ ! -e /etc/linksysconf ] +then + +# Ok this may be a little hack for now +# but Make sure the kernel module info is updated +# So the driver can actually load the first time + /usr/sbin/update-modules + + dd if=/dev/mtdblock1 of=/etc/linksysconf + cat <<EOF > /etc/interfaces +# /etc/network/interfaces -- configuration file for ifup(8), ifdown(8) + +# The loopback interface +auto lo +iface lo inet loopback + +iface eth0 inet static +EOF + + strings /etc/linksysconf | grep ip_addr >> /etc/interfaces + strings /etc/linksysconf | grep ^netmask >> /etc/interfaces + strings /etc/linksysconf | grep hw_addr >> /etc/interfaces + sed -i -e 's/ip_addr=/ address /' /etc/interfaces + sed -i -e 's/netmask=/ netmask /' /etc/interfaces + sed -i -e 's/hw_addr=/ hwaddress ether /' /etc/interfaces + + mv /etc/network/interfaces /etc/network/interfaces.old + cp /etc/interfaces /etc/network/interfaces +# mv /etc/interfaces /etc/network/interfaces + echo "Configured /etc/network/interfaces with IP Static linksysconf Information" +fi + +modprobe ixp425_eth diff --git a/packages/openslug-init/openslug-init_0.10.bb b/packages/openslug-init/openslug-init_0.10.bb index e69de29bb2..57871a934c 100644 --- a/packages/openslug-init/openslug-init_0.10.bb +++ b/packages/openslug-init/openslug-init_0.10.bb @@ -0,0 +1,29 @@ +DESCRIPTION = "Openslug initial network config via sysconf" +SECTION = "console/network" +LICENSE = "GPL" +DEPENDS = "base-files" +PR = "r2" + +SRC_URI = "file://sysconfsetup \ + file://kern_header.c" + +inherit autotools update-rc.d + +INITSCRIPT_NAME = "sysconfsetup" +INITSCRIPT_PARAMS = "defaults 39" + +do_compile() { + ${CC} -o ${S}/../kern_header ${S}/../kern_header.c +} + +do_install() { + install -d ${D}/${sysconfdir} \ + ${D}/${sysconfdir}/init.d \ + ${D}/${sysconfdir}/rcS.d \ + ${D}/${sbindir} + + + install -m 0755 ${D}/../kern_header ${D}/${sbindir}/kern_header + install -m 0755 ${D}/../sysconfsetup ${D}/${sysconfdir}/init.d/ + ln -s /etc/init.d/sysconfsetup ${D}/${sysconfdir}/rcS.d/S39sysconfsetup +} |