ftp authentication fails

Discussion in 'Installation/Configuration' started by fooboo, Mar 17, 2010.

  1. fooboo

    fooboo New Member

    I have been using ISPConfig for a while and I have had a number of working ftp accounts pointing at various sites.

    The accounts were still working yesterday but today for some reason they stopped authenticating. I get a "530 Login authentication failed" message using saved account details that were working fine yesterday and if I use ISPConfig to setup a brand new user those details get the same error message.

    The only thing I have done involving user accounts since yesterday is added an IP to mysql to allow a user to administer a couple of databases remotely.

    Can this affect the ftp accounts?
    Is there something I can try to get them working again? I definitely have the right connection details.
  2. fooboo

    fooboo New Member

    It looks as though the users are still being found but their passwords are being rejected...despite being correct:

    Command: USER <myuser>
    Response: 331 User <myuser> OK. Password required
    Command: PASS ******
    Response: 530 Login authentication failed
  3. falko

    falko Super Moderator ISPConfig Developer

    Did you modify your firewall?
    Did you try both active and passive transfers in your FTP client?
  4. fooboo

    fooboo New Member

    I didn't modify anything and the settings for my ftp client are exactly the same as when they were working. It's set to automatically try both types (I use filezilla).

    I had working ftp accounts, modified mysql to allow remote access, started filezilla again and clicked on the same set of details and now it denies the password. I didn't change the firewall at all.
  5. till

    till Super Moderator Staff Member ISPConfig Developer

  6. fooboo

    fooboo New Member

    It finds the server and accepts the username so I'm assuming the firewall is letting it through, it's just the password it rejects.
  7. fooboo

    fooboo New Member

    Hmm, my syslog isn't where that link thought it would be. I'll have to find it first :p
    I use CentOS not Debian.
  8. fooboo

    fooboo New Member

    Whilst digging through my system yesterday I found out something that may be of relevance.
    ISPConfig thinks my MySQL server is down. It reports it as such in the monitor section. I know it isn't because I have websites that use it and I've been using it in the command line.
    I also noticed my fetchmail has stopped fetching my mail.
    I wondering if ISPConfig thinking the MySQL server is down (for some unknown reason) is why ftp and fetchmail have stopped working? Could it possibly assume that the login details for both will be unavailable and therefore not try to carry out the task?

    Some of the actions it carries out must be working and using MySQL as I can create accounts and see their details in the ispconfig database tables.

    Another thing that makes me think maybe this is all MySQL related is that the problems occurred soon after I had modified a users remote access in the mysql command line.
    I didn't touch the ispconfig database but I've use the following command to allow me to view several databases remotely:

    mysql> GRANT ALL ON <db_name>.* TO [email protected]'<my_ip>' IDENTIFIED BY '<my_root_password>';

    I didn't do this to my ispconfig database but it was after I did this that my ftp went down and fetchmail stopped running.

    Any ideas? Is there something I can do to the ispconfig configuration that would refresh it's MySQL settings or something and get this working again?
  9. fooboo

    fooboo New Member

    Just scrolling through my rsyslog I noticed the line below:

    warning: connect to mysql server Can't connect to MySQL server on '' (111)

    But my websites still connect ok.
  10. falko

    falko Super Moderator ISPConfig Developer

    What's the output of
    netstat -tap
  11. fooboo

    fooboo New Member

    I've worked out that I can connect to mysql using 'localhost' but not '' so I'm guessing somewhere ISPConfig is configured to use instead of localhost.
    I either need to get mysql to consider to be local host or find the setting in ispconfig and change it to localhost...I don't know how to do either.

    netstat -tap gave me the following:

    Active Internet connections (servers and established)
    Proto Recv-Q Send-Q Local Address               Foreign Address             State       PID/Program name
    tcp        0      0 *:806                       *:*                         LISTEN      1896/rpc.statd
    tcp        0      0 localhost.localdomain:10024 *:*                         LISTEN      2403/amavisd (maste
    tcp        0      0 localhost.localdomain:10025 *:*                         LISTEN      2494/master
    tcp        0      0 mail.<my_domain>.net:mysql      *:*                         LISTEN      2323/mysqld
    tcp        0      0 localhost.local:dyna-access *:*                         LISTEN      2233/clamd
    tcp        0      0 *:sunrpc                    *:*                         LISTEN      1846/portmap
    tcp        0      0 *:ftp                       *:*                         LISTEN      2547/pure-ftpd (SER
    tcp        0      0 mail.<my_domain>.net:domain     *:*                         LISTEN      2359/mydns
    tcp        0      0 localhost.localdomai:domain *:*                         LISTEN      2359/mydns
    tcp        0      0 localhost.localdomain:ipp   *:*                         LISTEN      2218/cupsd
    tcp        0      0 *:smtp                      *:*                         LISTEN      2494/master
    tcp       35      0 mail.<my_domain>.net:50932      relay.<pop_domain>.net:pop3        CLOSE_WAIT  13670/python
    tcp       38      0 localhost.localdomain:smtp  localhost.localdomain:44673 CLOSE_WAIT  10228/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:53057 CLOSE_WAIT  4882/smtpd
    tcp       38      0 localhost.localdomain:smtp  localhost.localdomain:42337 CLOSE_WAIT  15193/smtpd
    tcp        1      0 mail.<my_domain>.net:smtp       mail-1.<smtp_domain>.net:50196   CLOSE_WAIT  8613/smtpd
    tcp       35      0 mail.<my_domain>.net:60542      pop.<pop_domain>.net:pop3         CLOSE_WAIT  16284/python
    tcp       38      0 localhost.localdomain:smtp  localhost.localdomain:37955 CLOSE_WAIT  14424/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:52259 ESTABLISHED 12879/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:44708 ESTABLISHED 16331/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:43972 CLOSE_WAIT  6314/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:59204 CLOSE_WAIT  10467/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:40901 ESTABLISHED 13284/smtpd
    tcp        1      0 mail.<my_domain>.net:smtp       mail-1.<smtp_domain>.net:15602   CLOSE_WAIT  13822/smtpd
    tcp       35      0 mail.<my_domain>.net:33514      relay.<pop_domain>.net:pop3        CLOSE_WAIT  15843/python
    tcp       35      0 mail.<my_domain>.net:58038      relay.<pop_domain>.net:pop3        CLOSE_WAIT  14091/python
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:53765 CLOSE_WAIT  8147/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:44645 CLOSE_WAIT  8904/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:49896 CLOSE_WAIT  7760/smtpd
    tcp        1      0 mail.<my_domain>.net:smtp       mail-1.<smtp_domain>.net:41727   CLOSE_WAIT  3946/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:34345 CLOSE_WAIT  9682/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:37130 ESTABLISHED 15463/smtpd
    tcp       35      0 mail.<my_domain>.net:36115      relay.<pop_domain>.net:pop3        CLOSE_WAIT  12007/python
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:56267 CLOSE_WAIT  9275/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:33035 CLOSE_WAIT  10852/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:46091 ESTABLISHED 12450/smtpd
    tcp       35      0 mail.<my_domain>.net:43972      relay.<pop_domain>.net:pop3        CLOSE_WAIT  16760/python
    tcp        1      0 mail.<my_domain>.net:smtp       mail-1.<smtp_domain>.net:55867   CLOSE_WAIT  11635/smtpd
    tcp       38      0 localhost.localdomain:smtp  localhost.localdomain:37773 CLOSE_WAIT  5715/smtpd
    tcp       38      0 localhost.localdomain:smtp  localhost.localdomain:53069 CLOSE_WAIT  5101/smtpd
    tcp       35      0 mail.<my_domain>.net:35335      relay.<pop_domain>.net:pop3        CLOSE_WAIT  14968/python
    tcp        1      0 mail.<my_domain>.net:smtp       mail-1.<smtp_domain>.net:32856   CLOSE_WAIT  5716/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:57743 CLOSE_WAIT  4196/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:43887 ESTABLISHED 12050/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:45936 ESTABLISHED 14578/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:38641 CLOSE_WAIT  4546/smtpd
    tcp        1      0 mail.<my_domain>.net:smtp       mail-ww0-f54.google.c:41119 CLOSE_WAIT  13335/smtpd
    tcp       35      0 mail.<my_domain>.net:56261      pop.<pop_domain>.net:pop3         CLOSE_WAIT  13241/python
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:53428 ESTABLISHED 16807/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:44661 CLOSE_WAIT  10059/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:53301 CLOSE_WAIT  11264/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:55478 CLOSE_WAIT  3534/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:45526 ESTABLISHED 13716/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:54038 CLOSE_WAIT  7032/smtpd
    tcp       35      0 mail.<my_domain>.net:36914      relay.<pop_domain>.net:pop3        CLOSE_WAIT  12408/python
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:37911 CLOSE_WAIT  7408/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:37943 ESTABLISHED 14133/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:42327 ESTABLISHED 15010/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:53977 CLOSE_WAIT  3871/smtpd
    tcp       35      0 mail.<my_domain>.net:48848      relay.<pop_domain>.net:pop3        CLOSE_WAIT  15422/python
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:53177 CLOSE_WAIT  11652/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:50713 CLOSE_WAIT  3177/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:59994 CLOSE_WAIT  5961/smtpd
    tcp       38      0 localhost.localdomain:smtp  localhost.localdomain:56283 CLOSE_WAIT  9517/smtpd
    tcp        0      0 localhost.localdomain:smtp  localhost.localdomain:36060 ESTABLISHED 15898/smtpd
    tcp       35      0 mail.<my_domain>.net:45773      pop.<pop_domain>.net:pop3         CLOSE_WAIT  14536/python
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:46301 CLOSE_WAIT  5242/smtpd
    tcp       35      0 mail.<my_domain>.net:47564      relay.<pop_domain>.net:pop3        CLOSE_WAIT  12832/python
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:48254 CLOSE_WAIT  6686/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:50623 CLOSE_WAIT  8512/smtpd
    tcp        1      0 localhost.localdomain:smtp  localhost.localdomain:37759 CLOSE_WAIT  5584/smtpd
    tcp        0      0 *:imaps                     *:*                         LISTEN      2421/couriertcpd
    tcp        0      0 *:pop3s                     *:*                         LISTEN      2433/couriertcpd
    tcp        0      0 *:pop3                      *:*                         LISTEN      2427/couriertcpd
    tcp        0      0 *:imap                      *:*                         LISTEN      2414/couriertcpd
    tcp        0      0 *:webcache                  *:*                         LISTEN      2528/httpd
    tcp        0      0 *:http                      *:*                         LISTEN      2528/httpd
    tcp        0      0 *:ftp                       *:*                         LISTEN      2547/pure-ftpd (SER
    tcp        0      0 localhost6.localdoma:domain *:*                         LISTEN      2359/mydns
    tcp        0      0 *:ssh                       *:*                         LISTEN      2203/sshd
    tcp        0      0 *:https                     *:*                         LISTEN      2528/httpd
    tcp        0      0 mail.<my_domain>.net:imap       host<my_IP>:mediacntrlnfsd ESTABLISHED 3058/imapd
    tcp        0      0 localhost.localdomain:40901 localhost.localdomain:smtp  ESTABLISHED 13304/o2JEt7wr01330
    tcp        0      0 localhost.localdomain:45526 localhost.localdomain:smtp  ESTABLISHED 13732/o2JF06fc01373
    tcp        0      0 localhost.localdomain:37130 localhost.localdomain:smtp  ESTABLISHED 15483/o2JFK6nT01548
    tcp        0      0 localhost.localdomain:53428 localhost.localdomain:smtp  ESTABLISHED 16823/o2JFZ6vw01682
    tcp        0      0 localhost.localdomain:45936 localhost.localdomain:smtp  ESTABLISHED 14598/o2JFA5do01459
    tcp        0      0 localhost.localdomain:46091 localhost.localdomain:smtp  ESTABLISHED 12470/o2JEj5Wu01247
    tcp        0      0 localhost.localdomain:37943 localhost.localdomain:smtp  ESTABLISHED 14153/o2JF56BN01415
    tcp        0   2496 mail.<my_domain>.net:ssh        host<my_IP>.in-a:4617 ESTABLISHED 16552/1
    tcp        0      0 localhost.localdomain:43887 localhost.localdomain:smtp  ESTABLISHED 12071/o2JEe7Y401207
    tcp        0      0 localhost.localdomain:36060 localhost.localdomain:smtp  ESTABLISHED 15918/o2JFP6h901591
    tcp        0      0 localhost.localdomain:52259 localhost.localdomain:smtp  ESTABLISHED 12899/o2JEoAVb01289
    tcp        0      0 localhost.localdomain:44708 localhost.localdomain:smtp  ESTABLISHED 16347/o2JFU59M01634
    tcp        0      0 mail.<my_domain>.net:ssh        host<my_IP>:cvspserver ESTABLISHED 3323/0
    tcp        0      0 localhost.localdomain:42327 localhost.localdomain:smtp  ESTABLISHED 15030/o2JFF6kl01503
  12. andreasnrb

    andreasnrb New Member

    Check /etc/pure-ftpd/db/mysql.conf
    Perhaps change MySQLServer to localhost
  13. fooboo

    fooboo New Member

    Thanks, that worked for my ftp logins...they are finally back in action :D

    You wouldn't happen to know what file I could modify to fix my fetchmail connection would you? It has the same problem with trying to use instead of localhost.
  14. till

    till Super Moderator Staff Member ISPConfig Developer

    Please post the content of the /etc/hosts file.
  15. fooboo

    fooboo New Member localhost.localdomain localhost ...
    ::1 localhost6.localdomain6 localhost6
    <my public IP> <my domain>
    <my private IP> <my domain>
  16. till

    till Super Moderator Staff Member ISPConfig Developer

    Remove the lines: localhost.localdomain localhost ...

    and replace them with this one line: localhost.localdomain localhost
  17. fooboo

    fooboo New Member

    I've done that but I don't think it's made a difference to my fetchmail problem.
    ISPConfig still thinks that MySQL server is down and I'm not getting any mail coming in.
  18. till

    till Super Moderator Staff Member ISPConfig Developer

    Fetchmail is not using any mysql connections. The question is, waht exactly did you change that caused all the services to not listen anymore on localhost as we have to undo these changes to fix all the services.
  19. fooboo

    fooboo New Member

    I had a working system using ISPConfig that was fetching mail into dovecot and serving several websites.

    I've been trying to recover an install of bugzilla so I've recently added a couple of bugzilla sites to my server and I installed Nagios to monitor my sites but everything seemed to still be working after these installs.

    I wanted to be able to administer my databases from my work computer so I logged into MySQL and ran the command below on several databases (not the ispconfig database though):

    mysql> GRANT ALL ON <db_name>.* TO [email protected]'<my_ip>' IDENTIFIED BY '<my_root_password>';

    This worked fine and I could manipulate the databases remotely, but my ftp accounts stopped working. It wasn't until the next day when I hadn't had any new mail that I realised it was more than just my ftp accounts affected so I went to the monitor section of ISPConfig and it says the MySQL server is down...which it isn't as I can still administer the databases.

    I can't see why it stopped as it seems to have stopped at the time when I granted remote access to my databases but I didn't touch the ispconfig database and I didn't reset any other permissions I just added some new ones.
  20. abubin

    abubin New Member

    I just installed 3.0.2 on my ubuntu 8.04 LTS and faced similar problem. It worked fine in another server with on ubuntu 8.04 LTS.

    Anyway, I followed the guide here and enabled verbose logging on my pureftp. Then saw some error on ispconfig trying to access mysql using 'ispconfig'@'localhost'. Then I check in my mysql privileges and only see ispconfig with only. Then I changed that to localhost and it is working now.

    But my question is, will this cause any problem on other ispconfig script that might try to access using 'ispconfig'@'localhost'?

Share This Page