Multiple (multiplexed) simultaneous ssh connections - Cygwin bug?

Goldburt, Dan Dan.Goldburt at
Sat Sep 9 02:16:42 EST 2006

>debug1: server_input_channel_req: channel 7 request exec reply 0
>debug1: session_by_channel: session 7 channel 7
>debug1: session_input_channel_req: session 7 req exec
>debug2: fd 29 setting O_NONBLOCK
>debug2: fd 27 setting O_NONBLOCK
>fcntl(31, F_GETFL, 0): Bad file descriptor
>select: Bad file descriptor


Ok so I think I tracked this down a bit more. What gave it away was that
it had trouble opening fd number 31.
I mentioned that I increased MAX_SESSIONS in session.c (line 107).
Before I did this, sshd was only getting up to fd 30 (10 sessions * 3 fd
per session - stdin, stdout, stderr).
So I'm wondering if there is another dependant variable that I need to
change? Perhaps somewhere where memory is allocated for the fd?


More information about the openssh-unix-dev mailing list