Subject: Re: Can't open passive connection: No such file or directory.

From: "May we be forgiving of our systems' faults..." <[email-masked]>
Date: Mon, 24 Jul 1995 12:41:23 -0400 (EDT)

Thanks for the info, Winfried.  Unfortunately, I do have a /dev/tcp
	file in the chroot'ed directory.  :(  BTW, I am using the WU-FTPd
	distribution (not Sloan's beta release which does include PASV sup-
	port).  Short of running the server in a debugger, is there a way
	to figure out WHICH files is not found?  Thanks!

								Sean.

*** IN RESPONSE TO ***

From:	IN%"[email-masked]" 21-JUL-1995 16:17:07.64 21-JUL-1995 16:17:00.00
To:	IN%"[email-masked]"
CC:	
Subj:	Re: Can't open passive connection: No such file or directory.

> Jul 21 14:40:23 ias4 ftpd[21322]: command: PASV
> Jul 21 14:40:23 ias4 ftpd[21322]: PASV
> Jul 21 14:40:23 ias4 ftpd[21322]: <--- 425
> Jul 21 14:40:23 ias4 ftpd[21322]: Can't open passive connection: No such file or directory.
> Jul 21 14:40:23 ias4 ftpd[21322]: command: PORT 198,112,141,40,5,245
> Jul 21 14:40:23 ias4 ftpd[21322]: PORT
> Jul 21 14:40:23 ias4 ftpd[21322]: <--- 200
> Jul 21 14:40:23 ias4 ftpd[21322]: PORT command successful.
> Jul 21 14:40:23 ias4 ftpd[21322]: command: LIST
> Jul 21 14:40:23 ias4 ftpd[21322]: LIST
> 
> 	I applied a patch that Bryan gave me to enable PASV, yet I am
> 	getting that error.  I suspect I may be missing some library
> 	file or something.  Anyone seen this one before?  Thanks!

I had a similar problem just befor two days. I installed wu-ftpd-2.4.2-beta-5
on a system with SINIX-5.42 (SVR4). After this our www-server (cern-httpd3.0)
fails to open the ftp-connection for proxy-clients.
The simply solution (I checked it after 1day) was that I have no
write-permission on ~/dev/tcp (may be I should read the manulapage
to the system-ftpd better). First I think it was an error in the
libsocket since the message was generated due to a failed open of
socket(). My message looks like this:
Can't open passive connection: permission denied
On your message I would say you don't have a ~/dev/tcp in your chroot.
I think the passive mode is the only method to open a socket after
the chroot and so it don't hurt users who don't connect the server
through the proxy-server (I don't know if other www-servers also
use passive mode, or should I say, befor this problem I never
heard from a passive mode :-)
You can simply check this with telnet:

telnet host.domain 21
USER ftp
PASS [email-masked]
PASV

regards

	winfried

-- 
Winfried Magerl - Internet Administration
Siemens Nixdorf AG, GP QM/S IF, 81739 Munich, Germany
Internet-Mail: [email-masked]

---

From: [email-masked] (Winfried Magerl)
Date: Tue, 25 Jul 1995 10:28:27 +0200 (MDT)

> 	to figure out WHICH files is not found?  Thanks!

There are only one section in wu-ftpd-2.4 and/or wu-ftpd-2.4.2-beta5
which generate this error message, both in ftpd.c in the function passive().
You can change one of the messages in the source, so you see if the error
occurs on socket() or on bind().
A eayse way to check for missing files ist to trace the syestemcalls.
I don't know which system you are running, but here are examples
for some systems:

pid is the process-id of the ftpd. You can start the trace just befor
you try PASV.

for SGI with IRIX5:
par -s -SS -p <pid>

for SVR4:
truss -p <pid>

for SunOS4:
trace -p <pid>

Sorry, I don't know the command for all sytems :-)

regards

	winfried