Bug 1101 - terminal allocation hangs ssh at a blocking tcsetattr (-t option)
Summary: terminal allocation hangs ssh at a blocking tcsetattr (-t option)
Status: CLOSED INVALID
Alias: None
Product: Portable OpenSSH
Classification: Unclassified
Component: ssh (show other bugs)
Version: 4.2p1
Hardware: ix86 Linux
: P2 normal
Assignee: Assigned to nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-10-11 09:04 AEST by Imre Deak
Modified: 2020-02-14 15:59 AEDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Imre Deak 2005-10-11 09:04:58 AEST
I'm trying to use ppp over ssh as follows:

# pppd passive pty "ssh -qtt remote.mine.nu pppd 192.168.10.1:192.168.10.2"

The ssh process which is run as a child will try as a consequence of option -t will hang for ever in function enter_raw_mode / tcsetattr(fileno(stdin), TCSADRAIN, &tio) .

I could avoid the problem with replacing TCSADRAIN with TCSANOW, not sure though what a proper fix would be for this.
Comment 1 Damien Miller 2005-10-12 22:39:39 AEST
I'm not sure I understand: does it hang because pppd is filling the pty buffer so it never drains?
Comment 2 Imre Deak 2005-10-14 15:52:28 AEST
Well I'm not sure, why it hangs at this point, but even if it is as you
say filled by the local pppd there won't be anyone reading it on the other
side, since the remote pppd is not yet started. So it's a dead-lock situation
in that case.

Let me know if you need any other info, or want me to perform some test.
Comment 3 Damien Miller 2020-01-26 00:19:20 AEDT
I don't have any more insight into how to debug this than I did 15 years ago. If you still happen to be suffering from it then please reopen the bug and attach a debug trace from ssh (i.e. "ssh -vvv")
Comment 4 Damien Miller 2020-02-14 15:59:22 AEDT
Closing all resolved bug with release of openssh-8.2