dashism in checkroot/checkfs/usplash functions
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
sysvinit (Ubuntu) |
Invalid
|
Undecided
|
Unassigned | ||
Bug Description
Binary package hint: sysvinit
When trying to run Hardy with mksh as /bin/sh booting fails. I now managed to track it down
to a bug in initscripts still present in maverick:
https:/
Let me illustrate the actual problem:
tglase@tglase:~ $ mksh -c 'sleep 2 & sleep 1; wait %1; echo $?'
0
tglase@tglase:~ $ mksh -c 'sleep 1 & sleep 2; wait %1; echo $?'
127
tglase@tglase:~ $ dash -c 'sleep 1 & sleep 2; wait %1; echo $?'
0
tglase@tglase:~ $ bash -c 'sleep 1 & sleep 2; wait %1; echo $?'
bash: line 0: wait: %1: no such job
127
Basically, the “wait” builtin returns 127 if the job has already finished by the time
wait is called, except in dash, where it returns 0. This makes *buntu unusable
with a shell other than dash as /bin/sh (among other things). I also wonder
whether this is the cause (with not using mksh as /bin/sh though) for our
workstations (at work) to boot to multiuser with / in read-only mode even
when it wants the 30-mount check (we need to manually fsck and reboot
then, which is idiotic in a production / company environment).
I’m currently working on a fix, will attach that soonish.
OK, got it. Both of them, I think. There was actually junk at the end of the e2fsck output file:
+ PASS=1
+ CUR=327
+ MAX=2316 /dev/sda1
This gave an expr arithmetic error.