Troubleshooting the ProFTPd FTP Server

Also general FTP, SFTP, and SCP issues.

My FTP server shows as being up under the shell but NodeWorx says it is not. How do I fix this?

NodeWorx does a fsockopen on the ftp port to 127.0.0.1. Can you give that a try and see if you get the ‘ftp ready’ message. Some folks block local ftp connections and this would interfere with the check.

Create a test file called, for example, /home/interworx/nodeworx/html/ftp-test.php. In it, put the following code:

<?
$fp = @fsockopen( "localhost",
                  21,
                  $errno,
                  $errstr,
                  30 );
if ( $fp === false ) {
  print "FTP NOT started!";
  var_dump( $errno, $errstr );
} else {
  print "FTP started!";
}
?>

Save and exit the file, then open up the page in your browser:

https://yourserver:2443/nodeworx/ftp-test.php

If FTP isn’t started, you’ll get a dump of information. If it is started, all you’ll see is “FTP Started!”. If you get this message, try doing a Shift-Reload of the FTP page.

I am having problems with proftpd after editing it's configuration file. What's wrong?

Frequently people edit the /etc/proftpd.conf and have problems so they restore from a proftpd configuration file from another InterWorx server or other box with proftpd on it. When this happens the file will have an incorrect password for the iworx tables because each box has a unique and random iworx password. This is a problem because proftpd logins are authenticated against ftp users stored in the iworx database, NOT /etc/users.

To locate this locate the iworx user password by doing by executing the following command.

cat /home/interworx/iworx.ini | grep dsn=


This will give several instances of both dns= and rootdns= Take the dsn= password (e.g. something@unix) and insert it into the following line from /etc/proftpd.conf

SQLConnectInfo iworx_ftp@127.0.0.1:2306 iworx <password>


where <password> is the iworx password (do not add the @unix part).

Then restart proftod

service proftpd restart or service proftpd start (if the service is down)

COPYRIGHT © InterWorx L.L.C. 2004-2008 PRIVACY POLICYEULA