LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

My first attempt

To: <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: My first attempt
From: "Ivan Figueredo" <idf@xxxxxxxxxxxxxx>
Date: Thu, 18 Jan 2001 02:54:13 -0600
Hello,

This is my first attempt at setting up an LVS. Pleasse forgive me if I am
being a bonehead.

I have three machines, all on a private network:

"Client:"---------------
192.168.168.5
-----------------------


"Director:"---------------
[root@wee2 httpd]# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:90:27:32:23:07
          inet addr:192.168.168.2  Bcast:192.168.168.7  Mask:255.255.255.248
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:7671 errors:0 dropped:0 overruns:0 frame:0
          TX packets:5958 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          Interrupt:12 Base address:0xe400

eth1      Link encap:Ethernet  HWaddr 00:60:08:3D:44:60
          inet addr:192.168.168.6  Bcast:192.168.168.255
Mask:255.255.255.248
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:29083 errors:0 dropped:0 overruns:0 frame:0
          TX packets:20 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          Interrupt:10 Base address:0x300

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:3924  Metric:1
          RX packets:278 errors:0 dropped:0 overruns:0 frame:0
          TX packets:278 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
----------------------


"Real Server:"-------------
[root@wee0 heartbeat]# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:A0:CC:58:D5:97
          inet addr:192.168.168.3  Bcast:192.168.168.15
Mask:255.255.255.240
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:43486 errors:0 dropped:0 overruns:0 frame:0
          TX packets:6987 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          Interrupt:4 Base address:0xf400

eth1      Link encap:Ethernet  HWaddr 00:60:08:C2:2C:93
          inet addr:192.168.168.4  Bcast:192.168.168.15
Mask:255.255.255.240
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:302025 errors:0 dropped:0 overruns:0 frame:0
          TX packets:624 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          Interrupt:10 Base address:0xfc40

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:3924  Metric:1
          RX packets:237 errors:0 dropped:0 overruns:0 frame:0
          TX packets:237 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
--------------------------

As per man page, on the Director, I did:

[root@wee2 httpd]# echo 1 > /proc/sys/net/ipv4/ip_forward
[root@wee2 httpd]# echo 1 > /proc/sys/net/ipv4/ip_always_defrag
[root@wee2 httpd]# ipchains -A forward -j MASQ -s 192.168.168.0/24 -d
0.0.0.0/0

Then I did:

[root@wee2 httpd]# ipvsadmin -A -t 192.168.168.2:80 -s rr
[root@wee2 httpd]# ipvsadm -a -t 192.168.168.2:80 -r 192.168.168.3 -m

On the Director, before I browse, I did a:

[root@wee2 httpd]# ipvsadm -l
IP Virtual Server version 0.8.3 (size=4096)
Protocol LocalAddress:Port Scheduler Flags
      -> RemoteAddress:Port    Forward Weight ActiveConn InActConn
TCP 192.168.168.2:80 rr
      -> 192.168.168.3:80      Masq    1      0          0

Now on client, I browsed to 192.168.168.2. It hangs and then displays error.

At the same time on the Director, while trying to browse to it I did a:

[root@wee2 httpd]# ipvsadm -l
IP Virtual Server version 0.8.3 (size=4096)
Protocol LocalAddress:Port Scheduler Flags
      -> RemoteAddress:Port    Forward Weight ActiveConn InActConn
TCP 192.168.168.2:80 rr
      -> 192.168.168.3:80      Masq    1      0          1


I am not sure what I am doing wrong. I thought I saw a post about LVS not
working if all machines are on the same (sub)net, but I am not sure...

Regards,

Ivan









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