Subject: Re: init: can't exec /bin/bash for /etc/rc: Exec format error
To: felix zaslavskiy <felix@students.poly.edu>
From: Bill Studenmund <wrstuden@netbsd.org>
List: current-users
Date: 06/25/2003 10:22:56
On 24 Jun 2003, felix zaslavskiy wrote:

> On Tue, 2003-06-24 at 22:17, Brian Rose wrote:
> > I looked throughout /etc /etc/rc.d /usr/pkg/etc and /usr/etc/rc.d for bash references, but the only ones I found are in the passwd and master.passwd files for some users.
> >
> > I did move bash to /bin so that I could have access to it in single user mode. But I did not modify root to use bash by default. I remember hearing of dire consequenses to those modifying the default root options.
>
> I like to know what these dire consequences are because the first thing
> i do when i install netbsd is install bash and change default shell for
> root to /usr/pkg/bin/bash
>
> I never had a problem on three machines i been using.

That's because the main reason for the concern has been fixed. If scripts
don't start with "#!/bin/sh", they may get executed with something other
than /bin/sh. That can lead to mayhem.

We make our scripts start with /bin/sh so there's no problem.

Take care,

Bill