Home
Help
Search
Login
Register
OPNsense Forum
»
Archive
»
23.7 Legacy Series
»
DHCP lease expiring and no longer resolving
« previous
next »
Print
Pages: [
1
]
Author
Topic: DHCP lease expiring and no longer resolving (Read 1374 times)
securid
Jr. Member
Posts: 71
Karma: 1
DHCP lease expiring and no longer resolving
«
on:
December 23, 2023, 09:05:33 am »
This is a new issue for me I have not seen before. I searched but I only seem to find issues about other issues concerning leases.
So what is happening is that I install a few new Rocky Linux systems (automated on ESX). They boot up with a kernel option "ip=dhcp". This required because during boot, it needs to pick up a kickstart file for silent install from an https-address.
The servers install, and reboot. They all get their lease and register their hostnames. But after short time (like, within an hour or so), some of the leases expire and their hostnames become unresolvable because they are also removed from Unbound (register dhcp clients). What I see in DHCP leases list is that the IP is still there and showing online, but expired. The host is reachable on IP and everything else seems to work fine (no connection issues).
The installations are mostly defaults, I only change the hostname, partitioning and I create a user with ssh key via the silent install script. I make no changes to network settings, I only tell it to use DHCP.
In debug logging in the dhcp server, I only see the requests and replies. I see reuse unaltered entries, but nothing about expiring or removing leases.
I also searched Unbound logging but that logs so much I might have missed something. I didn't find information about registrations being removed due to expired leases or something.
I tried increasing and changing some lease times like minimal and max, but the leases seem to expire anyway.
Basically I'm at a loss and I'm unsure what else to check? If anyone has an idea I would appreciate it!
Thanks!
Logged
knebb
Full Member
Posts: 126
Karma: 4
Re: DHCP lease expiring and no longer resolving
«
Reply #1 on:
December 23, 2023, 10:28:33 am »
Hi,
you might use
DHCPdump
to troubleshoot?
What are your dhcp-clients saying? Do they still have a valif IP or not? If yes, it might be an issue with unbound/dhcp, indeed. But if not there must be a reason why the abadonned their IP.
Check the lease time with dhcpdump and/or check if there are duplicate MAC or IP addresses somewhere. Make sure there is no static IP configured from within the pool.
/KNEBB
Logged
securid
Jr. Member
Posts: 71
Karma: 1
Re: DHCP lease expiring and no longer resolving
«
Reply #2 on:
December 23, 2023, 04:20:39 pm »
Thanks. Yes they do keep a valid IP. In their own logging its just the usual dhcpcd logging.
I can try the tool, but I am wondering. After deployment the guests are turned off. I turn them back on to start configuration and at that point some of them already do not resolve so there is no way for me to even start the dhcpdump tool.
After config (if they do resolve), I can install the tool and start it in a terminal. However, at that point I need to leave it open for I-dont-know-how-long. It seems intermittend I cannot predict which ones are going to have an issue.
Since I am already automating things I might just make a dhcp reservation via API. I feel that is less work than troubleshooting the guests.
Logged
securid
Jr. Member
Posts: 71
Karma: 1
Re: DHCP lease expiring and no longer resolving
«
Reply #3 on:
December 23, 2023, 08:50:06 pm »
I'm not very lucky with this project ...
https://github.com/ansibleguy/collection_opnsense/issues/41
Logged
Print
Pages: [
1
]
« previous
next »
OPNsense Forum
»
Archive
»
23.7 Legacy Series
»
DHCP lease expiring and no longer resolving