Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am having problems with ProFTPD server, because I am not able to set it to work correctly when multiple ports are active (IP address is the same).

In my proftpd.conf file, I have added this section:

    Port                        2122
    Umask                       022
    ServerName                  "Example"
    DefaultRoot                 /home/usr1/www/example1
    UserAlias                   fuser usr1

    # Valid LOGINs
    <Limit LOGIN>
        AllowUser usr1

So, when I try to establish connection to port 21, everything is ok, and I get directory listing. But when I try to establish connection to port 2122, it connects, but I get an error 500 Illegal PORT command at the very end.

In Linux Firewall ports 21 and 2122 are opened.

This is what I get when execute netstat -lpn | grep ftp

tcp6       0      0 :::2122                 :::*                    LISTEN      30597/proftpd: (acc
tcp6       0      0 :::21                   :::*                    LISTEN      30597/proftpd: (acc

Now, I am not sure, where could be a problem with this virtual server, and why I cannot get directory listing at the very end.

The point is, that I need two FTPs, since some of users should connect to the first one, and some of them to the second. Every FTP has its own home directory.

If needed, I can provide the full proftpd.conf file.

share|improve this question

migrated from Jul 27 '12 at 10:29

This question came from our site for professional and enthusiast programmers.

There is passive and active mode in FTP server, for active mode you will need to open a port range. In active mode FTP server opens a random port for data transfer, then client connects to the random port. If your firewall block this port, then directory listing, and data transfer will fail.

In passive mode, client opens new port then tells the server to connect it for data transfer. Passive mode would not work with all routers, client may cannot open a port for data transer.

Solution: Open a port range (eg. 1500 to 2000), then configure your FTP server to use these ports.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.