Ubuntu 7.04 (Feisty Fawn) shell problems

Here’s a little gotcha for anyone using Ubuntu 7.04 (it might have been in 6.10 too, I’m not sure) and some amount of shell scripting.

If you refer to /bin/sh anywhere, Ubuntu out of the box points to a shell called dash and not (as would normally be the case) bash. Dash doesn’t have all the features bash has though (the flip side is that it’s a lot faster, apparently), so in some cases (including a few I just ran into) your scripts may cease to work.

The solution? Change your scripts to explicitly use /bin/bash or use the sledgehammer approach and relink /bin/sh to /bin/bash.

And yes, despite going point-haired, I haven’t escaped from the land of build monkey.

Advertisements