Pihole through AT&T fiber's shitty router

I'm visiting my parents and I left a spare Zimaboard so I could set up a Pihole network and maybe some other interesting selfhosted applicatiions.

Pihole was a disaster. It took half an all nighter and more searching than I should've done. Extra points off because I wanted to deploy it using Docker so I could have it on the CasaOS dashboard. The disparity between my Docker Pihole setup in my own apartment and at my parents' place was night and day. The experience would have been 80% less work if I bothered installing it normally instead of dying on the Docker hill. But as you know by now, you don't let technology win. EVER.

The main culprit leading to 6 hours of struggle, 2 hours of internet downtime while family was still awake, 1 router reset, and endless malding lay in AT&T's piece of shit modem/router combo. Due to how fiber requires special handshaking and some other protocol stuff, the ISP-given router must be used. Sure, there are plenty of workarounds like using a second router and putting the AT&T BGW model in passthrough/bridge node, completing the handshaking and replacing the connection with a MAC spoofed router, and some other methods that are probably illegal, but the BGW will always have to be in the loop somehow.

To give some context, Pihole has 2 main ways of hooking into the network: DNS and DHCP. The DNS method is extremely easy and requires 0 effort. Go into your router, set static DNS to Pihole's IP. The other way is a little more complicated, and gives Pihole the responsibility of doling out IP addresses.

AT&T's router does not allow hijacks DNS so they can sell ads. That's why the router they give only has the option of enabling/disabling DHCP, but has no DNS option. My apartment's router is my own and easily changed DNS to Pihole Docker, so it was a breeze. Imagine expecting the same painless setup with AT&T 🤡

Here was the trouble, DHCP mode is notoriously difficult to set up on Pihole in Docker. In hindsight the issue was 50% my being stupid, 40% CasaOS app store's Pihole only supporting DNS mode, 10% not having necessary information as a result of using CasaOS's Pihole one-click install.

I try the easiest method outlined in Pihole documentation, removing all the ports in CasaOS's install script, change network mode to host, and expect things to work. Not so. I accidentally bring down the whole network. Thankfully most of my bumbling didn't lock me out of the router, so all I had to do was turn DHCP back on in the router and internet would be up again. However, my family was still using the internet so it was quite irritating for them. I decide to nap until 1am and then keep working, when everyone should be asleep and most definitely not playing on their phones. If they were, then that's on them.

There were a number of interesting posts on /r/Pihole dedicated to getting Pihole Docker working with AT&T fiber and the shitty BGW router. The most discouraging part of most of the posts is the majority of answers being "BGW sucks, buying a second router and use passthrough is infinitely easier than DHCP Pihole Docker." That does not help me. I think my family could accept a cute little SBC taking up some real estate near the BGW, but a second router would be a real eyesore, not to mention their disdain that I was just doing random shit that they'd never understand or be able to benefit from.

The "I am a fucking idiot" that led to the breakthrough came after reading the thread in this post. I needed to set a static IP on the Pihole device itself. I already did so on the BGW – which doesn't matter after disabling its DHCP – and the Pihole, which doesn't matter because it won't be able to resolve itself before getting through to Pihole. After setting static IP on the Zimaboard, THINGS WORK!!! I swapped notes with a friend who did a local installation of Pihole instead of Docker, and the local installation comes with a mandatory step of setting static IP. So being lazy and going with CasaOS screwed me over solely because of DHCP. Thanks AT&T.

A lot of time was spent malding over IPv6 filtering, but that one is beyond my powers. Even the Pihole devs suggest disabling IPv6 on the router and keep all traffic IPv4 only. Yeah, I'm throwing in the towel on that one too.

I've been busy learning Docker and setting things up on the Zimaboard, whether through CasaOS or linuxserver's docker compose scripts. I'm now 1 step closer to finishing a project that's been on my mind for a long time, and hopefully I can get it out before this summer. The next step: product evaluation.

Maybe I'll have a post on that next time.

Obligatory fuck AT&T.

Show Comments