[SUPPORT] pihole for unRaid - Spants repo


Recommended Posts

For anybody else that has the problem as me, I was able to solve it by creating a file, dnsmasq.d/10-custom.conf, that contained

addn-hosts=/etc/pihole/extrahosts.list

then I created the extrahosts.list file in the pihole directory with the hosts entries I wanted for my local network.

Link to comment





[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 setup for docker diginc/pi-hole
+ [[ admin == '' ]]
+ pihole -a -p admin admin
[✓] New password set
Docker DNS variables not used
Existing DNS servers used
DNSMasq binding to default interface: eth0
Added ENV to php:
"PHP_ERROR_LOG" => "/var/log/lighttpd/error.log",
"ServerIP" => "192.168.86.5",
"VIRTUAL_HOST" => "192.168.86.5",
Using IPv4
dnsmasq: syntax check OK.
::: Testing DNSmasq config: ::: Testing lighttpd config: Syntax OK
::: All config checks passed, starting ...
::: Docker start setup complete
[✗] DNS resolution is currently unavailable
[cont-init.d] 20-start.sh: exited 1.
[cont-finish.d] executing container finish scripts...
[cont-finish.d] done.
[s6-finish] syncing disks.
[s6-finish] sending all processes the TERM signal.
[s6-finish] sending all processes the KILL signal and exiting.

Link to comment

Still no support for IPv6?

 

Using the documentation here https://github.com/diginc/docker-pi-hole I managed to 50% get Ipv6 to work.  I say 50% because so far it is only been tested and working on a Windows 10 PC.  I assume Linux will work as well since you can configure DNS entries for it.

 

Steps:

1. Make sure your unRAID servers network settings have IPv4 + IPv6 set

2. Add a new variable to the piHole docker configuration

image.png.6a35c6fa51fb3473ddd8056900b30fc3.png

 

I got the IPv6 from my router and just copy pasted it into the Value field.

3. Save the new field

4. Click apply and let the container rebuild

5. Edit your network connection in your PC as follows for "Internet Protocol Version 6"

image.png.6b4682fa53205f6e0cf83b3862d5d212.png

 

Unfortunately I can't get my router to use this new IPv6 address as its default IPv6 DNS and only clients with configurable DNS entries seem to work right now.

 

 

Link to comment
10 hours ago, sansoo22 said:

 

Using the documentation here https://github.com/diginc/docker-pi-hole I managed to 50% get Ipv6 to work.  I say 50% because so far it is only been tested and working on a Windows 10 PC.  I assume Linux will work as well since you can configure DNS entries for it.

 

Steps:

1. Make sure your unRAID servers network settings have IPv4 + IPv6 set

2. Add a new variable to the piHole docker configuration

image.png.6a35c6fa51fb3473ddd8056900b30fc3.png

 

I got the IPv6 from my router and just copy pasted it into the Value field.

3. Save the new field

4. Click apply and let the container rebuild

5. Edit your network connection in your PC as follows for "Internet Protocol Version 6"

image.png.6b4682fa53205f6e0cf83b3862d5d212.png

 

Unfortunately I can't get my router to use this new IPv6 address as its default IPv6 DNS and only clients with configurable DNS entries seem to work right now.

 

 

 

Exactly what I needed but seems I need to get IPv6 configured on unRAID in order for this to work. I tried just ticking the boxes to turn on IPv6 in both Network Settings and Docker settings but my containers will pull down an IPv6 IP but can't seem to make an outgoing connections. Hopefully someone can point me in the right direction to get IPv6 setup properly. It works on the rest of the machines on my network, just not the docker containers. 

Link to comment
55 minutes ago, BrandonG777 said:

just not the docker containers. 

 

You need to have an IPv6 subnet and gateway defined on the interface which is used by the docker containers.

In my case I use a dedicated interface eth1 (br1) for container communications. Under network settings this interface is configured as IPv4+IPv6 without IP addresses assigned.

Next in my docker settings the IPv4 and IPv6 assignments are set manually:

 

image.thumb.png.8e511f64d4ef460dd10229f9b0663259.png

image.thumb.png.021dcdbe9ec85411178f03b690579911.png

 

If you use another interface or VLAN interface for docker containers, it should have similar settings manually set by you.

Docker does not allow communication between containers and host address (normal setup for eth0/br0), you should use a VLAN interface or dedicated interface to make this work.

 

I let the pihole container start as the very first container. Hence it will always get the next available IPv6 address in this range ::2. This address is configured as variable for pihole.

 

image.png.fff3ddcbcf953b0dc1cd69523bbd5a1d.png

 

~# docker inspect Pi-hole
[
...
            "Networks": {
                "br1": {
                    "IPAMConfig": {
                        "IPv4Address": "10.0.101.100"
                    },
                    "Links": null,
                    "Aliases": [
                        "93d1d8b34d6a"
                    ],
                    "NetworkID": "31b4aa8d663469b6218b5a3c39b9b84cddf26191c5198804c162b5ce7cf3c713",
                    "EndpointID": "f31c1cd39360650a2d204542292beeb9a346518a304f0b4f80e673027d31f769",
                    "Gateway": "10.0.101.1",
                    "IPAddress": "10.0.101.100",
                    "IPPrefixLen": 24,
                    "IPv6Gateway": "2a02:a448:32d5:101::1",
                    "GlobalIPv6Address": "2a02:a448:32d5:101::2",
                    "GlobalIPv6PrefixLen": 64,
                    "MacAddress": "02:42:0a:00:65:64",
                    "DriverOpts": null

Make sure your router has gateway address ::1 assigned. I am using a Ubiquiti USG router, see example below.

~$ show interfaces
Codes: S - State, L - Link, u - Up, D - Down, A - Admin Down
Interface    IP Address                        S/L  Description
---------    ----------                        ---  -----------
eth0         xxx.yyy.zzz.n/24                  u/u  WAN
             2a02:aaaa:bbbb:cccc:f29f:b2ff:fe05:9fff/128
eth1         10.0.101.1/24                     u/u  LAN
             2a02:a448:32d5:101::1/64

This is how pi-hole network settings look like

image.png.20cc01059f424ed8d350568ec577dacb.png

 

And you need to select IPv6 DNS servers, e.g. google

image.png.38a1be690b65482f28326e4934e24b42.png

Edited by bonienl
Link to comment
On 7/19/2018 at 8:35 PM, CJW said:

Also having problems after the last update, with pihole docker quitting shortly after startup.

 

ETA:  During the brief period it is up, I have thrown several dig queries at it ('dig google.com @pihole') and the resolve just fine, so I am not sure what the "DNS resolution is currently unavailable" error means.

 

I have manually downgraded to the debian_v3.3 tag and I no longer have sudden crashes.  I don't know what the problem is with later versions, but I have had the same problem (crashing after only a couple of minutes) with v3.3.1, v3.3.1-1, and prerelease,

Link to comment
12 hours ago, nuhll said:

how?

 

Was that question to me?

 

You can change the target version in the "Edit" page (where you set up all your parameters).  The default container is "diginc/pi-hole:latest" (I think—I am not looking at the unraid screen right now—but the ':latest' part is the tag we want to change).  To find the available tags, you go to the docker bug page for the container.  That's in an earlier post in this thread, and can be found off the Community Applications listing for any given container.  In this case, it is https://hub.docker.com/r/diginc/pi-hole/.

 

So, go to that page and click the "Tags" nav link at the top.  Based on the change dates, I figured out that ':latest' must refer to ':debian_v3.3.1' (or newer) and that the version I was running prior to the last update had to be ':debian_v3.3'.

 

Last step is to edit the container, change the ':latest' tag to the ':debian_v3.3' tag and click Apply.  The container will reinstall based on the older version.

 

I guess I will follow newer releases and try them every once in while to see if the problem is solved.  In the meantime, v3.3 seems to work well enough for me.

  • Upvote 1
Link to comment
6 hours ago, CJW said:

 

Was that question to me?

 

You can change the target version in the "Edit" page (where you set up all your parameters).  The default container is "diginc/pi-hole:latest" (I think—I am not looking at the unraid screen right now—but the ':latest' part is the tag we want to change).  To find the available tags, you go to the docker bug page for the container.  That's in an earlier post in this thread, and can be found off the Community Applications listing for any given container.  In this case, it is https://hub.docker.com/r/diginc/pi-hole/.

 

So, go to that page and click the "Tags" nav link at the top.  Based on the change dates, I figured out that ':latest' must refer to ':debian_v3.3.1' (or newer) and that the version I was running prior to the last update had to be ':debian_v3.3'.

 

Last step is to edit the container, change the ':latest' tag to the ':debian_v3.3' tag and click Apply.  The container will reinstall based on the older version.

 

I guess I will follow newer releases and try them every once in while to see if the problem is solved.  In the meantime, v3.3 seems to work well enough for me.

 


Y, thanks.

 

That ":debian_v3.3" would have done it for me, but im sure maybe some other can use ur detailed explanation :P

 

Since u used this version , it didnt crashed? Ill try it.

Edited by nuhll
Link to comment
1 hour ago, nuhll said:

 


Y, thanks.

 

That ":debian_v3.3" would have done it for me, but im sure maybe some other can use ur detailed explanation :P

 

Since u used this version , it didnt crashed? Ill try it.

 

Well, better too much answer than not enough. :)  Good luck!

Link to comment
On 7/24/2018 at 7:15 PM, bonienl said:

 

What kind of problems?

 

I am using pihole without any problems on both ipv4 and ipv6 connections.

 

 

Can't start the docker anymore, Execution error Bad parameter. Re installed and works now. Only set manual update for this docker.

Edited by etsi
Link to comment

Hi,

 

First of all I just want to thank everyone involved with Pi-Hole, it's an awesome software? 

 

I just noticed that my Pi-Hole container crashes and won't start.

I haven't done any changes that I can think of that would course this.

 

This is the log from the container:

[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 setup for docker diginc/pi-hole
+ [[ admin == '' ]]
+ pihole -a -p admin admin
[✓] New password set
Using custom DNS servers: 9.9.9.9 & 8.8.8.8
DNSMasq binding to custom interface: br0
/etc/pihole/setupVars.conf: line 4: 9.9.9.9: command not found
[cont-init.d] 20-start.sh: exited 127.
[cont-finish.d] executing container finish scripts...
[cont-finish.d] done.
[s6-finish] syncing disks.
[s6-finish] sending all processes the TERM signal.
[s6-finish] sending all processes the KILL signal and exiting.

I've googled and searched this forum but I haven't found anything and I hope that you can help me :)

 

Thank you! 

Edited by Muff
Link to comment
3 hours ago, Muff said:

Hi,

 

First of all I just want to thank everyone involved with Pi-Hole, it's an awesome software? 

 

I just noticed that my Pi-Hole container crashes and won't start.

I haven't done any changes that I can think of that would course this.

 

This is the log from the container:


[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 setup for docker diginc/pi-hole
+ [[ admin == '' ]]
+ pihole -a -p admin admin
[✓] New password set
Using custom DNS servers: 9.9.9.9 & 8.8.8.8
DNSMasq binding to custom interface: br0
/etc/pihole/setupVars.conf: line 4: 9.9.9.9: command not found
[cont-init.d] 20-start.sh: exited 127.
[cont-finish.d] executing container finish scripts...
[cont-finish.d] done.
[s6-finish] syncing disks.
[s6-finish] sending all processes the TERM signal.
[s6-finish] sending all processes the KILL signal and exiting.

I've googled and searched this forum but I haven't found anything and I hope that you can help me :)

 

Thank you! 

 

This is the problem:

/etc/pihole/setupVars.conf: line 4: 9.9.9.9: command not found

What is in your setupVars.conf file?

 

 

Link to comment
8 hours ago, spants said:

 

This is the problem:


/etc/pihole/setupVars.conf: line 4: 9.9.9.9: command not found

What is in your setupVars.conf file?

 

 

 

Ah, didn't check that. Thank you!

 

The files looked like this:

IPV4_ADDRESS=192.168.1.2
IPV6_ADDRESS=
WEBPASSWORD=998ed4d621742d0c2d85ed84173db569afa194d4597686cae947324aa58ab4bb
PIHOLE_DNS_1= 9.9.9.9
PIHOLE_DNS_2=8.8.8.8
PIHOLE_INTERFACE=br0

The problem was that (somehow) a space got in front of the value behind "PIHOLE_DNS_1".

I remove the space in the XML/container config and now it works again.

Link to comment
On 7/20/2018 at 9:43 PM, TexasAg said:

For anybody else that has the problem as me, I was able to solve it by creating a file, dnsmasq.d/10-custom.conf, that contained


addn-hosts=/etc/pihole/extrahosts.list

then I created the extrahosts.list file in the pihole directory with the hosts entries I wanted for my local network.

 

@TexasAg - if you do that, then does the query log show the host instead of the IP under "Client"? 

Or is that just to make local DNS queries resolve?

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.