Re: 2.6.25.3: su gets stuck for root

Joe Peterson
2008-06-02T05:55:21Z

Willy Tarreau wrote:
> Guys, you should test if "kill -CONT $pid" wakes the process up.
> It might be possible that some obscure bug appeared in the tty
> code resulting in SIGTTOU sometimes being sent to the caller,
> although that seems rather strange :-/

Just tried this ("kill -CONT <pid>") - no luck.

BTW, it should be possible, I would think, for others to duplicate this
fairly easily. Just:

1) make a user, "foo", with login shell set to /bin/bash
2) create a .bashrc in foo's home dir with contents:

sleep 2
stty -ixany

3) cp .bashrc .bash_profile (only needed to test "su - foo" too)
4) become root
5) type "su foo" (or "su - foo")

Sometimes it takes a second try to get it to happen. If the su hangs,
check to see if the stty process is in state "T". Also, it may make a
difference if you are logged in already as foo or are using X. I first
noticed this with no users logged in (except root) and no X running (but
I can reproduce with X/xterm as well using this simple test case). It
seems timing is a factor, so it's worth trying various things.

-Joe