[CentOS] Login timed out after 60 seconds

Fri Feb 12 15:55:43 UTC 2010
Paul Heinlein <heinlein at madboa.com>

On Thu, 11 Feb 2010, nate wrote:

> Paul Heinlein wrote:
>
>> I'm trying to figure out if it's possible to lengthen that timeout 
>> value from 60 to, say, 180. This isn't the first time I've wanted 
>> to kill a runaway process and been unable to get a console because 
>> of that timeout.
>
> I poked around a bunch but couldn't find a config that can be 
> adjusted.. I do see that the particular message comes from 
> /bin/login
>
> # strings login | grep -i timed
> Login timed out after %d seconds
>
> which seems to be part of the util-linux package, so perhaps poke 
> around in the source, maybe there is a .h file that you can adjust 
> with a higher value and rebuild it.

And we have a winner!

It's a simple declared variable in login-utils/login.c:

   int     timeout = 60;

The timeout variable is passed to alarm(). Once SIGALRM is raised, 
login prints the "Login timed out..." message, resets the terminal, 
and exits.

So the question is, do I want to patch the util-linux SRPM? Hmm...

-- 
Paul Heinlein <> heinlein at madboa.com <> http://www.madboa.com/