Some client hostnames are not being resolved

Expected Behaviour:

Client hostname resolved and noted in GUi and data

Actual Behaviour:

Some clients hostnames are resolved, others are shown as UNKNOWN in the GUI
One or 2 actually have nothing at all, as in juist empty in both netwrok table and stats
One or 2 ddevices show onlyt the local IP

Additional Info

pi@pihole:~ $ pihole -v && pihole status
  Pi-hole version is v5.2.4 (Latest: v5.2.4)
  AdminLTE version is v5.4 (Latest: v5.4)
  FTL version is v5.7 (Latest: v5.7)
  [✓] DNS service is listening
     [✓] UDP (IPv4)
     [✓] TCP (IPv4)
     [✓] UDP (IPv6)
     [✓] TCP (IPv6)

  [✓] Pi-hole blocking is enabled

This is a clean install in the last few weeks, previously hostnames were all resolved properly
IPV6 is disabled in pihole admin gui, aswell as in my ISP provided router
Unbound is running and working on the same Pi
Pihole is handling DHCP
No static leases are set
In pihole settings > DNS Never forward non-FQDNs and Never forward reverse lookups for private IP ranges are both checked (by default i think?)

Debug Token:

https://tricorder.pi-hole.net/yrkd4ibjfq

Who or what knows the name and IP mappings?

Edit: And a screenshot of where you are seeing these issues would be very helpful, or at least an idea of what page you are looking at when you see the missing information.

Thanks for taking a look

Sorry, but I'm not sure what you mean?

I see the missing info onnthe GUI dashboard innthe stats and in the network table:



What server should know the hostname for 192.168.0.179 or 192.168.0.178 (or the other unknowns). I'm asking to find out where Pi-hole should be asking to find out the name to display.

Sorry, I'm lost now.
In terms of servers in my lan, I have only 2.
Pihole and Hassio
I also have a second AP (ISP provided, more of a booster)
My query is more why some clients have their hostname resolved whereas others don't?

Because Pi-hole knows the names of some of the clients and doesn't know the names of the ones it doesn't. Or the names actually are UNKNOWN.

Pi-hole doesn't know anything on it's own. You have to tell Pi-hole how to find names. You can:

  1. Add local hostnames to /etc/hosts or another file and tell Pi-hole to use that file for names.
  2. Set up Conditional Forwarding and tell Pi-hole the address and domain of another DNS server that will know the names and IP address mapping.
  3. Use Pi-hole as the network DHCP server and use the names that clients report when they ask for a lease. Not all clients will send a name along with their request though.
  4. Add a local DNS entry to do the same thing as 1, but with the web interface.

It looks like you have set up Pi-hole as the DHCP server so one of a few things are happening.

  1. The clients are not sending a hostname with their lease requests.
  2. The clients are sending UNKNOWN as the client name.
  3. The hosts are not using Pi-hole as their DHCP server and Pi-hole has no information from them to guess a host name from.

You'll need to see which of those is happening. Check /etc/pihole/dhcp.leases and see if there is an active lease for the MAC addresses that are not showing the name you expect to see.

1 Like

Ah ok, makes sense I think.
I must have set static IP addresses in my previous install.
I stopped doing this as I was under the impression it is not good practice on devices that aren't a server.

This is tied to an IP though right? So should a device IP change, it may get the wrong name?

I guess I could forward to my router and see if that helps, although pihole is is the network DHCP server.

Is there any means to display the IP in the dashboard stats, rather than UNKNOWN, for ease of readability?

pi@pihole:~ $ cat /etc/pihole/dhcp.leases
1616871174 68:94:23:0f:96:5e 192.168.0.66 rich-laptop *
1616871111 70:af:24:97:cc:f0 192.168.0.164 * 01:70:af:24:97:cc:f0
1616873955 9c:64:8b:0a:2d:f8 192.168.0.232 Richards-iPhone 01:9c:64:8b:0a:2d:f8
1616848272 84:b8:b8:56:eb:46 192.168.0.206 * 01:84:b8:b8:56:eb:46
1616851291 bc:83:85:85:47:b1 192.168.0.208 XBOX-ONE 01:bc:83:85:85:47:b1
1616854161 ec:b5:fa:06:ef:dd 192.168.0.106 Philips-hue *
1616844847 dc:4f:22:8f:1f:77 192.168.0.210 sonoff_kitchen_cupboard_lights *
1616867630 5c:cf:7f:b4:de:4b 192.168.0.137 sonoff_bedside_lamp *
1616823423 9c:31:c3:6a:92:69 192.168.0.162 * 01:9c:31:c3:6a:92:69
1616859213 34:2f:bd:ee:62:a4 192.168.0.239 * *
1616871468 c8:db:26:0a:b1:b8 192.168.0.191 HarmonyHub 01:c8:db:26:0a:b1:b8
1616845094 e4:f0:42:00:04:aa 192.168.0.76 Google-Home-Mini *
1616845093 a4:77:33:1f:a2:4a 192.168.0.195 Google-Home *
1616878819 98:09:cf:6e:93:36 192.168.0.67 RichOnePlus7Pro 01:98:09:cf:6e:93:36
1616874144 b8:27:eb:a5:5c:dd 192.168.0.74 hassio 01:b8:27:eb:a5:5c:dd
1616854019 74:58:f3:b0:b6:d9 192.168.0.114 * *
1616860973 34:3e:a4:12:45:b0 192.168.0.197 RingDoorbell-b0 *
1616859485 dc:54:d7:e0:28:cc 192.168.0.178 * 01:dc:54:d7:e0:28:cc
1616859597 74:a7:ea:bc:4e:90 192.168.0.179 * 01:74:a7:ea:bc:4e:90
1616866522 b0:3e:51:a5:ac:d9 192.168.0.112 * *
1616859869 74:d8:3e:7d:d6:ab 192.168.0.55 P02047673 01:74:d8:3e:7d:d6:ab

OK, so i am still trying to figure this all out, and could really use some help.
I think it may be my understanding of DHCP etc. So if i need educating please do so!

There are a few things im confused about...
My network table shows IPV6 addresses, even though IPV6 is disabled on pihole and my router.
Is this normal?
Pihole setupVars.conf shows an IPV6 address, but i definetly only select IPV4 when making the clean install (based on past experience with IPV6 + Android)

pi@pihole:~ $ cat /etc/pihole/setupVars.conf
PIHOLE_INTERFACE=eth0
IPV4_ADDRESS=192.168.0.45/24
QUERY_LOGGING=true
INSTALL_WEB_SERVER=true
INSTALL_WEB_INTERFACE=true
LIGHTTPD_ENABLED=true
CACHE_SIZE=10000
BLOCKING_ENABLED=true
DHCP_ACTIVE=true
DHCP_START=192.168.0.51
DHCP_END=192.168.0.251
DHCP_ROUTER=192.168.0.1
DHCP_LEASETIME=24
PIHOLE_DOMAIN=lan
DHCP_IPv6=false
DHCP_rapid_commit=false
WEBPASSWORD=1fc4c65d6a31532602585e64ac80e06b9745c6721c67cc4f5fefb3a1d95b4a61
ADMIN_EMAIL=
WEBUIBOXEDLAYOUT=boxed
WEBTHEME=default-light
IPV6_ADDRESS=fe80::2b4c:1685:8a3c:e4b3
DNSMASQ_LISTENING=local
PIHOLE_DNS_1=127.0.0.1#5335
DNS_FQDN_REQUIRED=true
DNS_BOGUS_PRIV=false
DNSSEC=false
REV_SERVER=false

I also have a number of devices showing multiple IPs in the network table...A laptop i could expect, for example, if i cannot via Wifi and ethernet, but my ring video doorbell has 2 IPs?


One last cry for help here please.
I have noticed that things seem a lot slower, as in web page load times
And some deovces show as UNKNOWN in the dashboard, while a couple show the IP address.
Using conditional forwarding to my router did not help anything

Doing a bit nof digging, im concerned its something i may have changed...The unbound guide makes reference to unbound resolvconf
I went ahead and disabled this when i installed unbound without really knowing why (yes, a dumb thing to do)
So i fear there may be some conflict with name servers perhaps, as my dhcpcd/conf and resolv.conf files do not match:

# Example static IP configuration:
interface eth0
static ip_address=192.168.0.45/24
static routers=192.168.0.1
static domain_name_servers=192.168.0.1 8.8.8.8
pi@pihole:~ $ cat /etc/resolv.conf
# Generated by resolvconf
nameserver 127.0.0.1

Should these read the same?

And when i check the status of unbound-resolvconf there is an error, i think, as in the last line below

pi@pihole:~ $ sudo systemctl status unbound-resolvconf.service
● unbound-resolvconf.service - Unbound DNS server via resolvconf
   Loaded: loaded (/lib/systemd/system/unbound-resolvconf.service; enabled; vend
   Active: active (exited) since Thu 2021-04-08 10:44:28 BST; 5h 6min ago
  Process: 13297 ExecStart=/usr/lib/unbound/package-helper resolvconf_start (cod
 Main PID: 13297 (code=exited, status=0/SUCCESS)

Apr 08 10:44:28 pihole systemd[1]: Started Unbound DNS server via resolvconf.
Apr 08 10:44:29 pihole package-helper[13297]: Too few arguments. 

Using nslookup to check for hostnames, 192.168.0.1 is my router, and 192.168.0.45 is pi-hole

pi@pihole:~ $ nslookup pi.hole
Server:         127.0.0.1
Address:        127.0.0.1#53

Name:   pi.hole
Address: 192.168.0.45
Name:   pi.hole
Address: fe80::2b4c:1685:8a3c:e4b3

pi@pihole:~ $ nslookup pi.hole 192.168.0.1
Server:         192.168.0.1
Address:        192.168.0.1#53

** server can't find pi.hole: NXDOMAIN
pi@pihole:~ $ nslookup 192.168.0.206 192.168.0.1
206.0.168.192.in-addr.arpa      name = UNKNOWN.

Authoritative answers can be found from:

pi@pihole:~ $ nslookup 192.168.0.206 192.168.0.45
** server can't find 206.0.168.192.in-addr.arpa: NXDOMAIN

I'm really confused with the IPV6 address showing, as i do not have IPV6 enabled in my router, nor pi-hole, yet i see an IPV6 address in the pihole settings page?

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.