Project

General

Profile

Actions

Bug #3716

closed

Adding IPv6 alias to IPv6 CARP IP throws error - fix proposal attached

Added by Marc Posch about 8 years ago. Updated over 6 years ago.

Status:
Resolved
Priority:
Normal
Category:
Virtual IP Addresses
Target version:
Start date:
06/22/2014
Due date:
% Done:

100%

Estimated time:
Plus Target Version:
Release Notes:
Affected Version:
All
Affected Architecture:

Description

Hi,

Adding an IPv6 alias to an IPv6 CARP IP throws the following error:
"...Could not find a matching real interface subnet for the virtual IP..."

In my case, I tried adding the IP alias 2001:xxxx:xxxx:128::1 to the already created CARP IP fdfd:3f23:25b0:128::1.
The cluster node interfaces were already configured as follows:

Node 1:
main IPv6: fdfd:3f23:25b0:128::101
IPv6 alias: 2001:xxxx:xxxx:128::101

Node 2:
main IPv6: fdfd:3f23:25b0:128::102
IPv6 alias: 2001:xxxx:xxxx:128::102

I debugged the code so far until I reached the function convert_real_interface_to_friendly_interface_name in interfaces.inc, which was returning an error message instead of an empty string for each interface not configured with an IPv6 address. This was interpreted by the calling code as "true", so the wrong underlying interface was returned, which - as the error message correctly stated - did not have a matching subnet address.

I fixed it by adding an additional line to check, if the underlying interface has valid IPv6 address => worked for me!
I also added this additional check for IPv4 some lines above so anybody who might want to configure a cluster which has some IPv6-only interfaces would not run into the same problem just the other way around.

I would be happy if my fix proposal is helpful and would be included in some way in the next update release.

My version is 2.1.3-RELEASE (i386).

Regards,
Marc


Files

interfaces.inc.patch (909 Bytes) interfaces.inc.patch Marc Posch, 06/22/2014 04:36 PM
Actions

Also available in: Atom PDF