Live data from Hacker News

Ad blocking with Raspberry Pi and Pi-hole

cri.dev

11–20 of 163 posts

Re: Ad blocking with Raspberry Pi and Pi-hole

#11
I actually have been doing some work with MaraDNS to have the ability to have a pi-hole sized blacklist. The main source of pi-hole’s blacklist is this Git repo:

https://github.com/StevenBlack/hosts

That is about 60,000 hosts, so I added MaraDNS support to have up to 500,000 blacklisted names. Since it’s a speed-optimized (not size-optimized) cache, each element takes about a kilobyte of memory, so a blacklist this size takes about 60 megabytes of memory for MaraDNS to store (on a modern Core i7 7600U processor, it only takes about two seconds to load all 60,000 elements in to memory), but it’s very rapid to use.

The script to take that blacklist and convert it in to a MaraDNS compatible format is here:

https://github.com/samboy/MaraDNS/blob/master/deadwood-githu...

There are ways to make the memory footprint of the blacklist smaller, but this was a quick and simple way to implement a medium sized blacklist. Finding ways to have, say, 10 million blacklist elements with a small memory footprint is left as an exercise for the reader.

My current project is to make a proper Docker container for MaraDNS.

Re: Ad blocking with Raspberry Pi and Pi-hole

#12
post #4

> Use it for ad-blocking in your home network and to finally browse the web, watch videos etc. without annoying ads. It doesn't really do this as well as a browser adblocker, YouTube ads for example can't effectively be blocked with pihole

it's not really fair to compare it to an in-browser adblocker that way, especially since using them isn't mutually exclusive. PiHole blocks ads whether you are in a browser or not, an instant benefit for everybody on your WiFi network.

In fact, one of the best things about Pi-hole network wide blocking is the removal of those 5 to 10 second otherwise unskippable ads in apps.

Re: Ad blocking with Raspberry Pi and Pi-hole

#16
post #4

> Use it for ad-blocking in your home network and to finally browse the web, watch videos etc. without annoying ads. It doesn't really do this as well as a browser adblocker, YouTube ads for example can't effectively be blocked with pihole

there seems to be a solution: https://github.com/kboghdady/youTube_ads_4_pi-hole

Re: Ad blocking with Raspberry Pi and Pi-hole

#17

Does anyone have any good suggestions for blacklists? I've only been using the default and am wondering if I should add some more items to the list.

some blacklists i found:

- https://discourse.pi-hole.net/t/update-the-best-blocking-lis...

- https://github.com/chadmayfield/my-pihole-blocklists

Re: Ad blocking with Raspberry Pi and Pi-hole

#20
Is anyone successfully using PiHole with non-technical users?

My main concern with putting PiHole on my home network is that for example my mother in law might not understand that she can't get to some web page because it's being ad-blocked, nor would she be able to go to the web admin page and temporarily unblock it.

Even as a technical person sometimes it takes a while to figure out that a page isn't working because of adblock or pi-hole.

How do people deal with this?

Post reply on HN