Current-Users archive

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

Re: Sysinst default root login shell

Alan Barrett wrote:
> On Mon, 09 Apr 2012, Andreas Gustafsson wrote:
> >> If anita relies on having a specific shell for root user, why not just
> >> invoke /bin/sh explicitly, rather than relying on sysinst behavior?
> >The current sysinst behavior is a bug, and I would like the bug to be
> >fixed rather than changing the test to ignore it.
> I agree that there's a problem in sysinst, but I don't agree about 
> what the problem is.
> The underlying system default is that root's shell is /bin/csh, as 
> encoded in src/etc/master.passwd.
> Until recently, sysinst encouraged you to change the shell to 
> /bin/sh (if you just accepted the default answers in relevant 
> menus).  I think that it was a bad idea, or a bug, to have sysinst 
> encourage something other than the underlying default.

I agree that it was a bug for them to be different, I just disagree
about what they should both be changed to :)

> Currently, sysinst doesn't present the "Root shell" menu by 
> default, so if you don't deliberately go into the Root shell menu, 
> then you get /bin/csh, the underlying system default.  However, if 
> you do go into that menu, then sysinst encourages you to change to 
> /bin/sh (if you accept the default answer in the menu).
> I think that the default answer in the "Root shell" menu should be 
> taken from whatever is in /etc/master.passwd at the time the menu 
> appears, instead of always being /bin/sh.  For example, instead of
>       Root shell 
>      >a: /bin/sh 
>       b: /bin/ksh
>       c: /bin/csh
> (with the cursor on "a: /bin/sh"), use getpwname or equivalent to 
> look in master.passwd and adjust the cursor position accordingly, 
> displaying this if root's shell is csh:
>       Root shell 
>       a: /bin/sh 
>       b: /bin/ksh
>      >c: /bin/csh
> (with the cursor on "c: /bin/csh").

I think that would be fine.  It will make things consistent, and
we can then have a separate discussion about what the contents
of src/etc/master.passwd should be.

> Then I think "anita install" should deliberately go into that menu 
> and choose /bin/sh, or "anita test" should be adapted to work under 
> any shell (possibly by launching /bin/sh immediately after login).

It will have to be the latter.  Anita uses the default settings
whenever possible, because that is the most important case to test.
If the default root login shell is actually being changed on purpose
rather than by mistake, then anita will install with the new default,
and the "anita test" command will be updated to cope.
Andreas Gustafsson,

Home | Main Index | Thread Index | Old Index