This is Tinky v. 2.3.2-mu-02.2 for the NAS-2000 / 1000 Tinky is released under the term of the GPL v2 flipstar 20070507 *WARNING Using tinky-2_3_2-mu-02.2 will VOID YOUR WARRANTY.* You have been warned... 1.) This is tinky v. 2.3.2-mu-02.2 an alternate firmware for the NAS-2000 / 1000 NAS systems. Tinky was build from a 2_3_2_IB_02.2 firmware released by raidsonic. The 2.x firmware is based on a 2.6 kernel. As the flash layout has changed you cannot update the firmware the regular way via the webGUI. It will only work via the bootloader. Some people who had trouble with the firmware update from 1.0 to 1.3 received the box after sending it to raidsonic with this 2.x firmware. Tinky is now integrated into the firmware and will be executed during every boot. You can now use the Twonky-Software the regular way if you want to. This was not possible before because the old Tinky version used there Twonky-hook. I called the Firmware *-mu-* because I tryied to make it a little more useful -> mu = made usefull After all one could say the NAS-2000 is a pretty cool hardware but as you can see in /etc/ImageInfo DESCRIPTION="SL3316 demo board firmware." the firmware is/was demo. Guess we live in a world with short time to market times and the firmware is working somehow. A great chance for us, so lets make the NAS better. The NAS has lots of unused features like USB (1.0) and a hardware cryptoengine. Badwater did some tests and figured out that the USB is somehow working but (I suppose) not supported by the kernel. Further more there seems to be a 2nd Networkinterface you can see in the bootlog or simply by running 'ifconfig eth1 up; ifconfig' finally there seems to be an unsoldered JTAG (20 Pin) port. So there is a lot more to find out!!! 1.1) Why did you made Tinky? Well simply to see if I can :-) or to say it with Aleph One (Phrack 49) words "For Fun and Profit". 2.) What have you changed? When taking a closer look on the firmware I found lots of unneeded processes and files. - usb modules loaded - raid support in the webGUI - hotplug support - wireless support - unneeded libs - test for 2.4 Kernel in the boot up scripts - etc etc etc 2.1) What was deleted? Which featurs have been deleted / replaced? - the dhcp-Server was deleted -> its a NAS not a router!!! - unneeded usb and wireless modules - language support in the WebGUI for Chinese/Taiwanes lang - unneeded files in the sausalito dir - the printer support - some startup scripts have been cleaned up (by fare not all :-) TODO) 2.2) What has been added? - a new WebGui created by Christian (thanks again) - basic zeroconf/aka bonjour Service for http, ftp and ssh - ssh-server / -client including scp (telnet is dead) - new busybox with lots of new features - ipkg support to simplify the installation of new software - a hook if you create a file (shellscript) and put in /mnt/IDE1/public/tinky/tinky_hook it will be executed before sausalitos and most of the systems daemons. The Twonky-hack is not needed anymore. - Tinky entry in the WebGUI - the boot process is now ~30% faster (except for the first boot when the ssh-key are created) - some more I guess go and find out :-) 3.) How should Tinky be used? The way you use your NAS has not changed but only extended - you can login via ssh: User: root Passwd: nas2000 Make sure you change the password and run tinkysave!!! (run passwd) - the ipkg config file is /etc/ipkg.conf src tinky-2_3_2_mu_02 http://www.nas-2000.org/download/tinky-\ 2_3_2_mu_02/ipkg dest root / you should run: # ipkg-cl update now check the available pkgs: # ipkg-cl list and install some pkgs with: # ipkg-cl install rsync ipkg will take care about the dependencies :-) 3.1) Ok the new busybox version contains the su-Applett how to use it? If you want to be able to run the su-command with a spezific user you have to add this user to the group wheel in /etc/group # vi /etc/group wheel:x:10:root, and then add the /etc/group file to /system/overlay/savedata.conf # vi /system/overlay/savedata.conf /etc/group:group If your user is already logged in you have to logoff and on again now run su and enter your passwd. 4.) I want to create my own ipkg files, what to do? First of all I think it is a good idea to place every pkg in its own dir (execept libs) under /system/overlay/apps/. Then work with start script to create symlinks and start the stuff. All the libs should go to /system/overlay/lib/ They will be linked to /lib/ on every boot. 4.1) But HOW to create the pkg? Do the following on your Linux-Box. First you'll need to install the ipkg-utils on gentoo guess what ?!?! run 'emerge -av ipkg-utils' :-) Now do the following: # mkdir my_ipkgs # cd my_ipkgs # mkdir -p rsync-2.6.9/CONTROL # mkdir -p rsync-2.6.9/system/overlay/bin/ # cp /tmp/rsync rsync-2.6.9/system7overlay/bin/ # vi rsync-2.6.9/CONTROL/control Package: rsync Version: 2.6.9 Priority: optional Section: net Maintainer: flipstar_at_nas-2000_dot_org Architecture: armv4tl Source: rsync-2.6.9.tar.gz Depends: libpopt License: GPL Description: tool to sync files over the net Optional you can create preinst, postinst, prerm and postrm scripts in the CONTROL directory. For a lib you have to create a symlink for the first time do this in a postinst script. Now run: # ipkg-build rsync-2.6.9 and # ipkg-make-index ./ > Packages Package: rsync Version: 2.6.9 Depends: libpopt Section: net Architecture: armv4tl Maintainer: flipstar_at_nas-2000_dot_org MD5Sum: 928269b6d8af0a1562680a6882a332b1 Size: 134194 Filename: rsync_2.6.9_armv4tl.ipk Source: rsync-2.6.9.tar.gz Description: tool to sync files over the net Copy the archive and the output of ipkg-make-index to your webserver. For further studies see the links section. If you want your software to be accessible in the WebGUI you have to provide some files in /usr/webroot/ and make /usr/webroot/nav/tinky_service.xml your parent. See the tinky_save files for example or read the sausalitos handbook link in the links-section- 5.) How to install Tinky? First of all MAKE A BACKUP OF YOUR FILES You may be saying: Where should I put the 400GB??? We'll somewhere :-) Warning your MAC-Address will be changed to 0050c22b3322 but if you want you can reconfigure the MAC-Adr in the bootloader Before you begin you'll need a tftp server for the installation. For Windows you can try tftpd32.jounin.net (thanks again Jean-François) For Linux I can recommend atftp http://freshmeat.net/projects/atftp/ Extract the Archive and run # md5sum -c tinky-2_3_2-mu-02.2.md5 copy the tinky-2_3_2-mu-02 firmware file to you tftp-root for me its # cp tinky-2_3_2-mu-02.2 /tftp_root/ (Just to be sure your NAS has to powered OFF at this stage!!!) Configure your Networkcard to use a 192.168.2.x IP-adr. (e.q. 192.168.2.10) Now run: # arping -f 192.168.2.71; telnet 192.168.2.71 9000 boot your NAS and hit Ctrl+C when promted. If you have no arping (Windows) you should prepare the telnet command then power on your NAS and hit enter at the same time. Note: If you have problems to catch the NAS you probably have to put a switch or hub between your PC and the NAS. Once you reach the Redboot-Bootloader - press X - press 2 (TFTP download) - enter your PC IP-Adr. (for me its 192.168.2.10) - enter the path to the firmware image (for me /tftp_root/tinky-2_3_2-mu-02.1) Note: Redboot has problems with long paths + make sure that no space is in the path (like C:\im so cool\) - press enter - last chance Do not power-off this device while flash programming is proceeding!!------------ Are you sure to program Boot code (Y/N) y Its a bad idea to play now with the power supply etc etc :-) Flashing can take up to 15 min. If something goes wrong and you are lucky the bootloader has already been written to the flash you can retry. - Once its done press 1 to boot the NAS The first boot will be slow because dropbear will create the keys Note: If you want to use ssh with other users than root you have to make sure that they have a valid shell and home-dir /etc/passwd: my-user:$1$$CoERg7ynjYLsj2j4glJ34.:500:100:admin:/mnt/IDE1/my- user/:/bin/sh If you like you can copy the /etc/profile file to the users home and set the HOME-variable to: HOME=/mnt/IDE1/my-user 6.) Ok but I already have a 2.x firmware, do I have to make a full update Well no if and ONLY if you have a 2.x firmware you can update only the Ramdisk and Application parts. If you do so you have to first update the Ramdisk and after that the Application part but the bootloader wont be touched which makes the update process more secure (you will allways be able to access the bootloader even if something gose wrong while you flash) and your MAC-Adr wont be changed :-). 6.1) Ok I have a 2.x firmware (checked the WebGUI) so how to update? Again make really sure its 2.x!!! MAKE A BACKUP OF YOUR FILES You may be saying: Where should I put the 400GB??? We'll somewhere :-) Before you begin you'll need a tftp server for the installation. For Windows you can try tftpd32.jounin.net (thanks again Jean-François) For Linux I can recommend atftp http://freshmeat.net/projects/atftp/ Extract the Archive and run # md5sum -c Ramdisk.md5 # md5sum -c Application.md5 copy the RAMDISk and Application files to you tftp-root for me its # cp Ramdisk /tftp_root/ # cp Application /tftp_root/ (Just to be sure your NAS has to powered OFF at this stage!!!) Configure your Networkcard to use a 192.168.2.x IP-adr. (e.q. 192.168.2.10) Now run: # arping -f 192.168.2.71; telnet 192.168.2.71 9000 boot your NAS and hit Ctrl+C when promted. If you have no arping (Windows) you should prepare the telnet command then power on your NAS and hit enter at the same time. Note: If you have problems to catch the NAS you probably have to put a switch or hub between your PC and the NAS. Once you reach the Redboot-Bootloader we`ll begin with updating the Ramdisk - press 2 to list the flash parts - press 4 - Image Name: Ramdisk - Flash Address: 0x701a0000 - Memory Address: 0x00800000 - Entry Point: 0x00800000 - press 2 - 192.168.2.10 - Image Path /tftp_root/Ramdisk OK half way througth now we update the Application-Part - press 2 - press 4 - Image Name: Application - Flash Address: 0x703a0000 - Memory Address: 0x0 - Entry Point: 0x0 - press 2 - 192.168.2.10 - Image Path /tftp_root/Application ok done!!! Now press 1 and have fun! Note if you already had tinky installed on your NAS it is recomended that you make a backup of the /system/overlay directory and then delete that dir rm -rf /system/overlay This is needed because the new version will only copy the new files from flash to /system/overlay if the dir does not exists. This way it is possible that you can change, add or remove files and the data wont get overwriten on the next boot. 7.) The End! Again feedback is very welcome!!! Until now you can find some infos at http://www.flipstar.net/myfaq but all the NAS related stuff will be moved to http://www.nas-2000.org soon. Have fun P.S. If you have trouble formating you hd you should mount the NAS via USB and delete all partitions then retry. Links: DLink DNS-300 http://dns-300.sergeyzh.org/wiki/home (great work Sergey) The sausalitos handbook ftp://ftp.cobalt.com/pub/developer/TechNotes/SSDK.pdf IPKG HOWTO http://qtopia.net/modules/developers/qtopia.php?linkFile=developers/IPKG_Howto Document History 01 20070330 inital release 02 20070420 update version and date added zeroconf part added new update section added "Hot to use Tinky / Using su" added 3.1 howto use su 03 20070504 changed version vom tinky-2_3_2-mu-02 to tinky-2_3_2-mu-02.1 04 20070507 changed version vom tinky-2_3_2-mu-02 to tinky-2_3_2-mu-02.2 See Changelog for more infos.