Direct LVS with dual VIP not responding to 2nd VIP

"Posts" <[email protected]>
Newsgroups gmane.linux.redhat.piranha
Message-ID <000001c2d260$cb924790$6501a8c0@XP1>
Hi,
 
This is probably an apache setup but I am hoping someone here has seen
and solved this problem.
 
I have one director with two VIP's and one real server.
 
Director has both VIP entries in lvs.cf, ifcfg-eth0:xyz is up, and
ipvsadm display looks correct showing both VIP's responding.
 
Real server has iptables redirect setup, running apache 1.3 with a
default DocumentRoot and a <VirtualHost VIP-2> setup.
 
I can browse to VIP-1 and the default website comes up. What happens is
that when I browse to VIP-2 the default site comes up again instead of
site2 even though ipvsadm shows that a connection was made to VIP-2.
 
Any tips or suggestions are appreciated. Relevant files below.
 
Kawika Ohumukini
 
 
============================
DIRECTOR: LVS.CF
 
serial_no = 8
primary = 206.55.140.26
service = lvs
rsh_command = ssh
backup = 0.0.0.0
heartbeat = 1
heartbeat_port = 539
keepalive = 6
deadtime = 18
network = direct
reservation_conflict_action = preempt
debug_level = NONE
virtual 100 {
     active = 1
     address = 206.55.140.100 eth0:100
     port = 80
     send = "GET / HTTP/1.0\r\n\r\n"
     expect = "HTTP"
     load_monitor = ruptime
     scheduler = wlc
     protocol = tcp
     timeout = 6
     reentry = 15
     server RS1 {
         address = 206.55.140.41
         active = 1
         weight = 1
     }
}
virtual 101 {
     active = 1
     address = 206.55.140.101 eth0:101
     port = 80
     send = "GET / HTTP/1.0\r\n\r\n"
     expect = "HTTP"
     load_monitor = ruptime
     scheduler = wlc
     protocol = tcp
     timeout = 6
     reentry = 15
     server RS1 {
         address = 206.55.140.41
         active = 1
         weight = 1
     }
}

============================
REAL SERVER: In rc.local
 
iptables -t nat -A PREROUTING -d 206.55.140.100 -j REDIRECT
iptables -t nat -A PREROUTING -d 206.55.140.101 -j REDIRECT
 
 
============================
REAL SERVER: In httpd.conf
 
...
################################
# SITE 1
DocumentRoot "/usr/local/www/htdocs"
<Directory "/usr/local/www/htdocs">
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>
################################
# SITE 2
<Directory "/usr/local/www2/htdocs">
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>
<VirtualHost 206.55.140.101>
    DocumentRoot /usr/local/www2/htdocs
    ServerName www.site2.com
</VirtualHost>

...
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.