[SUPPORT] pihole for unRaid - Spants repo


Recommended Posts

On 6/27/2021 at 6:58 PM, Rockstar said:

 

This exact parameter was already in that field so I removed it and same thing.

I should note: I've already rebooted the server and the firewall just in case.


Just a note:

I solved my issue - It had nothing to do with the container or unraid at all.  Somehow my UDM Pro changed the range of allowed IPs for that subnet and thus wouldn't work. By updating this, everything now works as it originally did.

Link to comment
  • 2 weeks later...
7 hours ago, newunraiduser5 said:

Hi, I am trying to set up a whitelist at https://github.com/anudeepND/whitelist/blob/master/README.md but cant seem to get it to work without Python 3. The instructions for a docker install / install without Python doesnt seem to work either. Can anyone help.

 

Thanks in advance.

 

 

There is a section on the readme that will help.

 

0) If you dont have python3 on your unRaid, install it via the nerdtools plugin.

 

1) find the path for /etc/pihole/  - for me it is /mnt/user/appdata/pihole/pihole/

2) ssh to your unraid and cd to that directory

3) git clone https://github.com/anudeepND/whitelist.git

4) cd whitelist/scripts

5) ./whitelist.py --dir /mnt/user/appdata/pihole/pihole/ --docker

6) ./referral.sh --dir /mnt/user/appdata/pihole/pihole/ --docker

7) restart pihole

 

 

  • Like 2
  • Thanks 1
Link to comment
20 hours ago, spants said:

 

 

There is a section on the readme that will help.

 

0) If you dont have python3 on your unRaid, install it via the nerdtools plugin.

 

1) find the path for /etc/pihole/  - for me it is /mnt/user/appdata/pihole/pihole/

2) ssh to your unraid and cd to that directory

3) git clone https://github.com/anudeepND/whitelist.git

4) cd whitelist/scripts

5) ./whitelist.py --dir /mnt/user/appdata/pihole/pihole/ --docker

6) ./referral.sh --dir /mnt/user/appdata/pihole/pihole/ --docker

7) restart pihole

 

 

 

Thank you so much for this and I am sorry I missed it. Can I check where is the readme file?

Link to comment

Hey all. I am hoping someone can help me out here. I have been using this pi-hole template docker for almost 8 months without an issue. We had a power outage the other day, and since then if I use pi-hole for DNS nothing resolves, pages don't load, and ads are not blocked. If I change my dns setting in my router to just use google DNS everything is fine. If I change it to 192.168.1.2 (set for pihole in the docker config) my router insists I am not connected to anything and nothing loads. I really don't know why. I haven't changed any settings in forever which is why I mention the outage. Can't think how that would affect anything either but it's all I have. I also finally updated unraid to 6.9.2 but this issue was occurring before that. I'm going to attach whatever makes sense for settings as screen caps. Please let me know if anything else would be useful. If you look at AsusSetup 1 and 2 you will see there are two different places to enter a DNS server. Should I only be using 1 or both? That may not be *the* problem but I am thinking it might be *a* problem. I tried to follow SpaceInvader1's video as closely as I could. Also if I go into pihole settings and "update gravity" it hangs for a while then comes back with "DNS resolution not available". No idea what broke or how to fix it. Thanks for any and all suggestions.

AsusSetupPage1.png

AsusSetupPage2.png

PiHoleCfg1.png

PiHoleCfg2.png

PiHoleSetupPage1.png

Link to comment
33 minutes ago, Hydranmenace said:

I go into pihole settings and "update gravity" it hangs for a while then comes back with "DNS resolution not available".

You need fix this, if pihole can't reach upper DNS, how could it serve other. Anything blocking pihole 192.168.1.2 reach internet ?

Edited by Vr2Io
Link to comment
11 hours ago, Vr2Io said:

You need fix this, if pihole can't reach upper DNS, how could it serve other. Anything blocking pihole 192.168.1.2 reach internet ?

I understand I need to fix this but I do not know how. That is why I posted all the screen caps. I don't pretend to know what I'm doing. I'm a regular guy who followed a youtube tutorial.

I noticed that in my router in DHCP settings my IP Pool Starting Address is 192.168.1.2 and that is the IP pihole is using. Would that be a conflict? I thought that just meant that is the number the router would use to start looking for things on the network. When I tried an IP range outside of that for pihole it gave me an error saying it was outside the range of my subnet. Whatever that means.

Link to comment
6 hours ago, Hydranmenace said:

Would that be a conflict?

 

6 hours ago, Hydranmenace said:

When I tried an IP range outside of that for pihole it gave me an error saying it was outside the range of my subnet. Whatever that means.

The proper way was add pihole (192.168.1.2) in manual dhcp table, then router won't assign that IP to other.

 

But in general, those not a problem cause, even a router assign 192.168.1.2 to device, it will found this IP have a live device using it.

 

In your router LAN DHCP setting, you missing the default gateway , pls set it as router's IP.

 

I don't think problem cause by router setting, so suggest don't focus on router. Dose other docker reach Internet haven't problem ??

Edited by Vr2Io
Link to comment
6 hours ago, Hydranmenace said:

I understand I need to fix this but I do not know how. That is why I posted all the screen caps. I don't pretend to know what I'm doing. I'm a regular guy who followed a youtube tutorial.

I noticed that in my router in DHCP settings my IP Pool Starting Address is 192.168.1.2 and that is the IP pihole is using. Would that be a conflict? I thought that just meant that is the number the router would use to start looking for things on the network. When I tried an IP range outside of that for pihole it gave me an error saying it was outside the range of my subnet. Whatever that means.

 

Hey man:

 

Regular joe here, so take the advice for what it is worth.

 

It sounds like your router is acting as DHCP server.  If your DHCP settings are starting at .2, my guess is that some other device on the network was assigned to .2 by the router.

 

Maybe try changing the start of the range to .3.  This will set aside .1 for router and an open IP (.2) for the Pihole. 

 

When you restart your router, devices that need an IP will be assigned starting at .3, and you clear the conflict at .2.

 

Make sense?  (I don't use the Pi-hole as a DHCP server - so your setup might be different.  Maybe start getting it running with the router as DHCP server, get it running and adjust from there)

Link to comment
On 8/13/2021 at 6:41 PM, Hydranmenace said:

I understand I need to fix this but I do not know how. That is why I posted all the screen caps. I don't pretend to know what I'm doing. I'm a regular guy who followed a youtube tutorial.

I noticed that in my router in DHCP settings my IP Pool Starting Address is 192.168.1.2 and that is the IP pihole is using. Would that be a conflict? I thought that just meant that is the number the router would use to start looking for things on the network. When I tried an IP range outside of that for pihole it gave me an error saying it was outside the range of my subnet. Whatever that means.

 

Usually I set my DHCP range quite high up - maybe starting at 192.168.1.100 - so that nothing gets allocated in the ranges for my fixed IP. Some of the routers firmwares stop you allocating static addresses outside of this range.
So you can either, set the static address on the device itself (set to manual not dhcp on the device) and not worry about it on the router or have the large range on the router, set the pihole address and restart any device that may have claimed that IP address already.
Always set a DNS record manually (1.1.1.1 /8.8.8.8 or similar) for Unraid in the networking settings on unraid - dont let it use the DHCP dns as it will need DNS before the docker pihole as started (or if pihole is stopped)

 

Edited by spants
Link to comment
  • 1 month later...
  • 2 weeks later...

Error disappeared after recreating the docker directory. 

 

 

Hello,
sorry for my bad english.

I had to reinstall pihole. I use the same configuration. Pihole does not start anymore.

 

[s6-finish] waiting for services.
[s6-finish] sending all processes the TERM signal.
[s6-finish] sending all processes the KILL signal and exiting.

Edited by Rall1
Link to comment

Good Afternoon:

 

I recently upgraded my network router.  The router provides DHCP, not pihole.

 

For some reason, the hostnames in Pihole are still showing the names associated with the prior IP addresses.  (For instance, one windows system is being shown as an Ipad).  This is causing issues with my group rules.

 

I have tried to flush the table, cleared the logs, and powered the Pihole off and on.

 

This seems like it should be an easy fix.  Can someone help?   

 

 

Thanks.

 

Link to comment

Restore not working:

I have a fresh install of unraid, installed Pi Hole, and made minimal changes so I could get it running and restore my backup.

(IP for my unraid has changed, as well as pihole)

I can see data in the backup file, however, when I restore I get a new window:

Processed adlist (0 entries)
Processed adlist group assignments (0 entries)
Processed blacklist (exact) (0 entries)
Processed blacklist (regex) (0 entries)
Processed client (0 entries)
Processed client group assignments (0 entries)
Processed local DNS records (0 entries)
Processed domain_audit (0 entries)
Processed black-/whitelist group assignments (0 entries)
Processed group (0 entries)
Processed whitelist (exact) (0 entries)
Processed whitelist (regex) (0 entries)
OK

checking logs, I found error about gravitiy.db read only..

I removed pihole, removed appdata folder for pihole and downloaded..same thing.

I am on unraid 6.10.0-rc1

I googled and found info about directory ownership (checking in the docker, root owns /etc/pihole), and pihole -r

 

Link to comment

For whatever reason, within a few days of a pihole update, my pihole stops working. Lost connection to API, all DNS stops working et. No amount of stop/starting fixes it. The first time it happened, I tried all the common troubleshooting tips. However, now, its just faster to remove the image, and the data, and reinstall since the only setting I change is the IP. Everything chugs along fine until the next update

 

Pihole doesn't update enough for this to drive me mad, but next time, I would like to dig deeper. Any suggestions on where to start? Nothing jumps out other than DNS Service is not listening.....

Link to comment
  • 1 month later...

Cannot for the life of me get this Docker working, install goes well but I can never get to the WebUI.

 

I've seen tons of posts about this same issue in this thread, but nothing I've tried thus far is working.

Template Settings

Capture1.thumb.PNG.7bb0d463828cdef016ad7fe9e74a285b.PNG

Capture2.thumb.PNG.cad3b5432f0dca63ea3f8ad011354b89.PNG

 

Docker Run

docker run -d --name='pihole' --net='br0' --ip='192.168.1.5' -e TZ="America/New_York" -e HOST_OS="Unraid" -e 'TCP_PORT_53'='53' -e 'UDP_PORT_53'='53' -e 'UDP_PORT_67'='67' -e 'TCP_PORT_80'='80' -e 'TCP_PORT_443'='443' -e 'DNS1'='8.8.8.8' -e 'DNS2'='8.8.4.4' -e 'TZ'='America/New_York' -e 'WEBPASSWORD'='admin' -e 'INTERFACE'='br0' -e 'ServerIP'='192.168.1.5' -e 'ServerIPv6'='' -e 'IPv6'='False' -e 'DNSMASQ_LISTENING'='all' -v '/mnt/user/appdata/pihole/pihole/':'/etc/pihole/':'rw' -v '/mnt/user/appdata/pihole/dnsmasq.d/':'/etc/dnsmasq.d/':'rw' --cap-add=NET_ADMIN --restart=unless-stopped 'pihole/pihole:latest'
9a22a35e6fee700d3d88853be16878ed2b926cf6f15b69c053321827a4abdcc4

 

Log

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] 01-resolver-resolv: applying...
[fix-attrs.d] 01-resolver-resolv: exited 0.
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 20-start.sh: executing...
::: Starting docker specific checks & setup for docker pihole/pihole

[i] Installing configs from /etc/.pihole...
[i] Existing dnsmasq.conf found... it is not a Pi-hole file, leaving alone!
Converting DNS1 to PIHOLE_DNS_
Converting DNS2 to PIHOLE_DNS_
Setting DNS servers based on PIHOLE_DNS_ variable
::: Pre existing WEBPASSWORD found
DNSMasq binding to custom interface: br0
Added ENV to php:
"PHP_ERROR_LOG" => "/var/log/lighttpd/error.log",

"ServerIP" => "192.168.1.5",
"CORS_HOSTS" => "",
"VIRTUAL_HOST" => "192.168.1.5",
Using IPv4
::: Preexisting ad list /etc/pihole/adlists.list detected ((exiting setup_blocklists early))
https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
https://mirror1.malwaredomains.com/files/justdomains
http://sysctl.org/cameleon/hosts
https://s3.amazonaws.com/lists.disconnect.me/simple_tracking.txt
https://s3.amazonaws.com/lists.disconnect.me/simple_ad.txt
https://hosts-file.net/ad_servers.txt
::: Testing pihole-FTL DNS: FTL started!
::: Testing lighttpd config: Syntax OK
::: All config checks passed, cleared for startup ...
::: Enabling Query Logging
[i] Enabling logging...
::: Docker start setup complete
Checking if custom gravity.db is set in /etc/pihole/pihole-FTL.conf
Pi-hole version is v5.6 (Latest: v5.6)

AdminLTE version is v5.8 (Latest: v5.8)

FTL version is v5.11 (Latest: v5.11)

Container tag is: 2021.10.1
[cont-init.d] 20-start.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
Starting lighttpd
Starting crond
Starting pihole-FTL (no-daemon) as root
[services.d] done.
Stopping pihole-FTL
Starting pihole-FTL (no-daemon) as root
Stopping pihole-FTL
Starting pihole-FTL (no-daemon) as root

 

Bridging: Enabled 

Host access to custom networks: Enabled

 

What am I missing?

Link to comment
  • 4 weeks later...

Hi all,

 

This container stopped working/DNS on network not working as well as before lately?

 

NOTE: There has been a recent change with PiHole's docker usage of ENV variable DNS1 and DNS2 that caused me issues. These two Docker env. variables now need to be replaced with a single env. variable called PIHOLE_DNS_ and the value of your external DNS servers input in the format e.g. 1.1.1.1;1.0.0.1. The container seems to fail to start or will start but only resolve IP's from cache if using the old DNS1 & DNS2 env variables still.

 

Hope this helps someone else.

  • Thanks 2
Link to comment
  • 2 weeks later...

I'm seeing that the most recent upgrade sends my docker image into a continual fail and reboot cycle:

looking in the logs, I see that:
"install: cannot remove '/etc/dnsmasq.d/01-pihole.conf': Read-only file system"

 

the full logs:

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] 01-resolver-resolv: applying...
[fix-attrs.d] 01-resolver-resolv: exited 0.
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 20-start.sh: executing...
::: Starting docker specific checks & setup for docker pihole/pihole

[i] Installing configs from /etc/.pihole...
[i] Existing dnsmasq.conf found... it is not a Pi-hole file, leaving alone!
install: cannot remove '/etc/dnsmasq.d/01-pihole.conf': Read-only file system
[i] Installing /etc/dnsmasq.d/01-pihole.conf...[cont-init.d] 20-start.sh: exited 1.
[cont-finish.d] executing container finish scripts...
[cont-finish.d] done.
[s6-finish] waiting for services.
[s6-finish] sending all processes the TERM signal.
[s6-finish] sending all processes the KILL signal and exiting.

Link to comment
On 12/15/2021 at 8:20 PM, zaker said:

I'm seeing that the most recent upgrade sends my docker image into a continual fail and reboot cycle:

 

I can confirm that. After starting, the container runs for a few hours and then suddenly hangs in the reboot cycle.
Funnily enough, if it was switched off for a few hours, I can start it again, but then it only runs again for a few hours.

Link to comment
14 hours ago, Gokux said:

I can confirm that. After starting, the container runs for a few hours and then suddenly hangs in the reboot cycle.
Funnily enough, if it was switched off for a few hours, I can start it again, but then it only runs again for a few hours.

 

The template just uses the official PiHole docker - it seems that there is a discussion here that may help https://github.com/pi-hole/docker-pi-hole/issues/922 .

 

You could also change the docker tag to load a specific version: see here https://hub.docker.com/r/pihole/pihole/tags

 

I do not use PiHole now as I have adguard installed on my firewall so I cannot test.... But just to repeat - this is the offical docker image and not related to the template itself.

 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.