Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux Virtual Server: Users

[lvs-users] keepalived removing all IPs

 

 

Linux Virtual Server users RSS feed   Index | Next | Previous | View Threaded


bgs at bgs

Mar 21, 2008, 4:24 AM

Post #1 of 6 (531 views)
Permalink
[lvs-users] keepalived removing all IPs

Greetings,

I playing with keepalived to replace our current custom system, but
have some problems. The main one is that whenever I stop keepalived, it
removes all IPs from the outside interface and consequently it's default
route as well. Adding additional non-keepalived handled IPs to the
interface doesn't change a thing.
Any ideas? Bug or config error?

The setup is a very simple one. Here are the main things (the auth part
is not used yet as it's the only node atm):

vrrp_instance LB02_1 {
state MASTER
interface bond0
virtual_router_id 51
priority 100
advert_int 1
authentication {
auth_type PASS
auth_pass 1111
}
virtual_ipaddress {
6 IPs are here
}
}

The bond0 interface has an additional IP not on the above list. When I
fire up keepalived, it adds the 6 VIPs. When I shut it down, it removes
all 7 IPs on the interface and default gw is lost...


Regards
Bgs

_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users


graeme at graemef

Mar 21, 2008, 4:33 AM

Post #2 of 6 (492 views)
Permalink
Re: [lvs-users] keepalived removing all IPs [In reply to]

On Fri, 2008-03-21 at 12:24 +0100, Bgs wrote:
> Any ideas? Bug or config error?

I hate to have to say this, but: man keepalived

You need either or both of:

--dont-release-vrrp, -V
leave (don’t remove) VRRP VIPs & VROUTEs on daemon stop.
--dont-release-ipvs, -I
Dont remove IPVS topology on daemon stop.

Graeme


_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users


bgs at bgs

Mar 21, 2008, 4:38 AM

Post #3 of 6 (504 views)
Permalink
Re: [lvs-users] keepalived removing all IPs [In reply to]

I do want keepalived to remove the VIPs when I shut it down.
("do-release-ipvs"). My problem is that keepalived removed other IPs too
that it's not supposed to handle...

Or does 'release vips' mean wipe all addresses from interface?

Graeme Fowler wrote:
> On Fri, 2008-03-21 at 12:24 +0100, Bgs wrote:
>> Any ideas? Bug or config error?
>
> I hate to have to say this, but: man keepalived
>
> You need either or both of:
>
> --dont-release-vrrp, -V
> leave (don’t remove) VRRP VIPs & VROUTEs on daemon stop.
> --dont-release-ipvs, -I
> Dont remove IPVS topology on daemon stop.
>
> Graeme
>
>
> _______________________________________________
> LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
> Send requests to lvs-users-request [at] LinuxVirtualServer
> or go to http://lists.graemef.net/mailman/listinfo/lvs-users

_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users


bgs at bgs

Mar 21, 2008, 4:47 AM

Post #4 of 6 (496 views)
Permalink
Re: [lvs-users] keepalived removing all IPs [In reply to]

Following the 'wipe' idea I found what the problem is. Using ipvs I
had my addresses use normal netmask (/27 in this case). Apparently
keepalived removed the whole range defined by that netmask. So if you
have 192.168.0.2/27 in keepalived.conf and you manually add
192.168.0.3/27 too then .3 will be removed too. Adding VIPs with /32
solves this problem.

Is this behavior made on purpose?

Regards
Bgs


Bgs wrote:
> I do want keepalived to remove the VIPs when I shut it down.
> ("do-release-ipvs"). My problem is that keepalived removed other IPs too
> that it's not supposed to handle...
>
> Or does 'release vips' mean wipe all addresses from interface?
>
> Graeme Fowler wrote:
>> On Fri, 2008-03-21 at 12:24 +0100, Bgs wrote:
>>> Any ideas? Bug or config error?
>> I hate to have to say this, but: man keepalived
>>
>> You need either or both of:
>>
>> --dont-release-vrrp, -V
>> leave (don’t remove) VRRP VIPs & VROUTEs on daemon stop.
>> --dont-release-ipvs, -I
>> Dont remove IPVS topology on daemon stop.
>>
>> Graeme
>>
>>
>> _______________________________________________
>> LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
>> Send requests to lvs-users-request [at] LinuxVirtualServer
>> or go to http://lists.graemef.net/mailman/listinfo/lvs-users
>
> _______________________________________________
> LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
> Send requests to lvs-users-request [at] LinuxVirtualServer
> or go to http://lists.graemef.net/mailman/listinfo/lvs-users

_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users


alshu at tut

Mar 21, 2008, 6:27 AM

Post #5 of 6 (495 views)
Permalink
Re: [lvs-users] keepalived removing all IPs [In reply to]

> Following the 'wipe' idea I found what the problem is. Using ipvs I
> had my addresses use normal netmask (/27 in this case). Apparently
> keepalived removed the whole range defined by that netmask. So if you
> have 192.168.0.2/27 in keepalived.conf and you manually add
> 192.168.0.3/27 too then .3 will be removed too. Adding VIPs with /32
> solves this problem.
>
> Is this behavior made on purpose?
>
> Regards
> Bgs
>
>
> Bgs wrote:
>> I do want keepalived to remove the VIPs when I shut it down.
>> ("do-release-ipvs"). My problem is that keepalived removed other IPs too
>> that it's not supposed to handle...
>>
>> Or does 'release vips' mean wipe all addresses from interface?
>>
>> Graeme Fowler wrote:
>>> On Fri, 2008-03-21 at 12:24 +0100, Bgs wrote:
>>>> Any ideas? Bug or config error?
>>> I hate to have to say this, but: man keepalived
>>>
>>> You need either or both of:
>>>
>>> --dont-release-vrrp, -V
>>> leave (don’t remove) VRRP VIPs & VROUTEs on daemon stop.
>>> --dont-release-ipvs, -I
>>> Dont remove IPVS topology on daemon stop.
>>>
>>> Graeme


This my config:

...
vrrp_instance VI_WWW {
state MASTER
interface vlan102
track_interface {
vlan35
}
lvs_sync_daemon_inteface vlan34
mcast_src_ip 192.168.34.3
garp_master_delay 3
virtual_router_id 51
priority 150
# advert_int 1
# authentication {
# auth_type PASS
# auth_pass example
# }
virtual_ipaddress {
172.16.11.4/24 <---- VIP
}
debug 0
# smtp_alert
}
...

This is my output:

lbcnode1:/etc/keepalived # ip a l dev vlan102
5: vlan102: <BROADCAST,MULTICAST,MASTER,UP> mtu 1500 qdisc noqueue
link/ether 00:14:c2:3b:c3:f3 brd ff:ff:ff:ff:ff:ff
inet 172.16.11.6/24 brd 172.16.11.255 scope global vlan102
inet 172.16.11.4/24 scope global secondary vlan102
inet6 fe80::214:c2ff:fe3b:c3f3/64 scope link
valid_lft forever preferred_lft forever
lbcnode1:/etc/keepalived # /etc/init.d/keepalived stop
Shutting down Keepalived daemon done
lbcnode1:/etc/keepalived # ip a l dev vlan102
5: vlan102: <BROADCAST,MULTICAST,MASTER,UP> mtu 1500 qdisc noqueue
link/ether 00:14:c2:3b:c3:f3 brd ff:ff:ff:ff:ff:ff
inet 172.16.11.6/24 brd 172.16.11.255 scope global vlan102
inet6 fe80::214:c2ff:fe3b:c3f3/64 scope link
valid_lft forever preferred_lft forever

Where do you see problem?
Alex


-----------
Работа для JAVA – программистов, сделайте карьеру с нами!
Ирландский проект, новые возможности, технология успеха.
Резюме присылайте на hr [at] g2x

_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users


graeme at graemef

Mar 21, 2008, 7:28 AM

Post #6 of 6 (496 views)
Permalink
Re: [lvs-users] keepalived removing all IPs [In reply to]

On Fri, 2008-03-21 at 12:47 +0100, Bgs wrote:
> Is this behavior made on purpose?

No. Something - likely in your config - is wrong.

Please post your full VRRP config, including the VIP definitions,
unedited.

Graeme


_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users

Linux Virtual Server users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.