1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Setting up Pi-hole

Discussion in 'Linux & Open Source' started by NoNameNoNumber, 5 Nov 2016.

  1. ChrisD.

    Caporegime

    Joined: 20 Sep 2006

    Posts: 26,801

    I use it for the auto cookie feature.
     
  2. Rainmaker

    Sgarrista

    Joined: 18 Aug 2007

    Posts: 8,916

    Location: Liverpool

    Be careful of too many lists. They will slow down your network (and browsing experience). The OISD.nl list will cover basically everything you need, and not block things you want to keep (shopping baskets, referrals between the same site, game scores, porn, warez etc). You're asking about adding AdGuard on top of PiHole? Depends how you mean. I run AdGuard Home, which is an alternative to PiHole. I find it far superior, and easier to use to boot. YMMV and everyone is different. I started out with PiHole years ago but when AdGuard Home came out I was an instant convert. It does things PiHole doesn't out of the box, like DoH, DoT, DoQ, DNSSEC, EDNS, DHCP stuff, client tagging and tracking and so on. It also has a nicer UI imo, but again that's subjective.

    So, if you mean AdGuard Home then no - it's one or the other. If you mean AdGuard as in the browser based ad blocker plugin, then definitely add one of those to your devices where possible. DNS blocking (PiHole or AGH) have their limitations, including not being able to delete the white space on web pages where the ads failed to load. A local ad blocking extension will tidy all that up for you with cosmetic filtering. I'd recommend uBlock Origin over anything else, for that job, though. I only use AdGuard itself on Safari, where there's no alternative.
     
  3. Robert

    Capodecina

    Joined: 20 Oct 2002

    Posts: 15,388

    Location: North West

    Ah, cool. Can Adguard be run as a server instance similarly to PiHole?
     
  4. Rainmaker

    Sgarrista

    Joined: 18 Aug 2007

    Posts: 8,916

    Location: Liverpool

    Yeah, exactly the same essentially. Mine runs in Docker on my Synology DS218+, so basically the same way as you're running PiHole on yours. Quick and easy.
     
  5. Robert

    Capodecina

    Joined: 20 Oct 2002

    Posts: 15,388

    Location: North West

    Hmm...after knowing about PiHole for a while I've only just gotten around to installing it. Adguard does certainly look good from a UI perspective...may be I'll still with PiHole for now and investigate adguard at a later date.
     
  6. ChrisD.

    Caporegime

    Joined: 20 Sep 2006

    Posts: 26,801

    I didn't realise AdGuard did that, I thought they only did browser add-ons.

    Can AdGuard sync between two devices, say a Ubuntu VM and a rPi?
     
  7. Armageus

    Don

    Joined: 19 May 2012

    Posts: 12,986

    Location: Spalding, Lincolnshire

  8. Rainmaker

    Sgarrista

    Joined: 18 Aug 2007

    Posts: 8,916

    Location: Liverpool

    Yep, I explained the difference in post 742 above. As I said, it has some features out of the box that PiHole doesn't and I prefer it overall. I only mention it in passing (where the differences are relevant) so as not to derail this thread. No point setting up a separate thread for me and what is likely the one other person using it. :D

    Edit: There's a lot more info about it on their GitHub page, as opposed to the plain splash page you linked. There's a direct comparison with PiHole features there too.
     
  9. Rainmaker

    Sgarrista

    Joined: 18 Aug 2007

    Posts: 8,916

    Location: Liverpool

    Sorry, I only just noticed the extra replies sandwiched between the others. You will find success with either project mate, the joy of open source. Just be aware as I said that PiHole has less functionality out of the box than AdGuard Home, though you can add it manually. For example, DNS over HTTPS/TLS/Quic support, parental control, enforced safesearch for children's devices, client tagging etc.

    Yes you can sync using linuxserverio/adguardhome-sync.
     
  10. ChrisD.

    Caporegime

    Joined: 20 Sep 2006

    Posts: 26,801

    Cheers, I’ll check it out tomorrow.
     
  11. Robert

    Capodecina

    Joined: 20 Oct 2002

    Posts: 15,388

    Location: North West

    Thanks buddy, Scott helme had a few guides up on enabling doh in pihole. Was going to check it out.
     
  12. Avathar77

    Mobster

    Joined: 28 May 2010

    Posts: 4,342

    Location: London, UK

    Edit - wrong thread!
     
  13. HippoTank

    Gangster

    Joined: 27 Apr 2018

    Posts: 107

    I find that my PiHole has issues when i'm trying to refresh to get the latest version of a site. It keeps the old version in the cache and I don't know how to clear it/refresh it. I ended up just changing my DNS servers to Google. Gets annoying when you do a lot of web design changes and need to see the instant result
     
  14. Rainmaker

    Sgarrista

    Joined: 18 Aug 2007

    Posts: 8,916

    Location: Liverpool

    Your pi-hole is running as a (squid?) proxy? Or do you mean the IP is changing and pi-hole is caching the old result? In the former I can't help you aside from pointing you at the cache duration/exceptions. In the latter case, it's a TTL issue in your site's DNS, or else perhaps more likely a browser cache issue (Ctrl + F5).
     
  15. HippoTank

    Gangster

    Joined: 27 Apr 2018

    Posts: 107

    This might be what I was looking for. It's not the IP change, it's just when I update the pages on that domain - 100% not a browser cache issue though! Thanks!
     
  16. ChrisD.

    Caporegime

    Joined: 20 Sep 2006

    Posts: 26,801

    @Rainmaker do you know if AdGuard Home home can do local DNS entries?
     
  17. Rainmaker

    Sgarrista

    Joined: 18 Aug 2007

    Posts: 8,916

    Location: Liverpool

    The GUI offers rewrites, so 'My-Desktop' becomes 172.16.10.3, for example. It's basically dnsmasq underneath iirc, so pretty much anything will be possible. I suspect you'll need to adjust the (YAML) config file or perhaps set it as a cli flag on launch (eg as a Docker env variable). I suspect you may find it as part of the DHCP options, should you run it as your local DHCP server as well as DNS, but I'm not certain. The Wiki may help you further, or if not search the Issues on Github.
     
  18. ChrisD.

    Caporegime

    Joined: 20 Sep 2006

    Posts: 26,801

    Yeah I've done that and if I do a nslookup it resolves but I cannot ping the address as it doesn't seem to want to resolve.
     
  19. Rainmaker

    Sgarrista

    Joined: 18 Aug 2007

    Posts: 8,916

    Location: Liverpool

    Strange. Have you double checked the rewrites? I'm assuming you have, as I know you know your way around a PC. What's the offending OS? I know systemd-resolved is usually set up in a (frankly retarded) way by most distros, in which it won't resolve local DNS despite being pointed at your own server. On Ubuntu/WSL (I'm normally in Fedora, Arch or *BSD but had to fire up Windows 10 Pro for a bit) I get:

    Code:
    $ dig @10.100.0.5 raspi
    
    ; <<>> DiG 9.16.1-Ubuntu <<>> @10.100.0.5 raspi
    ; (1 server found)
    ;; global options: +cmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 37871
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
    
    ;; QUESTION SECTION:
    ;raspi.                         IN      A
    
    ;; ANSWER SECTION:
    raspi.                  10      IN      A       10.100.0.12
    
    ;; Query time: 1 msec
    ;; SERVER: 10.100.0.5#53(10.100.0.5)
    ;; WHEN: Mon Apr 19 18:19:47 BST 2021
    ;; MSG SIZE  rcvd: 39
    Code:
    $ ping -c 4 raspi
    PING raspi (10.100.0.12) 56(84) bytes of data.
    64 bytes from raspi (10.100.0.12): icmp_seq=1 ttl=64 time=1.49 ms
    64 bytes from raspi (10.100.0.12): icmp_seq=2 ttl=64 time=0.949 ms
    64 bytes from raspi (10.100.0.12): icmp_seq=3 ttl=64 time=1.01 ms
    64 bytes from raspi (10.100.0.12): icmp_seq=4 ttl=64 time=1.03 ms
    
    --- raspi ping statistics ---
    4 packets transmitted, 4 received, 0% packet loss, time 3003ms
    rtt min/avg/max/mdev = 0.949/1.120/1.492/0.216 ms
     
  20. ChrisD.

    Caporegime

    Joined: 20 Sep 2006

    Posts: 26,801

    I'm using macOS, but it's just started working so I assume it was some caching issue. On the face of it I prefer Pi-Hole however I need to give it some time.