Re: Strange behavior with carp and preemption

2005-11-24 Thread Ralf Hornik Mailings
Hi Eli,

> Eli K. Breen wrote:
> Have you tried simply unplugging one's network cable? (to more closely
> replicate what would happen during a hard lock or panic?) I should think
> things won't be as smooth.

Thats correct. When ifconfig down one IF, then it works and the backup
becomes master on both interfaces. Not by unplugging the cable or power
off the switch. That was what I wanted to test

> Additionally, what happens if you shut the master down in to Single-User
> mode?
> I'm seeing a bug where if the MASTER is shutdown to single user mode it
> stops the BACKUP from becoming MASTER. ...which is somewhat disturbing
> as the original MASTER no longer actually performs any useful network
> functions, but it does prevent takeover of the ARP address.
>
> Has anyone else tested/run in to this?

This could be done in therory. Does the master send advertisements in
single user mode? When no network is enabled I don't think, that it keeps
being master.

However, the problem reproduced by unplugging the cable, can be solved by
workarounding using ifstated(8). :-(

Best regards

Ralf



Re: Strange behavior with carp and preemption

2005-11-22 Thread Ralf Hornik Mailings
Hi list,

I found out something new.

> Ralf Hornik Mailings schrieb:
> However, the advskew of carp1 on the master side keeps being zero,
> allthough showing itself as BACKUP. Should ifconfig show advskew 240 then?

tcpdump tells me although preemtion enabled an advskew of 0! After I look
at ifconfig, the carp1 (which is the IF to preempt) tcpdump shows an
advskew of 100 (which is the same value as the backup interface) but not
240!

Could this be a bug in preemption? Has anyone else successfully set up
carp with preemption? My OS is now OpenBSD 3.8 RELEASE. After going to
stable, I'll be back! :-)

Best regards

Ralf



Re: Strange behavior with carp and preemption

2005-11-11 Thread Ralf Hornik Mailings
Hi Nick,

> Nick Holland wrote:
> To the top of google we go! :)

Great! :-)

> are all the interfaces really in the carp group?

Yes, I believe, because carp works if I shut down the Box, or something...

> are the interfaces accurately and reliably detecting the cable-unplug?
> Might some NICs (or their drivers) have trouble detecting that the cable
> was suddenly unplugged, and thus, the change in advskew doesn't take

When I unplug the cable or power off the switch, carp0 (what is the
affected) goes into INIT and the carp1 goes into BACKUP. Then a can access
the backup machine via carp0. So that works.

However, the advskew of carp1 on the master side keeps being zero,
allthough showing itself as BACKUP. Should ifconfig show advskew 240 then?
That could be the problem...
Thank you and Best regards!

Ralf



Strange behavior with carp and preemption

2005-11-10 Thread Ralf Hornik Mailings
Dear list,

I set up two OpenBSD 3.7 -stable firewalls using carp. Everything works
except preemption.

When only one interface on the master side fails (pull the Cable) the
regarding carp0 interface on the backup side becomes master. But not
carp1.

I waited some minutes, but carp1 keeps being backup until I do a simple
ifconfig(8) on the master side. Then it changes immediately.

I can reproduce it, waiting some minutes, or only a fiew seconds. Once I
do an ifconfig on the master side, the backup side becomes master on all
carp's. Strange...?

My config:

MASTER Side:

# cat /etc/hostname.bge0
inet 10.25.0.2 255.255.255.240

# cat /etc/hostname.carp0
inet 10.25.0.1 255.255.255.240 10.25.0.15 vhid 1 pass foo carpdev bge0

# cat /etc/hostname.bge1
inet 10.25.0.18 255.255.255.240

# cat /etc/hostname.carp1
inet 10.25.0.17 255.255.255.240 10.25.0.31 vhid 2 pass foo carpdev bge1

# cat /etc/hostname.pfsync0
up syncif bge0

BACKUP Side:

# cat /etc/hostname.bge0
inet 10.25.0.3 255.255.255.240

# cat /etc/hostname.carp0
inet 10.25.0.1 255.255.255.240 10.25.0.15 vhid 1 advskew 100 pass foo
carpdev bge0

# cat /etc/hostname.bge1
inet 10.25.0.18 255.255.255.240

# cat /etc/hostname.carp1
inet 10.25.0.17 255.255.255.240 10.25.0.31 vhid 2 advskew 100 pass foo
carpdev bge1

preemtion is enabled on both machines using

sysctl -w net.inet.carp.preempt=1

and in /etc/sysctl.conf

Can anybody reproduce it, and has a solution for this problem?
Any help would be very nice! :-)

Thanks

Ralf