PDA

View Full Version : pure-ftpd-mysql Connection error, but pw accepted


bolek2000
8th October 2009, 13:54
Hi guys,

I'm going crazy :confused: , while trying to get ftp working. The story is:

I'm running ISPConfig 3 on an Ubuntu 8.04 vServer (the provider uses XEN) and I rebuilt the pure-ftpd packages --without-capabilities as mentioned in the forums.
Then I installed ISPC 3, created client, site and ftp user. The result was, that Filezilla FTP Client shows this in debug mode:

Antwort: 220---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
Antwort: 220-You are user number 1 of 50 allowed.
Antwort: 220-Local time is now 11:18. Server port: 21.
Antwort: 220-This is a private system - No anonymous login
Antwort: 220 You will be disconnected after 15 minutes of inactivity.
Trace: CFtpControlSocket::SendNextCommand()
Befehl: USER bolek2000_ftp
Trace: CFtpControlSocket::OnReceive()
Antwort: 331 User bolek2000_ftp OK. Password required
Trace: CFtpControlSocket::SendNextCommand()
Befehl: PASS ***********
Trace: CRealControlSocket::OnClose()
Trace: CFtpControlSocket::ResetOperation(66)
Trace: CControlSocket::ResetOperation(66)

As you can see, there's no Authentication failed, but the Connection is reset. I tried passive mode, with(out) SSL an so on.
I turned off iptables firewalls on server and client.
Then I uninstalled the pure-ftpd-mysql package and installed pure-ftpd, set up pureDB and got it working perfectly with/out TLS.
Then I switched back to mysql auth and still the same problem.
I turned on VerboseLogging in pure-ftpd and in my.cnf. The queries are running against the Db-Server. The syslog shows:
Oct 8 13:42:12 h1486047 pure-ftpd: (?@84.190.60.189) [INFO] New connection from 84.190.60.189
Oct 8 13:42:12 h1486047 pure-ftpd: (?@84.190.60.189) [DEBUG] Command [user] [bolek2000_ftp]
Oct 8 13:42:12 h1486047 pure-ftpd: (?@84.190.60.189) [DEBUG] Command [pass] [<*>]

I also tried to switch off different options in /etc/pure-ftpd/conf (DontResolve, ChrootEveryone
After reading really a lot of threads I have no idea anymore, do you have one ? Is it possible that it is an vServer issue ?

Cheers

bolek2000
9th October 2009, 00:45
Now I found the solution.
On my system /etc/init.d/pure-ftpd-mysql always started with the pure-ftpd-mysql-virtualchroot binary, what I never doubted to be wrong, because it was like this from the beginning and it made sense to me !?
Now I edited /etc/default/pure-ftpd-common and changed VIRTUALCHROOT=no

Now the daemon starts like this and everything seems to work now:

/usr/sbin/pure-ftpd-mysql -l mysql:/etc/pure-ftpd/db/mysql.conf -O clf:/var/log/pure-ftpd/transfer.log -Y 2 -E -H -A -4 -u 1000 -d -B

Seems the virtualchroot binary doens'nt work on my system, conflicts with something or it is a feature. Any Comments, otherwise good night :)

till
9th October 2009, 12:12
Thats strange, I've not seen this before. But good to know that this is a possible reason for login errors.