On 4/19/2025 5:39 PM, Chuck Zmudzinski via Kea-users wrote: > Hi Darren, > > I found the reason for the problem, but still have a question. Your > advice to look at the logs identified the problem. > > According to the logs, the problem is that the Xen system is > configuring each vifn.0 interface on which kea-dhcp4 is listening > to have the same IPv4 address, and this is something that kea rejects. > > Here is the warning I get from the logger: > > Apr 19 16:25:05 almalinux kea-dhcp4[5650]: WARN > [kea-dhcp4.dhcpsrv.139918558259328] DHCPSRV_OPEN_SOCKET_FAIL failed to open > socket: Failed to open socket on interface vif6.0, reason: failed to bind > fallback socket to address 192.168.1.105, port 67, reason: Address already in > use - is another DHCP server running?
I see this warning is coming from PktFilter::openFallbackSocket, and the fallback socket fails to bind because the address is already in use. Is this the same thing that is described in the note at section 8.2.4 of the documentation for the dhcp4 server quoted below? > Specifying the value raw as the socket type does not guarantee that raw > sockets will be used! The use of raw sockets to handle traffic from the > directly connected clients is currently supported on Linux and BSD systems > only. If raw sockets are not supported on the particular OS in use, the > server issues a warning and fall back to using IP/UDP sockets. It looks like the failure in my case is due to a failure to bind the fallback IP/UDP socket. But in my case, I don't think I need the UDP fallback socket because all the clients are directly connected. Would it be possible to add a dhcp-socket-type option such as "raw-no-fallback" to the dhcp4 server to allow the server to listen on an interface using the raw socket in cases like mine when the the call to bind the fallback UDP socket fails? That might help in my situation since, as I mentioned in a previous message in this thread, I have to waste N-1 IPv4 addresses on the Xen virtualization server to serve N guests with IPv4 configurations using the kea dhcp4 server, which is IMHO a nasty regression compared to the old ISC dhcp4 server, with which I could get away with using only a single IPv4 address on the Xen virtualization sever for all N vifn.0 interfaces, the same address the Xen virtualization server obtains from the SOHO router. Would the kea project consider such a new dhcp-socket-type option as proposed above? I am willing to do some experiments to test such an option in my system to see if it solves this regression compared to the old ISC dhcp4 server. Thanks, Chuck Zmudzinski -- ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. To unsubscribe visit https://lists.isc.org/mailman/listinfo/kea-users. Kea-users mailing list Kea-users@lists.isc.org https://lists.isc.org/mailman/listinfo/kea-users