Zaurus - networked

How I got the Zaurus networked for the first time

I mostly followed this page to get going. My Z is an SL-5500 with ROM ver 2.38, so it seems that the notes about the closed ports apply to me.

Z sits in the usb cradle, and its network setup has 'USB - TCP/IP' with automatic address (dhcp). Here are the commands that I run (2.4.22 kernel) to get networked:

modprobe usbnet
ifconfig usb0 192.168.129.1 netmask 255.255.255.255 up
dhcpd -q usb0
route add -host 192.168.129.201 usb0
iptables -t nat -F
iptables -t nat -A POSTROUTING -j SNAT -o eth0 --to 10.1.0.229
echo 1 > /proc/sys/net/ipv4/ip_forward

Where 10.1.0.229 is my machine's address on my local net. My /etc/dhcpd.conf looks like this:

# empty subnet for eth0, where i don't want dhcp
subnet 10.1.0.0 netmask 255.255.0.0 {
}

subnet 192.168.129.0 netmask 255.255.255.0 {
  option routers 192.168.129.1;
  option domain-name-servers 10.1.0.1;
  range 192.168.129.201 192.168.129.204;
}

where 10.1.0.1 is my name server.

Once I was networked, I surfed to http://www.myzaurus.com/downloads.asp on the Z and had Opera download the terminal .ipk package into /home/root/Documents where it can be installed with the 'add software' program.

To ssh to the zaurus, get openssh. Move the new files from /usr/local/bin/ to /usr/bin so they get found in the basic path. (scp/rsync will depend on that). On the Z, run ssh-keygen -b 1024 -f /usr/local/etc/ssh_host_key -N '' (see here for more, but note the typo on /usr/local/etc). Then add ssh stream tcp nowait root /usr/sbin/tcpd /usr/local/bin/sshd -i to /etc/inetd.conf and run /etc/rc.d/init.d/inet restart.

I also added these lines to inetd.conf to block qpe's ftp and other sync services:

4242 stream tcp nowait root /bin/false false
4243 stream tcp nowait root /bin/false false
To make those take effect, kill the qpe process then quickly HUP the inetd process so it grabs the ports first. Use "netstat -pl" to see what process is listening on what port.

To ssh to root@zaurus from my non-root user, I added this section to my desktop's .ssh/config:

Host z
 User root

scp and rsync had trouble connecting to the Z because their Z-installed versions were in /usr/local/bin.