3
« on: November 06, 2007, 07:40:54 am »
Well, the other day I deletes the symbolic link to grep, egrep and fgrep. This wasn't a problem at the time as I have compiled the full version of grep and it was in /usr/local/bin. The problem was that I have /usr/local/ symlinked to a directory on my SD card and when I rebooted I discovered that the zaurushw startup script needed grep and it couldn't find it as it hadn't mounted the SD card yet.
"Not a problem" I thought, "just log in an move grep and it's libs into /bin/ and /lib/", but then I discovered that without the zaurushw script having run correctly or because grep was missing I couldn't log in.
"Great" I thought, "now I can try out the UBoot emergency console"
So I booted into it (holding down OK when restarting the Zaurus) and up popped the emergence console. The SD card was auto mounted but the NAND partition wasn't, but a little experimentation later and I had mounted the NAND partition (/dev/mtdblock2 with a filetype of jffs2). I copied the grep commands across to /bin/ on the NAND partition and then copied the relevant libraries for them to the /lib/ (I figured out the libraries required by simply running the command and when it complained about not being able to find a library I moved it)
After all that I rebooted, logged in and everything is back running fine again.