LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

PASV FTP

To: <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: PASV FTP
From: "lisj" <lisj@xxxxxxxxxxxxxxx>
Date: Tue, 23 Jul 2002 17:19:18 +0800
hi, everyone

I used ipvs to distribute the load of ftp server.
But I encountered a problem for PASV ftp, the following
is my configurations.

Client: TurboLinux6.1(kernel 2.2.15)
        IP:  192.168.0.1

Load Balancer: TurboLinux6.1(kernel 2.2.15-8)
        IPVS Version:  ipvs-0.9.13
        VIP:  192.168.0.2
        
        ipchains -A input -j ACCEPT -d 192.168.0.2 21 -p tcp -m 1
        ipchains -A input -j ACCEPT -d 192.168.0.2 1024:65535 -p tcp -m 1

        ipvsadm -A -f 1
        ipvsadm -a -f 1 -r 192.168.0.3 -g

Real Server: RedHat Linux7.1 (kernel 2.4.2-2)
        IP:  192.168.0.3

        ipchains -A input -j REDIRECT 21 -d 192.168.0.2 21 -p tcp
        ipchains -A input -j REDIRECT -d 192.168.0.2 1024:65535 -p tcp

I used the following command to ftp VIP:
    ftp -p 192.168.0.2
When I used tcpdump to watch the packets, I found that the connection to
port 21 passed through the Load Balancer(192.168.0.2), but the connection
to the data port didn't pass through the Load Balancer, just directly
went to the Real Server(192.168.0.3).

By the way, when I used Turbo Linux6.1(kernel 2.2.15) as the Real Server,
the data connection also passed through the Load Balancer.

What's the problem? 

Is there any difference in ftpd of RedHat Linux and Turbo Linux?

How can I let the data connection also pass through the Load Balancer 
when the ftp server is RedHat Linux?
 
Best regards!


<Prev in Thread] Current Thread [Next in Thread>