DHCP frantic requests with wrong expires-after value

SERVER SIDE

doas grep lease /etc/dhcpd.conf
default-lease-time 3600;
max-lease-time 3600;

LOG

Repeated every 15 seconds:

May 24 19:58:34 dhcpd[91838]: DHCPREQUEST for 192.168.1.31 from 48:a9:8a:9c:1d:4b via vether0
May 24 19:58:34 dhcpd[91838]: DHCPACK on 192.168.1.31 to 48:a9:8a:9c:1d:4b via vether0
May 24 19:58:34 dhcpd[91838]: DHCPDISCOVER from 48:a9:8a:9c:1d:4b via vether0
May 24 19:58:34 dhcpd[91838]: DHCPOFFER on 192.168.1.31 to 48:a9:8a:9c:1d:4b via vether0
May 24 19:58:34 dhcpd[91838]: DHCPDISCOVER from 48:a9:8a:9c:1d:4b via vether0
May 24 19:58:34 dhcpd[91838]: DHCPOFFER on 192.168.1.31 to 48:a9:8a:9c:1d:4b via vether0
May 24 19:58:34 dhcpd[91838]: DHCPREQUEST for 192.168.1.31 from 48:a9:8a:9c:1d:4b via vether0
May 24 19:58:34 dhcpd[91838]: DHCPACK on 192.168.1.31 to 48:a9:8a:9c:1d:4b via vether0

MIKROTIK SIDE

> /ip/dhcp-client/print
Columns: INTERFACE, USE-PEER-DNS, ADD-DEFAULT-ROUTE, STATUS, ADDRESS
# INTERFACE    USE-PEER-DNS  ADD-DEFAULT-ROUTE  STATUS  ADDRESS
;;; defconf
0 bridgeLocal  yes           yes                error   192.168.1.31/24

> /ip/dhcp-client/print detail
Flags: X - disabled, I - invalid, D - dynamic
0   ;;; defconf
interface=bridgeLocal add-default-route=yes default-route-distance=1 use-peer-dns=yes use-peer-ntp=no dhcp-options=hostname,clientid status=error address=192.168.1.31/24 gateway=192.168.1.1 dhcp-server=192.168.1.3 primary-dns=192.168.1.3 secondary-dns=192.168.1.1 expires-after=2d21h33m18s

What I see

  • the DHCP server sets a lease time of 3600 seconds;
  • the MIKROTIK DHCP client status reports an unspecified error;
  • the MIKROTIK DHCP client says it received a lease time of neary 3 days;
  • the MIKROTIK client hits the DHCP server every 15 seconds.

Reference

/system/routerboard/print
routerboard: yes
board-name: hAP ax^2
model: C52iG-5HaxD2HaxD
serial-number: HEB08ZETYA3
firmware-type: ipq6000
factory-firmware: 7.6
current-firmware: 7.15
upgrade-firmware: 7.15

The DHCP server is OpenBSD, and its lease time has been verified using various tools: dhcpdump, dhcpcd, nmap and nagios.

This device is managed by CAPsMAN. Other DHCP-enabled non-CAP MT devices do not behave like this.

Edited to show latest values.
export.rsc (2.83 KB)

Did you change the max lease time between the MikroTik asking for the lease and now that you see this problem?

NO

https://download.mikrotik.com/routeros/7.15/CHANGELOG

*) defconf - do not override default DHCP server lease time;

I see…

Currently in the process of upgrading and testing. Will report back.

Updated.


> ssh 192.168.1.31 '/system/routerboard/print'
routerboard: yes
board-name: hAP ax^2
model: C52iG-5HaxD2HaxD
serial-number: HEB08ZETYA3
firmware-type: ipq6000
factory-firmware: 7.6
current-firmware: 7.15
upgrade-firmware: 7.15

Query:


ssh 192.168.1.31 ‘/ip/dhcp-client/print detail’
Flags: X - disabled, I - invalid, D - dynamic
0 ;;; defconf
interface=bridgeLocal add-default-route=yes default-route-distance=1
use-peer-dns=yes use-peer-ntp=no dhcp-options=hostname,clientid
status=error address=192.168.1.31/24 gateway=192.168.1.1
dhcp-server=192.168.1.3 primary-dns=192.168.1.3
secondary-dns=192.168.1.1 expires-after=7m58s

I see the expires-after is nearing completion.
I am waiting for the expiration date to see what happens.
I also see “status=error”, also present in the previous report.

The “expires-after” parameter … keeps increasing???


ssh 192.168.1.31 ‘/ip/dhcp-client/print detail’
Flags: X - disabled, I - invalid, D - dynamic
0 ;;; defconf
interface=bridgeLocal add-default-route=yes default-route-distance=1
use-peer-dns=yes use-peer-ntp=no dhcp-options=hostname,clientid
status=error address=192.168.1.31/24 gateway=192.168.1.1
dhcp-server=192.168.1.3 primary-dns=192.168.1.3
secondary-dns=192.168.1.1 expires-after=14m13s

ssh 192.168.1.31 ‘/ip/dhcp-client/print detail’
Flags: X - disabled, I - invalid, D - dynamic
0 ;;; defconf
interface=bridgeLocal add-default-route=yes default-route-distance=1
use-peer-dns=yes use-peer-ntp=no dhcp-options=hostname,clientid
status=error address=192.168.1.31/24 gateway=192.168.1.1
dhcp-server=192.168.1.3 primary-dns=192.168.1.3
secondary-dns=192.168.1.1 expires-after=20m36s

This is a bug. Please correct the programming error.

Have you checked out the new v7.15 that dropped today? If you’re still having trouble and since this is just a user forum, I suggest sending in a bug report to ‘support@mikrotik.com’.

Yes, I updated.

Bug report sent, although it seems they are reading this.

This device is managed by CAPsMAN.

Other devices with DHCP enabled do not behave like this.