Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New IPv6 clients are not resolved until another new client is added #2292

Open
ranger81 opened this issue Feb 26, 2025 · 0 comments
Open

New IPv6 clients are not resolved until another new client is added #2292

ranger81 opened this issue Feb 26, 2025 · 0 comments

Comments

@ranger81
Copy link

Hi,

I upgraded my Pi-Hole installation from 5.25.2 to the 6.0.2 release and I noticed a new behavior in how new IPv6 clients are resolved to their hostnames with PTR queries.

I saw below change in the code base between 5.x and 6.x. It adds a delay in resolving new IPv6 clients.

FTL/src/resolve.c

Lines 946 to 958 in ac500d5

// If onlynew flag is set, we will only resolve new clients.
// However, if this is a IPv6 client, we postpone the resolution
// slightly to ensure the network table has had time to possibly
// correlate the IPv6 address via a related other address (e.g.,
// IPv4 address) though an identical MAC address.
if(onlynew && newflag && IPv6 && client->firstSeen + DELAY_V6_RESOLUTION > now)
{
log_debug(DEBUG_RESOLVER, "Postponing resolution of new client %s (IPv6) for at least %.0f more seconds",
getstr(ippos), now - client->firstSeen + DELAY_V6_RESOLUTION);
skipped++;
continue;
}

The caveat is, that, as long as resolver.refreshNames is not set to ALL, that client hostname is never going to be resolved, except, if there is another new client (after the delay time). In that case, the previous client hostname is resolved.

Is this the expected behavior? I would have expected, that at least after the delay, that new IPv6 client should be resolved even though resolver.refreshNames is set to the default value of IPV4_ONLY. What is the wanted behavior here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant