[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: /bin/sh linked to dash?



On Sunday 31 Jul 2011, Goswin von Brederlow wrote:
> Francesco Pietra <chiendarret@gmail.com> writes:
> > I wonder whether amd64 wheezy links /bin/sh to dash instead of bash.
> >
> > I am getting error "Bad fd number, can't run mopac.h" in a mopac.sh
> > calculation (mopac compiled fortran, in fact a FOR005 file is
> > generated, and not deleted by mopac probably because it was running
> > bad).
> /bin/sh in debian is a posix shell with some tiny extras (echo -n for
> example and printf). It can be either dash or bash depening on your
> configuration. New installs default to dash, upgrades default to keeping
> bash as /bin/sh.

The other way of looking at it, of course, is that bash has been the default 
shell on GNU systems for so long, it's become entirely reasonable to expect 
the default shell to support the GNU extensions.  It's not as though they are 
going to go anywhere in future.

While I can fully understand why someone might want to use a less-complex  
(i.e. faster)  shell implementation to run the system startup scripts, 
redirecting /bin/sh to something besides bash is breaking the principle of 
least surprise.  Startup scripts that can use dash ought to have 
used "#!/bin/dash" for their first line, and then had the package depend on 
dash.

-- 
AJS
delta echo bravo six four at earthshod dot co dot uk


Reply to: