Running SAS on Ubuntu Linux: Dash to Bash

It happened to me again today … the Ubuntu dash-bash-default-shell-thing:

userid@hostname:~$ /opt/sas92/SASFoundation/9.2/sas
/bin/sh: 0: Illegal option -p
userid@hostname:~$ /opt/sas93/SASFoundation/9.3/sas
/bin/sh: 0: Illegal option -p

I encounter this every now and then. This time I was upgrading my notebook and it’s Ubuntu 64-bit installation to 12.10 and restoring SAS 9.2 & 9.3 installations from backup.

Several years ago the default shell symlink of /bin/sh to /bin/bash was changed to /bin/dash in Ubuntu. You can find out more about the reasoning behind Ubuntu’s switch from bash to dash here – it caused quite a bit of discussion when it happened.

The often suggested fix is to manually change the /bin/sh symlink, but there’s also a command to do it (which also fixes the associated man page symlink too):

Continue reading “Running SAS on Ubuntu Linux: Dash to Bash”