My way to install HASSIO on QNAP NAS

Im back :wink:
But with the same problem…or at least the same symptom. Homeassistant is not answering on 192.168.8.145: 8123 since the last update (a few hours ago).
I’ve Been running for weeks and even survived the last update before this one… The ubuntu server VM is ok on that IP so I just used puTTY and ran ā€œdocker restart homeassistantā€ but that did not help…
I’m a novice at Linux so running this configuration was probably a bad idea from the beginning…
The Docker0 IP shows as 172.17.0.1
Hassio at 172.30.32.1
Is that OK?
Do i need to use some ā€œhassioā€ command ? (I tried hassio restart homeassistant But the hassio command is not recognized and I have so little understanding of this configuration so I cannot even understand if that is how it should be )
Is there another way to restart homeassistant?
Is there any other command i can run to se if homassistant/hassio is up and running and start to understand where its stuck?
Sorry for beeing such a noob.

Edit: Hmm… I can see now that the QNAP and hence the virtual switch has a new IP from my router… Could that for some reason affect homeassistant? It probably should not since i can reach the Ubunte server om its IP which should be the same as homeassistants IP…

Great tutorial thanks! I seems to be the best way for my use…Ie: not to install on Pi3 as it kept freezing up… Only had two flows running in Node Red and the Pi couldn’t manage that!

I installed the Node Red addon and all seemed to go well until… I clicked on the side panel and was greeted with 502: Bad Gateway… I checked the system log and found the below…

19-11-12 10:15:26 INFO (MainThread) [hassio.addons] Create Home Assistant add-on data folder /data/addons/data/a0d7b954_nodered
19-11-12 10:15:26 INFO (SyncWorker_8) [hassio.docker.interface] Pull image hassioaddons/node-red-amd64 tag 5.0.3.
19-11-12 10:16:33 INFO (MainThread) [hassio.addons] Add-on ā€˜a0d7b954_nodered’ successfully installed
19-11-12 10:16:37 INFO (MainThread) [hassio.ingress] Update Ingress as panel for a0d7b954_nodered
19-11-12 10:16:45 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 10:17:05 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 10:18:23 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 10:19:59 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 10:33:18 WARNING (MainThread) [hassio.api.addons] Protected flag changing for core_samba!
19-11-12 10:34:06 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 10:34:11 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 10:37:56 INFO (SyncWorker_2) [hassio.docker.interface] Restart homeassistant/qemux86-64-homeassistant
19-11-12 10:38:35 INFO (MainThread) [hassio.homeassistant] Detect a running Home Assistant instance
19-11-12 10:55:02 INFO (MainThread) [hassio.homeassistant] Updated Home Assistant API token
19-11-12 10:55:32 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 11:02:30 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 11:03:32 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]
19-11-12 11:03:38 ERROR (MainThread) [hassio.api.ingress] Ingress error: Cannot connect to host 172.30.32.1:63164 ssl:None [Connection refused]

I can see NR was installed ok but I am damned if I can work out what is wrong…

Anyone???

I think you need to set ā€œsslā€: false . That is if you do not have a ssl certificate… Im unfortunately not able to run hassio at all so i can not be more specific but look here https://github.com/hassio-addons/addon-node-red/issues/268#issuecomment-525945305

Yep that worked…and a bit more patience helped too!..

Interesting situation with this install is the response time when using HA is slower than I expected. Is there a way to make it more responsive? My install is on a TS453pro using 2 cores and 2gb ram in the VM with 25Gb disk.

Now that I have Node Red up and running I am setting up the flows I had in the previous installation.

One thing has me puzzled when configuring my Kodi lighting flow is that the ā€˜media_player_Kodi HT’ cannot be found in Node Red.

I have this entry in config…

media_player:

  • platform: kodi
    host: 192.168.1.208
    name: Kodi HT

I appears on the Lovelace overview as Kodi HT but is invisible to NR.

What am I missing??

Just figured it out…

I found the entry in the Entities and I copied and pasted ā€˜media_player.kodi_ht’ into the Entity ID of the State node and Viola it works!!

Next, onto trying an independent installation of NR on a Pi.

well… to reply to my own post a few steps up… Since i do not understand enough about containers and how they work, I installed portainer. It showed hassio_dns, hassio_supervisor, two addons to hassio and homeassistant. All showed as running. However when going to command propt in homeassistant container via portainer and typed hass, it started up saying there was no configuration file and continued to start up with a new one. I went to 8123 and created the same account again… Logged in and restored the lattest snapshot. Im taking baby steps to really understand why tis happens… I guess ill wait for next uppdate of VM/QTS/hassio to see if it fails again…as of now it is running

I have to apt-get update/upgrade and restart my VM every week beacuse the VM starts using more cpu cycles. ssh into the VM i can only see its python3 process but no further info. Anyone else has this problem?

edit this morning the VM again was utilising the HD and CPU for 50%+. I turned it off this time, anyone has a idea how to find out what process is causing this?

Because you ran the hass command, without any parameters? You would need to specify the configuration file location, but you really shouldn’t be using that command INSIDE the running home assistant container, because, well, home assistant is already running.

Thanks…yes i found the info about parameters later… But that is not the main issue…I just wanted to kick home assistant in the nuts since it had stopped responding on port 8123… any enlightening thoughts about that? As I wrote Portainer showed every container as running… so what can the problem be?

You have to review the logs and see why it failed to actually run. If you want to ā€˜kick it in the nuts’, restart the container. The next time that container restarts, if there was a problem in the configuration (likely cause), you will lose your settings you just set, and it will do the same thing.

ALWAYS review the logs before jumping in and doing something that will break the system.

Hmm… i would have ranked the configuration as one of the most unlikely causes since I can run home assistant without any issues for weeks, but when I updated VM and/or hassio it just stops responding on 8123 while , as you say, still is running… first I thought ther was an issue with my router firewall but I fail to figure it out…
Anyway, thanks for trying to help… I’ll do some reading instead of clogging this thread up

You are aware that there are breaking changes with almost every release? If those breaking changes apply to your setup, YOU have to fix them before updating. A bad configuration (like what happens when a component changes with updates) can absolutely cause it to ā€œnot respond on 8123ā€ because home assistant isn’t running. It is sitting there with an error waiting on you to fix it…

Yes I am aware and that’s partly why I left the configuration as clean as possible the last time.
However I see now that I had node-red running and telldus enteties… so maybe not as clean as I intended…
Anyway… I’ll wait for next updates and see if it happens again. I do not want to put too much effort into configuring Hass before I feel I can rely on it…I guess that actually means ā€œthat I understand it in more depthā€
Thanks for your time!
Actually… as I wrote on my first post…I was going to go wit a Raspberry PI… do you recommend that I, with my limited knowledge on VMs, containers, virtual switches and what have you… go that way instead? (No disrespect to OP)

Away with only mobile phone so sorry for any misshaps…

I think the raspberry pi is a cool device but I don’t think it’s appropriate to rely on for your home automation brains.

1 Like

I narrowed it down to the google drive snapshot add-on its causing NPM and Node processes to be stuck in a loop.

Thank you so much for this guide, it worked like a charm.
Have you got audio working on ubuntu server 18.04 LTS virtual machine hosted on a QNAP NAS?

I don’t use audio on my Nas since there is no need for it for me…

What’s your idea behind, do you want to connect some speakers to the bad and play audio on that? Or what are you thinking of?

Platini76, I get the same error after a few months of running. I am wondering if it is the history or log getting too full. I do limit the log files. Did you find out anything on your side?

@BjornH big thanks a lot for this great guide. Based on this I have setup Hass.io on my qnap TS-453B with Aeotec Z-Wave, Zigbee2Mqtt and Bluetooth.
As there were a couple of obstacles along the way I want to share them with all of you, hoping it will help people finding solutions for their problems:
Problem 1: Aeotec Stick will not show up when doing lsusb
Solution 1: Use Front USB Port
Problem 2: Aeotec Stick not available in Hass.Io
Solution 2: Followed Link provided by Bjorn but instead of Back USB port using Front USB port
Problem 3: Stick will not show after restart of Qnap
Solution 3a: Can’t find the link anymore, but here is what you need to do:
Enable the autorun.sh processing in the Control Panel -> Hardware -> General: Run user defined startup processes (autorun.sh)

With Putty 
mount $(/sbin/hal_app --get_boot_pd port_id=0)6 /tmp/config

With WinSCP
Create/Edit /tmp/config/autorun.sh.
Ensure that /tmp/config/autorun.sh is executable
# chmod +x /tmp/config/autorun.sh
IMPORTANT: Unmount the mounted flash partition:
 # umount /tmp/config

Add to autostart.sh
insmod /usr/local/modules/cp210x.ko
insmod /usr/local/modules/cdc-acm.ko
chmod /dev/ttyACM0

Solution 3b: Make sure your USB devices in the Virtual Station are mounted (have not found a solution to ensure that is happening after restart) and restart Hass.Io

Problem 4: In Hass.Io Error ā€œNot running in priviledge modeā€
Soltuion 4: https://gist.github.com/frenck/32b4f74919ca6b95b30c66f85976ec58#gistcomment-2803212

Thanks to all the different people who have helped me on my setup and I hope this summary will help to find all those great helps at one shot.

2 Likes