FTP port issues behind router


I have my server behind a router, forwarding the ports works fine - I can access the server IP and the setup domains just fine from the internet.

The problem arises when I try to connect to the ftp server for the setup domain name (the ftp user for that domain name exists and I connect with these details). Passive mode does not work at all. The active mode - it logs in authenticates the ftp password correctly, but then it does not show the contents of the domain folder - it times out with:

resolving sxxga.com...
Connect socket #748 to, port 21...
220 (vsFTPd 2.0.6)
USER sxxga
331 Please specify the password.
PASS **********
230 Login successful.
215 UNIX Type: L8
Keep alive off...
Attemping Active mode transfer...
PORT 93,103,103,26,41,139
200 PORT command successful. Consider using PASV.
425 Failed to establish connection.
Server failed to connect data port
Error loading directory...
421 Timeout.

I have opened ports 93,103,103 to help the situation. Do I have to open port from port 21 (external) to port 103 (internal) or from port 103 (external) to port 103 (inernal)? I have done both but id didn't work.

Accessing my sites and server from the same LAN the server is on is also not possible - I have put the external server IP 90.XX.157.XX.44 into the etc/hosts file in Win XP for both www.sxxga.com and sxxga.com.

What to do ? :)

Thank you very much for your assistance...


1. You need to open ports 20 <-> 20 and 21 <-> 21 this way, you should be able to use ftp. I dont have any idea about port 103

2. if you want to use your domain in same internal lan as your server, you need to update your hosts files; as you did . currently, there is no other way, i think.

I have had all the relevant ports open since the start including port 20.

Here is the screenshot of the virtual server setting:


The hosts file strings need o be like this right:? swega.com www.swega.com

Thank you,


your router config seems ok.

if you want to access your domains in same lan as your server, your hosts file should be: swega.com www.swega.com

because your internal net knows your server as internal ip
note that, outside world do not need such thing (otherwise, what is internet? dns?:) )