Community Hass.io Add-on: Pi-hole

hassio-repository
hassio-addon
Tags: #<Tag:0x00007fd078640280> #<Tag:0x00007fd078640118>

#145

Please share your add-on configuration and ResinOS network configuration file


#146

{
“log_level”: “info”,
“password”: “xsffghhh!”,
“update_lists_on_start”: false,
“http_port”: 80,
“https_port”: 443,
“dns_port”: 53,
“ssl”: false,
“certfile”: “fullchain.pem”,
“keyfile”: “privkey.pem”,
“interface”: “”,
“ipv6”: true,
“ipv4_address”: “”,
“ipv6_address”: “”,
“virtual_host”: “”,
“hosts”: []
}

[connection]
id=my-ethernet
type=ethernet
interface-name=eth0
permissions=
secondaries=

[wifi]
hidden=true
mode=infrastructure
ssid=My_Wifi_Ssid

[wifi-security]
auth-alg=open
key-mgmt=wpa-psk
psk=super_secret_wifi_password

[ipv4]
method=manual
address1=10.0.1.44/10.0.1.1;
dns=8.8.8.8;8.8.4.4;
dns-search=
method=manual

[ipv6]
addr-gen-mode=stable-privacy
method=auto


#147

Hmmm @Dominic, Have you enabled the auto-start of the add-on? (Not saying that it is required or not… just wondering based on another experience I came across).


#148

Yes sir I have


#149

After installing v1.0.1 on hassio v1.3 I had to add

"hosts": [
  {
    "name": "hassio.lan",
    "ip": "192.168.1.13"
  }
]

Otherwise hassio.local wouldn’t resolve. Just wanted to let you all know. I suppose because I disabled my routers DHCP and let my pi take care of DHCP as well as DNS.

But it seems that the hostnames does not apply to the hassio itself.

"hosts": [
  {
    "name": "hassio.lan",
    "ip": "192.168.1.13"
  },
  {
    "name": "wdmycloudmirror.lan",
    "ip": "192.168.1.15"
  }
]

If I go ssh [email protected] from hassio then i get

ssh: Could not resolve hostname wdmycloudmirror.local: Name does not resolve

I can do it from any other client on my network though. Is there someway to ensure that the network-wide hostnames applies to my hassio machine as well?

EDIT: I also just noticed that all client names in pihole are resolved to ip adresses instead of hostnames given in the addon. I would expect that the hosts configuration would take care of this? I’m hoping that it isn’t necessary to keep /etc/hosts manually updated at all times. I could imagine the problem is the hassio machine connects to wifi before the addon is up and running.


#150

Another issue. On power outage my network obviously goes down. Then pihole have problem restarting. I have auto-restart, but

[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] 01-sudo: applying... 
[fix-attrs.d] 01-sudo: exited 0.
[fix-attrs.d] 02-nginx: applying... 
[fix-attrs.d] 02-nginx: exited 0.
[fix-attrs.d] 03-pihole: applying... 
[fix-attrs.d] 03-pihole: exited 0.
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing... 
-----------------------------------------------------------
 Hass.io Add-on: Pi-hole v1.0.1
 Network-wide ad blocking using your Hass.io instance
 From: Community Hass.io Add-ons
 By: Franck Nijhof <[email protected]>
-----------------------------------------------------------
[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing... 
Log level is set to INFO
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] 02-updates.sh: executing... 
INFO: You are running the latest version of this add-on
[cont-init.d] 02-updates.sh: exited 0.
[cont-init.d] 03-version-requirements.sh: executing... 
[cont-init.d] 03-version-requirements.sh: exited 0.
[cont-init.d] 10-requirements.sh: executing... 
[cont-init.d] 10-requirements.sh: exited 0.
[cont-init.d] 11-patches.sh: executing... 
[cont-init.d] 11-patches.sh: exited 0.
[cont-init.d] 11-pihole.sh: executing... 
ip: RTNETLINK answers: Network unreachable
ip: can't find device ''
[cont-init.d] 11-pihole.sh: exited 1.
[cont-finish.d] executing container finish scripts...
[cont-finish.d] 99-message.sh: executing... 
-----------------------------------------------------------
				Oops! Something went wrong.
 
 We are so sorry, but something went terribly wrong when
 starting or running this add-on.
 
 Be sure to check the log above, line by line, for hints.
-----------------------------------------------------------
[cont-finish.d] 99-message.sh: exited 0.
[cont-finish.d] done.
[s6-finish] syncing disks.
[s6-finish] sending all processes the TERM signal.

I suppose it would work if it just retries after a bit. Any workarounds out there?


#151

The addon was unable to detect the network interface to use. Please specify it manually in the add-on configuration.


#152

Alright. I use wifi to connect but for some reason wlan are not showing if I run ifconfig on my pi. Now that confuses me quite a lot. Is it because I am connected differently when I ssh into my hassio OS? The adresses showing are not in my IP range and the subnet mask are different as well. Haven’t noticed any issues though except for what I stated earlier AND apparantly my Linux Mint laptop can’t connect using my LANs DHCP and DNS for some reason. All other devices works on the LAN.


#153

Did you get this solved?


#154

Nope. Disabled pi-hole.


#156

Hi!
I have Hass.io 0.67.0 installed in a dedicated Raspberry Pi.
I really like the idea of Pi-hole, so I installed the addon. The problem is that I’m getting an error stating that the port 53 is already in use:

[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] 01-sudo: applying... 
[fix-attrs.d] 01-sudo: exited 0.
[fix-attrs.d] 02-nginx: applying... 
[fix-attrs.d] 02-nginx: exited 0.
[fix-attrs.d] 03-pihole: applying... 
[fix-attrs.d] 03-pihole: exited 0.
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing... 
-----------------------------------------------------------
 Hass.io Add-on: Pi-hole v1.0.1
 Network-wide ad blocking using your Hass.io instance
 From: Community Hass.io Add-ons
 By: Franck Nijhof <[email protected]>
-----------------------------------------------------------
[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing... 
Log level is set to INFO
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] 02-updates.sh: executing... 
INFO: You are running the latest version of this add-on
[cont-init.d] 02-updates.sh: exited 0.
[cont-init.d] 03-version-requirements.sh: executing... 
[cont-init.d] 03-version-requirements.sh: exited 0.
[cont-init.d] 10-requirements.sh: executing... 
[cont-init.d] 10-requirements.sh: exited 0.
[cont-init.d] 11-patches.sh: executing... 
[cont-init.d] 11-patches.sh: exited 0.
[cont-init.d] 11-pihole.sh: executing... 
[cont-init.d] 11-pihole.sh: exited 0.
[cont-init.d] 12-dnsmasq.sh: executing... 
[cont-init.d] 12-dnsmasq.sh: exited 0.
[cont-init.d] 13-nginx.sh: executing... 
[cont-init.d] 13-nginx.sh: exited 0.
[cont-init.d] 14-password.sh: executing... 
  [✓] New password set
[cont-init.d] 14-password.sh: exited 0.
[cont-init.d] 15-hostname.sh: executing... 
[cont-init.d] 15-hostname.sh: exited 0.
[cont-init.d] 16-logfiles.sh: executing... 
[cont-init.d] 16-logfiles.sh: exited 0.
[cont-init.d] 17-hosts.sh: executing... 
[cont-init.d] 17-hosts.sh: exited 0.
[cont-init.d] 50-gravity.sh: executing... 
dnsmasq: failed to create listening socket for port 53: Address in use
[cont-init.d] 50-gravity.sh: exited 2.
[cont-finish.d] executing container finish scripts...
[cont-finish.d] 99-message.sh: executing... 
-----------------------------------------------------------
                Oops! Something went wrong.
 
 We are so sorry, but something went terribly wrong when
 starting or running this add-on.
 
 Be sure to check the log above, line by line, for hints.
-----------------------------------------------------------
[cont-finish.d] 99-message.sh: exited 0.
[cont-finish.d] done.
[s6-finish] syncing disks.
[s6-finish] sending all processes the TERM signal.

I don’t have anything DNS related in my raspberry, just the hassio installation straight from the image.

This is my configuration:

{
  "log_level": "info",
  "password": "somepassword",
  "update_lists_on_start": true,
  "http_port": 80,
  "https_port": 443,
  "dns_port": 53,
  "ssl": true,
  "certfile": "fullchain.pem",
  "keyfile": "privkey.pem",
  "interface": "",
  "ipv6": false,
  "ipv4_address": "",
  "ipv6_address": "",
  "virtual_host": "myaddress.duckdns.org",
  "hosts": []
}

Any ideas?


#157

Ensure you Host OS is running on 1.3, since 1.2 has a known issue with this.


#158

Yup!
I’m running 1.3


#159

That is unfortunate, still, it is not lying, port 53 is reported by the OS as in use, so there must be something on your system.
Are you running another DHCP server or DNS add-on? Something manually installed on the host OS? (dnsmasq for example) ?


#160

Oh man, this is embarrassing. I was indeed running DNSmask as an AddOn and I had completely forgotten about it.

Thanks a lot for your help! Keep up the good work :slight_smile:


#161

No problem at all m8! Glad you’ve found it.


#162

Hi, can somebody help me with Pi-hole and its configuration? I´ve got problem for last 4 days as I think Pi-hole is somehow blocking connection for weather cameras and darksky sensor. If I stop Pi-hole, everything works. If I start Pi-hole, it stop working. I´m using standart config as per github, nothing else special… Any idea how to configure Pi-hole? Or do I need some special setting? Or is it possible that it shold be problem to run via RPi3 on one device together Hassio with Pi-hole?


#163

@alibababa This indicated your Pi does not have a static IP and external DNS host configured.

This is required for everything to function properly.


#164

@frenck Thank you very much for your reply. Can you pls specify your reply closer?

To have static IP - my setting is, that this is managed by router and adress reservation. Is it ok or do I have to configure it different way?

To configure external DNS host - you mean something like duckdns or? What happened, if I don´t use it?


#165

Has a Nest fix been implemented?

I love PiHole and I love that you guys have made a community addon for hassio. But any time I install it, it breaks nest. Pretty much just nest, too. Usually after a reboot.

Or at least, is there a tutorial on how to get around this issue?