LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: [lvs-users] Accessing lvs from client on same network

To: lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re: [lvs-users] Accessing lvs from client on same network
From: Nissim <nissim@xxxxxxxxxxxxx>
Date: Wed, 26 Jan 2000 07:21:40 -0500
> The reason is that the LVS/NAT just translate the destination of
> request packets and change the source of response packets back to the
> VIP address. If the client is in the network of real server, real
> server will send response packets to the client directly, and the load
> balancer won't have chance to change the source of response packets
> back to the VIP, so the connection wait forever.
> 
> > Is there a solution to this?
> >
> 
> Put your clients in another private network like 192.168.2.0/24, and
> let your LVS/NAT cluster has its own private network.
> 
> Wensong
> 

OK, this isn't really directly related to LVS anymore, but I'm having
trouble setting this up.  Is it possible to have two private subnets
using IP aliasing.

Like this (All three machines are connected to the same switch):

Router:
ifconfig eth0 192.168.1.1 up
ifconfig eth0:0 192.168.2.1 up
route add -net 192.168.1.0/24 dev eth0
route add -net 192.168.2.0/24 dev eth0
ipchains -A forward -j MASQ -s 192.168.1.0/24
ipchains -A forward -j MASQ -s 192.168.2.0/24

Client1:
ifconfig eth0 192.168.1.10 up
route add -net 192.168.1.0/24 dev eth0
route add default gw 192.168.1.1

Client2:
ifconfig eth0 192.168.2.10 up
route add -net 192.168.2.0/24 dev eth0
route add default gw 192.168.2.1

With this in place I can ping client2 from client1.  Is there a way to
prevent this without getting an additional NIC and hub?

        -Nissim

----------------------------------------------------------------------
LinuxVirtualServer.org mailing list - lvs-users@xxxxxxxxxxxxxxxxxxxxxx
To unsubscribe, e-mail: lvs-users-unsubscribe@xxxxxxxxxxxxxxxxxxxxxx
For additional commands, e-mail: lvs-users-help@xxxxxxxxxxxxxxxxxxxxxx

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