Ignore certain clients

Hello everybody,

is there a way to get the pi-hole to ignore certain clients?

I have a SmartTV that is not used as such. It is completely blocked in the FritzBox and cannot access the Internet. He's on the network so that I can send content from the mobile phone display to the TV. But now the blocked television trashes the pi-hole with 1800 DNS requests in 10 minutes. The DHCP in the pi-hole should work with the television but DNS requests from the television should not unnecessarily burden the pi-hole.

I tried group management, but I can block everything at most. I would like the PI-get to play dead opposite the television and that the television no longer appears in the statistics.

Can you do something about that?

thank you for your help

Kind regards Steffen

You will want to assign a different DNS server to this client. I assume there is no configuration option on the TV to assign a DNS server.

Since you are using Pi-hole for DHCP, you can use a dnsmasq configuration to do this:

if I've seen that correctly, the post is from March 2019 and I read that it no longer works like that. Is that correct? is there an updated manual for DNSMASQ? I can not find anything.

Thank you for your help

Greetings Stefenzo

Where did you read that? Dnsmasq has not changed, and this is using dnsmasq to assign an alternate DNS to a client.

http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html

ok, I guess I misunderstood something. I find it a little difficult with the English text. I'll try to understand that again.

Thank you for your answer

Ok, last question about safety. I create the file "/etc/dnsmasq.d/04-bypass.conf" with the following content. And my TV will shut up in the future because it asks itself for DNS entries?

## The contents here bypass pihole by mac address

## This will go straight to localhost.
dhcp-option=tag:local,6,127.0.0.1
dhcp-host=F8:77:B8:D9:65:65,set:local

Thank you for your help

Greetings Stefenzo

If you don't want the TV to have internet access (which is what you are doing by removing its DNS server), why not just disconnect it from the network?

He's on the network so that I can send content from the mobile phone display to the TV.

Ok, that doesn't work.

## The contents here bypass pihole by mac address

## This will go straight to localhost.
dhcp-option=tag:local,6,127.0.0.1
dhcp-host=F8:77:B8:D9:65:65,set:local
dhcp-host=DC:A6:32:D9:6E:D7,set:local

tested with the MAC address of my computer

does anyone have an idea what can still be wrong?

the beginning of the file is already occupied by a file named "04-pihole-static-dhcp.conf"

is that important? does it have to start with something other than 04?

Thank you for your help

Greetings Stefenzo

What is the complete output of this command (will show us all the content in /etc/dnsmasq.d):

sudo grep -v '#\|^$' -R /etc/dnsmasq.*

OK, bug found. it must be "05-bypass.conf". so that it is executed after "04-pihole-static-dhcp.conf". It works now. Presumably the command for the static IP overwrites the DNS assignment. "03-bypass.conf" don't works.

thanks for all.

Greetings Stefenzo

here is an addition.

With my change, I have achieved that the DNS server is assigned correctly. Instead, the static IP was gone for these devices. The same instruction is used in "04-pihole-static-dhcp.conf" and in "05-bypass.conf". (dhcp-host =)

once

"dhcp-host=MA:CA:DR:ES:SE,192.178.176.100,Device"

and for the assignment of the DNS server

"dhcp-host =MA:CA:DR:ES:SE,set:local"

depending on what is processed first, the MAC address has either a static IP or a different DNS server. it must be correct in "05-bypass.conf".

"dhcp-host=MA:CA:DR:ES:SE,192.178.176.100,Device,set:local"

important! Under no circumstances should the same IP appear in two lines. I thought I could just leave the old entries in "04-pihole-static-dhcp.conf". The result is that the DHCP server no longer starts.

It would be interesting whether "dhcp-option=tag:local,6,127.0.0.1" and "set:local" could have simply been entered in "04-pihole-static-dhcp.conf"? Will the system overwrite this again? Perhaps one of the experts will know.

Greetings Steffen

If the file has this warning at the top, it will be subject to overwrite:

###############################################################################
#      FILE AUTOMATICALLY POPULATED BY PI-HOLE INSTALL/UPDATE PROCEDURE.      #
# ANY CHANGES MADE TO THIS FILE AFTER INSTALL WILL BE LOST ON THE NEXT UPDATE #
#                                                                             #
#        IF YOU WISH TO CHANGE THE UPSTREAM SERVERS, CHANGE THEM IN:          #
#                      /etc/pihole/setupVars.conf                             #
#                                                                             #
#        ANY OTHER CHANGES SHOULD BE MADE IN A SEPARATE CONFIG FILE           #
#                    WITHIN /etc/dnsmasq.d/yourname.conf                      #
###############################################################################
1 Like

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