[H-GEN] getty and login and things

Martin Pool martinp at mincom.com
Wed Apr 28 02:50:39 EDT 1999


(Note reply-to: being general at humbug.org.au vs Martin Pool <martinp at mincom.com>)

Allen Grace wrote:

> I could probably figure this out without having to come asking for help
> if I spent some more time with it, but it's starting to get up my nose.

 $ man 8 nasaltweezers

> While tinkering last Saturday afternoon, I managed to do something to
> the login process, so that logins are impossible in any runlevel except
> first.

Version control on configuration files is good.

> Three cases:
> 1. boot to single user, run login: everything is fine.
> 2. boot to runlevels 3 or 5 directly (i.e. standard boot): login accepts
> username, asks for password, and never returns *if I enter the correct
> password*.

Are the 'shell' fields in /etc/passwd reasonable?  Have you changed the
PAM settings?  What happens if you enter the wrong password?  What
happens if you change the shell to be (say) date: does it print the date
OK?

> 3. boot to single user, telinit 3: the following happens
> 
>         sporty login: allen
>                         sh: allen: command not found
>         bash#
> 
> Do I understand from this that getty has passed the username directly to
> /bin/sh without trying to run login?

Not exactly.  I think perhaps the sh that was running on the console in
single-user mode is still-running in level 3.  It happens to have read
the input rather than login.  A better way to switch levels is 

   bash# exec telinit 3
   [time passes]
   scary login:

HTH,

-- 
 /\\\  Mincom | Martin Pool          | martinp at mincom.com
// \\\        | Software Engineer    | Phone: +61 7 3303-3333
\\ ///        | Mincom Pty. Ltd.     | 
 \///         | Teneriffe, Brisbane  | Speaking for myself only

--
This is list (humbug) general handled by majordomo at lists.humbug.org.au .
Postings only from subscribed addresses of lists general or general-post.



More information about the General mailing list