OPNsense
  • Home
  • Help
  • Search
  • Login
  • Register

  • OPNsense Forum »
  • English Forums »
  • High availability »
  • CARP DHCP Cluster - Failover Split Ignored
« previous next »
  • Print
Pages: [1]

Author Topic: CARP DHCP Cluster - Failover Split Ignored  (Read 2172 times)

ky41083

  • Newbie
  • *
  • Posts: 45
  • Karma: 3
    • View Profile
CARP DHCP Cluster - Failover Split Ignored
« on: December 30, 2023, 10:09:27 pm »
I have a 2 node DHCP CARP cluster setup. I only want the primary handing out leases (whichever happens to be primary at the time) so I've set the Failover split to 256. XMLRPC Sync has replicated the Failover split value of 256 to the secondary node (the text help states it will be ignored on the secondary so this should be fine, but the text help also says to leave the value blank on the secondary which XMLRPC Sync does not do.)

However, it seems both the primary and backup are still handing out DHCP leases. I tried fixing this by setting the response delay on the backup, but that value gets wiped out as soon as the config gets synced from the primary so that won't work.

Any idea how I can get only the primary to hand out DHCP leases via the Failover split value?
« Last Edit: February 18, 2024, 12:35:03 am by ky41083 »
Logged

JannF

  • Newbie
  • *
  • Posts: 1
  • Karma: 0
    • View Profile
Re: CARP DHCP Cluster - Failover Split Ignored
« Reply #1 on: February 08, 2024, 10:24:25 am »
+1 have the exact same issue.
Logged

Phoenix4

  • Newbie
  • *
  • Posts: 2
  • Karma: 0
    • View Profile
Re: CARP DHCP Cluster - Failover Split Ignored
« Reply #2 on: May 20, 2024, 02:02:41 pm »
Same problem here :(

I can also see in the logs the balancing being done as if the seeting was 128:

2024-05-20T21:42:49   Informational   dhcpd   balanced pool 8256ae180 192.168.0.0/24 total 64 free 28 backup 28 lts 0 max-misbal 8   
2024-05-20T21:42:49   Informational   dhcpd   balancing pool 8256ae180 192.168.0.0/24 total 64 free 34 backup 22 lts 6 max-own (+/-)6   
Logged

blacknote

  • Newbie
  • *
  • Posts: 6
  • Karma: 0
    • View Profile
Re: CARP DHCP Cluster - Failover Split Ignored
« Reply #3 on: November 14, 2024, 03:06:47 pm »
Hie all,

Have you any idea regarding the split failover in ISC DHCP - while the param is synchronised and might should not be?
Could it be possible to exclude it from sync?

Regards,
James.

Could it be possible and not overrided by any code if modifying

like: if (isset($dhcpifconf['failover_peerip']) && $dhcpifconf['failover_peerip'] != '') {
if (isset($dhcpifconf['failover_split']) && $dhcpifconf['failover_split'] != '') {

> dont know the exact variable / just an exemple / but it would probably be overrided.

/usr/local/etc/rc.filter_synchronize

 // dhcpd, unchanged from legacy code (may need some inspection later)
    if (is_array($transport_data['dhcpd'])) {
        foreach($transport_data['dhcpd'] as $dhcpif => $dhcpifconf) {
            if (isset($dhcpifconf['failover_peerip']) && $dhcpifconf['failover_peerip'] != '') {
                $int = guess_interface_from_ip($dhcpifconf['failover_peerip']);
                $transport_data['dhcpd'][$dhcpif]['failover_peerip'] = get_interface_ip($int);



« Last Edit: November 14, 2024, 03:17:40 pm by blacknote »
Logged

  • Print
Pages: [1]
« previous next »
  • OPNsense Forum »
  • English Forums »
  • High availability »
  • CARP DHCP Cluster - Failover Split Ignored
 

OPNsense is an OSS project © Deciso B.V. 2015 - 2024 All rights reserved
  • SMF 2.0.19 | SMF © 2021, Simple Machines
    Privacy Policy
    | XHTML | RSS | WAP2