Brilliant guide and script, thank you very much @kanga_who . I was just wondering if I could suggest an alteration to the install script? Could you change it from: if systemctl list-unit-files ModemManager.service | grep enabled > /dev/null 2>&1; then
to if systemctl is-enabled ModemManager.service | grep enabled > /dev/null 2>&1; then
it’s just that list-unit-files shows what the vendor sets the service to on install (enabled or disabled) and therefore can’t be changed. This means that as it’s enabled, at least on ubuntu, grep gets a match and gives a false positive for the service being enabled.
UNIT FILE STATE VENDOR PRESET
ModemManager.service disabled enabled
1 unit files listed.
The script isn’t mine, I just take it from the official HA version. You are welcome to submit a change on Github HERE for a change to script and see if it gets through.
I’m trying to follow your instructions on a Pi 4B 2GB and kept failing at the last curl command:
pi@rpi4b01:~ $ sudo curl -sL "https://raw.githubusercontent.com/Kanga-Who/home-assistant/master/supervised-installer.sh" | bash -s -- -m raspberrypi4
[Info]
[Info]
[Info]
[Info] This script is taken from the official
[Info]
[Info] Home Assistant Supervised script available at
[Info]
[Info] https://github.com/home-assistant/supervised-installer
[Info]
[Info]
[Info]
pi@rpi4b01:~ $
pi@rpi4b01:~ $ curl -vvv https://registry-1.docker.io/v2/ * Expire in 0 ms for 6 (transfer 0x59f880)
* Expire in 1 ms for 1 (transfer 0x59f880)
* Expire in 0 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 0 ms for 1 (transfer 0x59f880)
* Expire in 0 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 0 ms for 1 (transfer 0x59f880)
* Expire in 0 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 0 ms for 1 (transfer 0x59f880)
* Expire in 0 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 1 ms for 1 (transfer 0x59f880)
* Expire in 1 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 1 ms for 1 (transfer 0x59f880)
* Expire in 1 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 2 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 3 ms for 1 (transfer 0x59f880)
* Expire in 3 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 4 ms for 1 (transfer 0x59f880)
* Expire in 8 ms for 1 (transfer 0x59f880)
* Expire in 6 ms for 1 (transfer 0x59f880)
* Expire in 6 ms for 1 (transfer 0x59f880)
* Expire in 8 ms for 1 (transfer 0x59f880)
* Expire in 6 ms for 1 (transfer 0x59f880)
* Expire in 6 ms for 1 (transfer 0x59f880)
* Expire in 8 ms for 1 (transfer 0x59f880)
* Expire in 8 ms for 1 (transfer 0x59f880)
* Expire in 8 ms for 1 (transfer 0x59f880)
* Expire in 8 ms for 1 (transfer 0x59f880)
* Expire in 9 ms for 1 (transfer 0x59f880)
* Expire in 9 ms for 1 (transfer 0x59f880)
* Expire in 16 ms for 1 (transfer 0x59f880)
* Expire in 12 ms for 1 (transfer 0x59f880)
* Expire in 12 ms for 1 (transfer 0x59f880)
* Expire in 16 ms for 1 (transfer 0x59f880)
* Expire in 12 ms for 1 (transfer 0x59f880)
* Expire in 12 ms for 1 (transfer 0x59f880)
* Expire in 16 ms for 1 (transfer 0x59f880)
* Expire in 16 ms for 1 (transfer 0x59f880)
* Expire in 16 ms for 1 (transfer 0x59f880)
* Expire in 16 ms for 1 (transfer 0x59f880)
* Expire in 50 ms for 1 (transfer 0x59f880)
* Expire in 50 ms for 1 (transfer 0x59f880)
* Expire in 32 ms for 1 (transfer 0x59f880)
* Expire in 50 ms for 1 (transfer 0x59f880)
* Expire in 50 ms for 1 (transfer 0x59f880)
* Expire in 32 ms for 1 (transfer 0x59f880)
* Expire in 50 ms for 1 (transfer 0x59f880)
* Expire in 50 ms for 1 (transfer 0x59f880)
* Expire in 50 ms for 1 (transfer 0x59f880)
* Trying 52.5.11.128...
* TCP_NODELAY set
* Expire in 149924 ms for 3 (transfer 0x59f880)
* Expire in 200 ms for 4 (transfer 0x59f880)
* Connected to registry-1.docker.io (52.5.11.128) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
* CAfile: none
CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Change cipher spec (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-RSA-AES128-GCM-SHA256
* ALPN, server did not agree to a protocol
* Server certificate:
* subject: CN=*.docker.io
* start date: May 23 00:00:00 2020 GMT
* expire date: Jun 23 12:00:00 2021 GMT
* subjectAltName: host "registry-1.docker.io" matched cert's "*.docker.io"
* issuer: C=US; O=Amazon; OU=Server CA 1B; CN=Amazon
* SSL certificate verify ok.
> GET /v2/ HTTP/1.1
> Host: registry-1.docker.io
> User-Agent: curl/7.64.0
> Accept: */*
>
< HTTP/1.1 401 Unauthorized
< Content-Type: application/json
< Docker-Distribution-Api-Version: registry/2.0
< Www-Authenticate: Bearer realm="https://auth.docker.io/token",service="registry.docker.io"
< Date: Tue, 29 Sep 2020 05:20:59 GMT
< Content-Length: 87
< Strict-Transport-Security: max-age=31536000
<
{"errors":[{"code":"UNAUTHORIZED","message":"authentication required","detail":null}]}
* Connection #0 to host registry-1.docker.io left intact
edit: I just did a fresh Raspi OS install on a Pi4 4gb, and installed as per the guide. Fully up and running within 25 mins, so you must not have followed the instructions correctly.
I did a fresh install from a Raspberry Pi OS image and I’m consistently getting this:
root@rpi4b01:~# curl -sL "https://raw.githubusercontent.com/Kanga-Who/home-assistant/master/supervised-installer.sh" | bash -s -- -m raspberrypi4
[Info]
[Info]
[Info]
[Info] This script is taken from the official
[Info]
[Info] Home Assistant Supervised script available at
[Info]
[Info] https://github.com/home-assistant/supervised-installer
[Info]
[Info]
[Info]
[Warning] Docker is using json-file and not 'journald' as the logging driver, this is not supported.
[Info] Creating NetworkManager configuration
root@rpi4b01:~#
The earlier curl command didn’t complete successfully the first time either.
I suspect from where I am, docker.com and docker.io aren’t consistently accessible.
root@rpi4b01:~# bash supervised-installer.sh -s -- -m raspberrypi4-64
[Info]
[Info]
[Info]
[Info] This script is taken from the official
[Info]
[Info] Home Assistant Supervised script available at
[Info]
[Info] https://github.com/home-assistant/supervised-installer
[Info]
[Info]
[Info]
[Info] Creating NetworkManager configuration
[Info] Restarting NetworkManager
supervised-installer.sh: line 192: --/hassio.json: No such file or directory
Also thought my DNS must be unreliable, so I set /etc/resolv.conf to use Cloudflare:
My ISP’s DNS must be really unreliable or maybe my Pi’s wifi module is degrading (yes, I know I should be using ethernet & eventually I will). I had to run the supervised-installer.sh tens of times before I finally got to:
[info] Home Assistant supervised is now installed
[info] First setup will take some time, when it's ready you can reach it here:
[info] http://192.168.20.138:8123
My next issue is pretty basic & I’m a docker noob so please forgive me - I’m unable to load up the UI using that URL above.
How do I check if the ha services are running and confirm what URL to load?
Edit 1: OK my Pi’s network config must be messed up and I don’t know how to fix it. I managed to load up the Home Assistant UI by loading it from localhost, so I’m sure it’s up.
Weird thing is I see the install script says the IP is 192.168.20.138 but ifconfig shows 192.168.20.142. Loading either IPs from my desktop PC don’t work. Using its hostname rpi4b01.local doesn’t work.
What/where should I check?
Edit 2: Not sure exactly what helped, but I managed to reach my Pi using its hostname in the end.
Probably re-entering my wifi ssid and password using raspi-config, or selecting US for the wifi region since I just changed my home wifi to 802.11ac may have been the solution.
Hello, I am getting following error. I am on ‘Linux raspberrypi 5.4.51-v7+ #1333 SMP Mon Aug 10 16:45:19 BST 2020 armv7l GNU/Linux’
pi@raspberrypi:~ $ sudo curl -sL "https://raw.githubusercontent.com/Kanga-Who/home-assistant/master/supervised-installer.sh" | bash -s -- raspberrypi3
[info]
[info] This script is taken from the official
[info]
[info] Home Assistant Supervised script available at
[info]
[info] https://github.com/home-assistant/supervised-installer
[info]
[info] Creating default docker deamon configuration /etc/docker/daemon.json
bash: line 73: /etc/docker/daemon.json: Permission denied```
Can you please help as i have been testing different commands since last 2 days and it always stuck at this point.
Thank you
Edit: this might be caused by a faulty SD card… I’ll get back on this later.
Edit 2: Nope, tried different sdcard but also problems. They appear at different moments but seem to only occur after networkmanager is installed. My last install attempt actually resulted in a frozen pi, had to cycle the power. After this I can’t even access it anymore…
Edit 3: Turns out you’re not supposed to first boot the raspberry pi and use WIFI to connect… when you do networkmanager kills that connection and then totally disregards a working wifi network connection. After the networkmanager install I can only acces the pi using the lan port. And to top it off, it regularly requests a new ip address from the DHCP server for unclear reasons…
I got it working in the end but it still seems very unstable. Just did a restore of my settings and now HA doesnt come back up anymore
I was wondering where is the location for homeassistant folders in this case. I am tying to add ‘Hive’ customer integration and would add couple of files in homeassistant folder.