What's new
  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Entware Pi-hole directly on the router? Yes!

There is an argument that you may want to offload anything possible from the router as that is the critical piece to any environment and you want it to be as stable and reliable as possible. :) Just because you *can* run things on your router, doesn't mean you have to. It may also depend on your router model. I would imagine this works better on some models than it does on others.
Right. I have a Proxmox box sitting switched off where I thought I'd have more use, such as a Home Assistant. But not yet. So don't want to keep it running just for PiHole.

Say the extra device wants 10 watts of power. That is 88 kWh per year, which at my rates is slightly above $10. I already have the router burning energy, so might as well have it do the double shift!

My main thing was to observe how PiHole on the router would impact the performance. It does not. So there is absolutely no reason to run it not on the router itself.
 
Ok so slight issue. Internet has been going down every few days just randomly, my modem is still synced so it's definitely the router. It was happening on my AX88U so I kind of used it as an excuse to upgrade to the BE88U but seems it's still happening. I reboot the router and it usually comes back up but if it doesn't and I stop and start the pihole service again it comes good. When it's not working the pihole graph with queries and activity only shows one bar on the very right of the graph. As soon as I restart the service it all fills in properly as it should so I think that might point to it being an issue with pihole and how I've set it up? I've got a syslog if you can take a look for me and see if you can see anything? No idea what I'm looking for

 
might as well have it do the double shift!

It's a common practice in some countries.

1765443253278.png
 
There is a WAN disconnect at Dec 9 16:49:55 in the log, I dunno why would it break pi-hole. Maybe newer firmware does something I am not aware of.
Perhaps there would be more insight in Pi-hole logs
 
There is a WAN disconnect at Dec 9 16:49:55 in the log, I dunno why would it break pi-hole. Maybe newer firmware does something I am not aware of.
Perhaps there would be more insight in Pi-hole logs
Hmmmm.... so perhaps the modem is going down and then causing an issue down the line when it comes back up? No other reason for the WAN to disconnect is there?

What log files would you like me to collect next time it happens and what's the best way to grab them?
 
What log files would you like me to collect next time it happens and what's the best way to grab them?

That's all that comes to my mind:
Code:
pihole debug
# upload when asked

netstat -tulnp | pihole tricorder

cat /etc/dnsmasq.conf | pihole tricorder

You could probably use wan-event script to just reload Pi-hole when reconnect happens if we can't get this fixed any other way
 
Last edited:
That's all that comes to my mind:
Code:
pihole debug
# upload when asked

netstat -tulnp | pihole tricorder

cat /etc/dnsmasq.conf | pihole tricorder

Awesome, cheers mate. I'll maybe get onto my ISP too and see if they can see something on their end

The wan-event script sounds interesting too but hopefully don't have to go down that route!
 
Last edited:
Anyway, I am not seeing the need to burn a few watts of electricity on a stand alone piece of hardware just to run PiHole.
Performance and security are two reasons I can see why I much prefer to run Pihole on my Proxmox host than on my server itself.
 
Performance and security are two reasons I can see why I much prefer to run Pihole on my Proxmox host than on my server itself.
And I run Pihole (along with unbound) on a dedicated Raspberry Pi for the same reasons.
 
Last edited:
Depending on the Raspberry Pi vintage, I think the Asus router hardware is likely to be faster.

Proxmox is of course different!
Dedicated Raspberry Pi 5 with 2.4 Ghz 64-bit quad-core CPU (8GB RAM) should be plenty sufficient
 
And I run Pihole (along with unbound) on a dedicated Raspberry Pi for the same reasons.
I do the same. Two Pi's running Pi-Hole and Unbound (and Jacklul's pihole-updatelists script). I prefer to leave the router to do router things. Pi-Hole+Unbound is running fine even on a cheap Pi Zero WH (WiFi) which I've had running many years and is extremely hardware limited (1 GHZ Broadcom BCM2835 - single-core ARM1176JZF-S processor, 512MB of RAM). To each their own. If you want to run it on the router, knock your self out. If you want to run it on some other separate device, knock your self out. Use what your comfortable with, and which works best for you and your use case.
 
Last edited:
I used to host Pi-hole on Pi Zero powered by router's USB port using Ethernet adapter.
Over the years my setup switched from using adapter to just using USB Ethernet gadget mode to directly connect to the router without any extra accessory.
Then Pi-hole dropped lighttpd dependency and made packaging it doable and this is how this project was born.
I don't have many devices in my network so I'm not too bothered by potential performance impact, other than memory requirements there is barely any CPU usage in my current setup caused by Pi-hole.
AX58U isn't a beast of a router but the CPU speed compared to Pi Zero is significantly better - gravity update takes up to 3 minutes on the router (I also limit it to core 1 and 2, keeping 0 and 4 free) while with Pi Zero sometimes it took even half an hour.
The setup will always depend on the user and priorities.
 
Last edited:
I used to host Pi-hole on Pi Zero powered by router's USB port using Ethernet adapter.
Over the years my setup switched from using adapter to just using USB Ethernet gadget mode to directly connect to the router without any extra accessory.
Did the same, USB Ethernet Gadget mode with the Pi Zero W for a number of years on a RT-AC68U back in 2019. Worked well once it was properly configured. Did a write up about it even at the time 😆:
 
Then Pi-hole dropped lighttpd dependency and made packaging it doable and this is how this project was born.
I don't have many devices in my network so I'm not too bothered by potential performance impact, other than memory requirements there is barely any CPU usage in my current setup caused by Pi-hole.
AX58U isn't a beast of a router but the CPU speed compared to Pi Zero is significantly better - gravity update takes up to 3 minutes on the router (I also limit it to core 1 and 2, keeping 0 and 4 free) while with Pi Zero sometimes it took even half an hour.
...

I was able to replace Diversion with PiHole, so both of these are router entities. Thanks again for pushing this project forward!

And, there is no performance impact on the router. So it's literally a free PiHole instance, no extra devices and no new electricity consumption.

If I had a Proxmox box running - I'd probably do a PiHole instance there.

I used RPi 2 for a few things (bios chip clipping mainly). Boy, was it slow ... I cannot imagine it would perform well on a local network as a PiHole device.
 
I used RPi 2 for a few things (bios chip clipping mainly). Boy, was it slow ... I cannot imagine it would perform well on a local network as a PiHole device.
Pi-Hole has very low system requirements and is generally very lightweight. Where having a fast processor and more RAM may benefit is updating Pi-Hole's Gravity database or generally updating the Pi-Hole program itself. But otherwise in general, Pi-Hole operation is light weight and doesn't (or shouldn't) consume significant system resources. As with any DNS sinkhole program, if you have an extremely large block list that may impact the program's performance. Or enabling certain DNS Sinkhole features may impact performance. Or possibly having a large number of active LAN clients making DNS requests may impact performance. People have been running Pi-Hole on limited hardware devices, like the Raspberry Pi Zero, for years without issue.

On a headless Pi-Zero W, Pi-Hole doesn't consume that much resources in my use case:
PiZeroW Pi-Hole System Information.jpg


As a comparison, Pi-Hole on a headless Pi 3B+:
Pi3BPlus Pi-Hole System Information.jpg
 
Last edited:
For years I've run Pi-hole on several various Pogoplug's; the E02, the Pro, a V4, and a Mobile. Recently they are becoming obsolete as support for old ARM versions are sunsetted, though you can still compile to keep them going. I don't think I paid more than $20 for any of them and they had more than enough power to run Pi-hole and Apple backups for the household.
 
Pi-Hole has very low system requirements and is generally very lightweight. Where having a fast processor and more RAM may benefit is updating Pi-Hole's Gravity database or generally updating the Pi-Hole program itself. But otherwise in general, Pi-Hole operation is light weight and doesn't (or shouldn't) consume significant system resources.
For years I've run Pi-hole on several various Pogoplug's; the E02, the Pro, a V4, and a Mobile. Recently they are becoming obsolete as support for old ARM versions are sunsetted, though you can still compile to keep them going. I don't think I paid more than $20 for any of them and they had more than enough power to run Pi-hole and Apple backups for the household.
This is a fantastic discussion here, and a lot of robust debate!

I think the arguments for running PiHole on separate devices actually directly confirm that the resource usage is negligible. And if this is the case - then one might as well run PiHole on the router itself! One can probably tweak the database update time to be at night - so then there is no observable impact on the user. It looks like my database is already updating on Sunday at 4:23am, so that's early enough for me!

The legacy PiHole crowd may find the idea of router based PiHole somewhat uncomfortable given the historical approach, but for newcomers like me it just seems like such a great setup.
 
Last edited:

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Back
Top