David Holland organised NetBSD’s Hackathon 11 at the last weekend. The goal was to fix bugs in preparation for the NetBSD 5.0 release.
I decided that this was the best opportunity to fix PR kern/38100 which had rendered my ULTRA60 useless the past few month. I started with trying to reproduce the problem without using the automounter daemon but couldn’t cause a similar kernel panic. Fortunately Michael van Elst provided the crucial clue: the panics were related to NFS’s directory cookie translation option. If I manually mounted a filesystem using the -X option of mount_nfs(8) the attempt to unmount it afterwards would trigger a kernel panic. With futher help from Michael van Elst I came up with a fix. Using a kernel with this change my ULTRA60 survived mounting and unmounting filesystems via the automounter in rapid succession for an hour without problems.
Because I had plenty of time left I also ported a change from FreeBSD to fix PR bin/38584. I tried to fix further cases of bad handling of set -e in /bin/sh but that turned out to be less successful. In the end I gave up on these changes because the spec is somewhat debatable.