From ad2d021fcca1344e14d6e97c1ad6b0f55ebbfab6 Mon Sep 17 00:00:00 2001 From: Markus Hilger Date: Wed, 5 Aug 2026 03:23:27 +0200 Subject: [PATCH] Restore proxyDHCP log throttling The per-MAC 90 second log throttle in proxydhcp has been inert: the `skiplogging = True` reset sat in relay_proxydhcp, where it is a dead local, while the loop in proxydhcp only ever assigns False. Once the first packet is handled the flag stays False for the life of the process, so every retransmitted boot request logs again even though ignoredisco is updated to suppress it. Reset the flag at the top of each loop iteration instead, next to the timestamp check it belongs to, and drop the dead assignment. --- confluent_server/confluent/discovery/protocols/pxe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/confluent_server/confluent/discovery/protocols/pxe.py b/confluent_server/confluent/discovery/protocols/pxe.py index c09829e6..ed962c02 100644 --- a/confluent_server/confluent/discovery/protocols/pxe.py +++ b/confluent_server/confluent/discovery/protocols/pxe.py @@ -279,7 +279,6 @@ def relay_proxydhcp(sock, pktq): elif disco.get('uuid', None) in uuidmap: node = uuidmap[disco['uuid']] myipn = myipbypeer.get(data[28:28+hwlen], None) - skiplogging = True pktq.put_nowait((disco, peer, myipn, idx, recv, node, opts, data)) @@ -296,6 +295,7 @@ async def proxydhcp(handler, nodeguess): try: disco, client, myipn, idx, recv, node, opts, data = await pktq.get() netaddr = disco['hwaddr'] + skiplogging = True if time.time() > ignoredisco.get(netaddr, 0) + 90: skiplogging = False ignoredisco[netaddr] = time.time()