LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

RE: LVS-NAT two nic / two network problem

To: "'lvs-users@xxxxxxxxxxxxxxxxxxxxxx'" <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: RE: LVS-NAT two nic / two network problem
From: "Lizambri, Todd" <tlizambri@xxxxxxxxxxxx>
Date: Thu, 21 Mar 2002 08:43:16 -0500
Sorry I don?t have time to see if this is actually your problem, but I
have the exact set-up using the configure scripts (except for one
thing). The only noticeable difference between what I have and what you
have is that I have an address for eth0 and eth1 in addition to the
aliases I create. Should be simple to try. Set-up eth0 to be
192.168.100.10 and eth1 to be 192.168.8.10 and rerun the config scripts.


> Everyone - I am trying to configure a NAT LVS using two nics and two
> networks on the director.  I have previously set up a one nic two
> network director - this works as expected but is not suitable for my
> application my current setup is:
> 
>                         ________
>                        |        |
>                        | client |
>                        |________|
>                            | CIP 192.168.8.1
>                            |
>                            |
>                            |
>                            |
>                       _____|____
>                      |          | VIP (eth1:40) 192.168.8.40
>                      + director |
>                      |__________| DIP (eth0:1)  192.168.100.1
>                            |
>                            |
>                            |
>          +-----------------+----------------+
>          |                 |                |
>          |                 |                |
>      RIP1 192.168.100.2 RIP2 192.168.100.3  RIP3 192.168.100.4
>     ____________      ____________    ____________
>    |            |    |            |  |            |
>    |realserver1 |    |realserver2 |  |realserver3 |
>    |____________|    |____________|  |____________|
> 
> 
>         CIP  = 192.168.8.1 - directly connected to the director
>         DIP  = 192.168.100.1      (eth0:1)
>         VIP1 = 192.168.8.40    (director: eth1:40)
>         RIP1 = 192.168.100.2     
>         RIP2 = 192.168.100.3    
>         RIP3 = 192.168.100.4    
> 
> My problem is that if I tcpdump both interfaces on the 
> director and then
> send a request from the client no packets come out eth0:1.  I have
> ipv4_forwarding turned on.  I can ping the RIP's from the CIP.  I can
> ping the CIP from the Realservers.  Can telnet from the 
> director to the
> realservers.  traceroute's from the realservers go through 
> the director
> to get to the client.
> 
> Unfortunately I am running RedHat7.2 (kernel 2.4.9) - and am 
> stuck using
> the ipvs-0.8.2 which came preinstalled.  I am currently trying to
> compile ipvs-1.0.0 against a 'clean' kernel.org kernel - but redhat is
> not making it easy (no ext3 support in the kernel.org tree).
> 
> Output from various things on the director:
> ipvsadm:
> IP Virtual Server version 0.8.1 (size=65536)                   
> Prot LocalAddress:Port Scheduler Flags                         
>   -> RemoteAddress:Port             Forward Weight ActiveConn 
> InActConn
> TCP  piranha:telnet rr
>   -> 192.168.100.3:telnet           Masq    2      0          
> 0         
>   -> 192.168.100.2:telnet           Masq    1      0          
> 0         
> TCP  piranha:http rr
>   -> 192.168.100.3:http             Masq    1      0          
> 0         
>   -> 192.168.100.2:http             Masq    1      0          
> 0         
> 
> ifconfig:
> eth0      Link encap:Ethernet  HWaddr 00:06:29:4E:57:5E  
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           RX packets:694 errors:0 dropped:0 overruns:0 frame:0
>           TX packets:1006 errors:0 dropped:0 overruns:0 carrier:0
>           collisions:420 txqueuelen:100 
>           RX bytes:58564 (57.1 Kb)  TX bytes:802493 (783.6 Kb)
>           Interrupt:11 Base address:0xe000 
> 
> eth0:1    Link encap:Ethernet  HWaddr 00:06:29:4E:57:5E  
>           inet addr:192.168.100.1  Bcast:192.168.100.255
> Mask:255.255.255.0
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           Interrupt:11 Base address:0xe000 
> 
> eth1      Link encap:Ethernet  HWaddr 00:50:BA:6C:5B:17  
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           RX packets:17582 errors:0 dropped:0 overruns:0 frame:0
>           TX packets:8617 errors:12 dropped:0 overruns:0 carrier:6
>           collisions:4730 txqueuelen:100 
>           RX bytes:23720033 (22.6 Mb)  TX bytes:773990 (755.8 Kb)
>           Interrupt:10 Base address:0x7800 
> 
> eth1:40   Link encap:Ethernet  HWaddr 00:50:BA:6C:5B:17  
>           inet addr:192.168.8.40  Bcast:192.168.8.255
> Mask:255.255.255.0
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           Interrupt:10 Base address:0x7800
> 
> netstat -nr
> Kernel IP routing table
> Destination     Gateway         Genmask         Flags   MSS 
> Window  irtt
> Iface
> 192.168.8.40    0.0.0.0         255.255.255.255 UH       40 0 
>          0
> eth1
> 192.168.100.0   0.0.0.0         255.255.255.0   U        40 0 
>          0
> eth0
> 192.168.8.0     0.0.0.0         255.255.255.0   U        40 0 
>          0
> eth1
> 127.0.0.0       0.0.0.0         255.0.0.0       U        40 0 
>          0
> lo
> 
> ipvsadm version:
> ipvsadm v1.17 2001/03/18 (compiled with popt and IPVS v0.8.2)
> 
> tcpdump output - eth1:40
> 15:49:17.965618 192.168.8.1.1177 > piranha.telnet: S
> 2766801928:2766801928(0) win 16384 <mss 1460,nop,nop,sackOK> (DF)
> 15:49:20.929381 192.168.8.1.1177 > piranha.telnet: S
> 2766801928:2766801928(0) win 16384 <mss 1460,nop,nop,sackOK> (DF)
> 15:49:26.937978 192.168.8.1.1177 > piranha.telnet: S
> 2766801928:2766801928(0) win 16384 <mss 1460,nop,nop,sackOK> (DF)
> 
> And finally heres my lvs.conf
> #----------lvs_nat.conf------------------------------------
> LVSCONF_FORMAT=1.1
> LVS_TYPE=VS_NAT
> INITIAL_STATE=on  
> CLEAR_IPVS_TABLES=yes
> VIP=eth1:40 192.168.8.40 255.255.255.0 192.168.8.255
> DIP=eth0:1 192.168.100.1 192.168.100.0 255.255.255.0 192.168.100.255
> DIRECTOR_GW=192.168.8.1
> SERVICE=t telnet rr 192.168.100.2:telnet,1 192.168.100.3:telnet,2 
> SERVICE=t http rr 192.168.100.2:http 192.168.100.3:http 
> SERVER_NET_DEVICE=eth0
> 
> Any tips appreciated;
> 
> jeremy

Attachment: smime.p7s
Description: S/MIME cryptographic signature

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