Attention: This is work in progress.
Today I managed to bring up a NetVista N2200 under LTSP 5 for the first time. - Yeah, that rocks! Things are not perfect yet, but this all looks already quite useful. So I decided to put my bits and pieces up on the net to make many people happy ... --
HeGi - 19 Apr 2008
IBM NetVista N2200 aka Model 8363
Prologue
Since I did not really get any further with my old beloved
NetworkStation1000 (the CPU is just a bit slow an 64 MB is not really much), I shot myself a 4-pack of N2200s (8363-EXX) for around 65 ¤ in March (2008) to play a bit with this machine and to set it up as a client for my kids.
Mainly based on the work of Robert Wachinger on
NetVista N2200 and Linux-Kernel 2.6, I moved on step by step. If anyone plans to build N2200 kernels, Robert's scripts
do_netvista and
patch_nvista.c are highly recommended.
Results first
Current Status
What works:
- LTSP 5 connection over NFS
- LDM wiht fbdev graphics for X (1024x768x16)
- Remote Sound via pulseaudio on the integrated CS5530
- Kernel support for CF-Cards and USB-Sticks
- Switching between X-org and console
- root-fs hack to set the date
What needs to be done:
- using the nsc display driver (so far, it just doesn't work, despite to succes under ltsp-4.2)
Follow instructions for GX2 here, new developments are all on the LX chipsets so don't expect too much progress:
http://muzso.hu/node/3929?page=1
--
StevenMcCoy - 09 May 2008
Other things I dream of:
- support for German keyboard on console (c.f. scripts/init_top/keymap)
- getting Skype to use pulseaudio connection
Quickstart
To try it all out, go to
my download area and get youself the latest
kernel.2200 and the matching
module-pack.
Provided you got ltsp5 up and running for other i386 clients, there aren't that many specialities. Go to Robert's site to find help on how to update the firmware, if you havn't the latest available Version, BL072902 (from July 29th, 2002).
Configure DHCP
You'll need an entry with information like this in your dhcpd.conf:
# For NetVista N2200 :
option nv-211 code 211=string;
host tambala {
hardware ethernet 00:06:29:23:a6:2a;
fixed-address 192.168.1.3;
option nv-211 "tftp";
filename "ltsp/i386/kernel.2200";
option root-path "/opt/ltsp/i386";
}
Install the kernel
Put the
kernel.2200 into the relevant tftp-path. On debian Etch, that's in
/var/lib/tftpboot/ltsp/i386. Next take the
module-pack and untar it into your root-fs:
# cd /opt/ltsp/i386/lib/modules
# tar xvjf /path/to/download/modules-2.6.24.4-n2200-ltsp-1.tbz
Configure lts.conf
Here's what I've got in my lts.conf:
[tower]
XSERVER = fbdev
MODULE_01 = snd-cs5530
SOUND = True
SOUND_DAEMON = pulse
X_MOUSE_PROTOCOL = imps/2
X_BUTTONS = 5
X_MOUSE_DEVICE = "/dev/input/mice"
X_MOUSE_RESOLUTION = 400
X_MOUSE_BUTTONS = 3
XkbLayout = "de"
XkbModel = "pc105"
XkbVariant = "nodeadkeys"
Hack root-fs to set time
The N2200 has no battery buffered clock. So you need to set the time upon every boot. To avoid error messages, that the files of the root-fs were created too long in the future I came up with this script (you might want to change the IP of your NTP-Server or use the name of a public NTP-Server instead:
#! /bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
ntpdate -b 192.168.1.250
hwclock --systohc --utc --noadjfile
exit 0
Then, I linked it into the Start-up sequence:
# cd /opt/ltsp/i386/etc/rcS.d
# ln -s ../init.d/setdate S02setdate
This is not really elegant ... but it works for me. First I tried to incorporate ntpdate into the initrd ... but the date was reset when the init process started. I don't know why. My plan was to integrate an ntpdate request to the rootserver into the initrd/kernel pack to have a kernel, that needs no changes of the root-fs ... If someone finds a way to do so, please let me know.
Fire it up!
And enjoy your N2200 running on LTSP 5!
PLEASE do report
success (e.g. on the mailing list
ltsp-discuss@sourceforge.net) and not only failure. Writing docs is
work, too - and getting only bad feedback kills motivation.
Building the Kernel
Based on Robert's
web-site and scripts, I started my own project to make my N2200 ready for LTSP 5, since he didn't move to LTSP 5 after getting it working with LTSP 4.2 - for his results look
here.
So I took what I found there and also played with the various N2000 kernel-configs on the net. I took an initrd from LTSP 5 build on debian lenny, and thought, the rest would be an easy task. - But reality proved me wrong in this judgement.
Preliminaries
Get yourself a kernel-source. If you want to try out squashfs images you need to apply patches for unionfs and squashfs. Maybe you want to use your own latest initrd as a base. Then take that image from /opt/ltsp/i386/boot. The rest can be found in
my download area.
Step by step
- Read the kernel-build docs on Robert's page.
- Take your initrd, unpack it, strip the /lib/modules/2.whatever.version-you-might-have
- Take my config as a .confign and start with do_netvista -oldconfig
- Build the modules first (do_netvista -modules). Install only the "modules.*" files into the initrd image to keep it lean. Hence you need to build all functionality you need on bootup into the kernel itself.
- Then build the new cpio-image of the initrd (do_netvista -cpio)
- Finally build the kernel (do_netvista -m)
- Install the Image
- ... be happy!
The long way home
The Problems I had on the way ... and how I solved them:
- Couldn't get initial console (despite the init script providing for the creation of initial devs) --> I created basic devices in the /dev
path of the initrd (console fd fd0 null ram0 stderr stdin stout tty0 tty1 tty2 tty3).
- Had the error message "Bad page stat in process 'swapper'" upon boot --> reduced the size of the kernel and of the initrd. The idea:
The initrd contains no modules, every feature not needed in the initrd is compiled as module. - So I put only the modules.* into the initrd
and the modules go straight into the nfs-root.
Interesting: While at first I had to bring down the kernel/initrd package to about 3.0 MB, I'm now again at 3.5 MB and the error doesn't
come back. If the image gets bigger than 3.5 MB the kernel won't boot.
- Now I had mount-problems for the root. After a long while I found out, that /proc/cmdline is empty, no matter what I pass as commandline
from dhcpd. Result: The client (automatically) wants to mount an NBD-Image which needs unionfs and squashfs. Wasted a lot of time here,
and finally solved the issue by patching the initrd's /init with an ugly hack for
NFS (around line 170) by saying:
maybe_break mount
log_begin_msg "Mounting root file system..."
#### we have no "cmdline" - so we set this manually for nfs!
ROOT=/dev/nfs
BOOT=nfs
####
. /scripts/${BOOT}
parse_numeric ${ROOT}
(I added only the stuff between the "####")
- Since the N2200 has no battery buffered clock, it makes a lot of sense, to set the clock upon boot. Currently I'm experimenting with ntpdate here. But so far I havn't managed to get it working out of the initrd. Instead I patched the root-fs (c.f. above).
[More to follow later ... maybe]
--
HeGi - 19 Apr 2008