Please can someone help me fix my issues with adding the Zwave USB stick? HA is running on Freenas, if i SSH into it and use the command ls -ltr /dev/tty*|tail -n 1, it reports the following for my USB stick (itβs from zwave.me):
crw------- 1 root wheel 0x50 Nov 22 12:05 /dev/ttyv0
However, if I try to add the Zwave integration in the HA GUI and replace the default path (/zwaveusbstick) with /dev/ttyv0, it just reports the error βZ-Wave validation failed. Is the path to the USB stick correct?β
Iβve had problems with the automatic z-wave integration in the past
Iβm not always a fan of these automatic discovery integrations, sometimes they give me headaches. I usually add thing to my configuration the old way. Everything works much better that way and zwave is no exception. If you remove the automatic integration and setup zwave to your configuration.yaml, you may have better results.
I donβt know if you already have or even need a network_key but just in caseβ¦ I used the following command from inside the jail (wonβt work from FreeNAS host) to generate my network_key.
cat /dev/urandom | tr -dc '0-9A-F' | fold -w 32 | head -n 1 | sed -e 's/\(..\)/0x\1, /g'
Troy, youβre a scholar and a gent! I thought Iβd just try the USB stick address you mentioned in the automatic integration and it added it no problem and the zwave network appears to be running. Thanks very much for your instant help! Strange that the address isnβt being reported properly from the console.
Regarding auto integration vs manually adding it to the config, not sure how to proceed here. Iβll give the manual setup a try. Thanks again.
If the automatic integration is working you can stick with that. If you run into any errors during your initial zwave setup try the manual configuration
OK, great. At the risk of abusing your hospitality, I have another issue. Iβm trying to add HACS to the HA install, but configurator wont let me copy whole folders, only individual files. I tried to move the HACS files across one file at a time which was working, but configurator hides the "." folders I create, so that scuppered that approach. Is there a workaround to copy whole folder or unhide . folders? Does HACS even work on this install?
I assume you donβt have file sharing setup to the /home/hass directory inside the jail. Itβs easiest to just copy files using some type of network share.
Next quickest way to just install HACS is using the terminal
@troy my apologies for harassing you and the community, but Iβm repeatedly into issues when trying to activate the stream component. I wonder if itβs only my installation (I followed your recommended install in an iocage jail and it worked perfectly for v0.100.3), however when activating stream in configuration.yaml, I get the following error message:
Unable to install package av==6.1.2: WARNING: The directory β/.cache/pip/httpβ or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudoβs -H flag.
WARNING: The directory β/.cache/pipβ or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudoβs -H flag.
WARNING: Building wheel for av failed: [Errno 13] Permission denied: β/.cacheβ
ERROR: Command errored out with exit status 1:
command: /srv/homeassistant/bin/python3.7 -u -c βimport sys, setuptools, tokenize; sys.argv[0] = β"β"β/tmp/pip-install-v6h3bklg/av/setup.pyββ'ββ; file=ββ'ββ/tmp/pip-install-v6h3bklg/av/setup.pyββ'ββ;f=getattr(tokenize, β"βββopenβββββ, open)(file);code=f.read().replace(βββ"β\r\nββ'ββ, β"β"β\nββ'ββ);f.close();exec(compile(code, file, β"βββexecβββββ))β install --record /tmp/pip-record-oumu0gpi/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.7/av
cwd: /tmp/pip-install-v6h3bklg/av/
Complete output (53 lines):
running install
running build
running build_py
creating build
creating build/lib.freebsd-11.2-STABLE-amd64-3.7
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av
copying av/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av
copying av/datasets.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av
copying av/main.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av
copying av/deprecation.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/seekmany.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/experimental.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/frame_seek_example.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/glproxy.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/merge-filmstrip.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/encode_frames.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/second_seek_example.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/qtproxy.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/average.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/filmstrip.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/player.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/decode_threads.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/audio_player.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/dump_format.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/remux.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/save_subtitles.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/decode.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/resource_use.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/encode.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/show_frames_opencv.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/cctx_encode.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/cctx_decode.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/audio.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/graph.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/subtitles
copying av/subtitles/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/subtitles
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/data
copying av/data/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/data
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/codec
copying av/codec/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/codec
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/filter
copying av/filter/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/filter
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/audio
copying av/audio/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/audio
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/container
copying av/container/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/container
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/video
copying av/video/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/video
running build_ext
running config
pkg-config is required for building PyAV
----------------------------------------
ERROR: Command errored out with exit status 1: /srv/homeassistant/bin/python3.7 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = 'ββ"β/tmp/pip-install-v6h3bklg/av/setup.pyββ'ββ; file=ββ'ββ/tmp/pip-install-v6h3bklg/av/setup.pyββ'ββ;f=getattr(tokenize, β"βββopenβββββ, open)(file);code=f.read().replace(βββ"β\r\nββ'ββ, β"β"β\nββ'ββ);f.close();exec(compile(code, file, β"βββexecβββ"β))β install --record /tmp/pip-record-oumu0gpi/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.7/av Check the logs for full command output.
I tried to manually install (pip3 install av) in the virtualenv - does not work. Tried to find and install the package pkg-config - doesnβt exist. Searched forums - nothing useful.
Sorry, I was too fast. The system tricked me into believing that the stream component has been activated in my configuration.yaml, however this was not true.
After putting stream: into my configuration.yaml, Iβm getting the following notification:
component error: stream - Requirements for stream not found: [βav==6.1.2β]
My log file shows this:
Unable to install package av==6.1.2: WARNING: The directory β/.cache/pip/httpβ or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudoβs -H flag.
WARNING: The directory β/.cache/pipβ or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudoβs -H flag.
WARNING: Building wheel for av failed: [Errno 13] Permission denied: β/.cacheβ
ERROR: Command errored out with exit status 1:
command: /srv/homeassistant/bin/python3.7 -u -c βimport sys, setuptools, tokenize; sys.argv[0] = β"β"β/tmp/pip-install-c3atgp69/av/setup.pyββ'ββ; file=ββ'ββ/tmp/pip-install-c3atgp69/av/setup.pyββ'ββ;f=getattr(tokenize, β"βββopenβββββ, open)(file);code=f.read().replace(βββ"β\r\nββ'ββ, β"β"β\nββ'ββ);f.close();exec(compile(code, file, β"βββexecβββββ))β install --record /tmp/pip-record-nro32dp6/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.7/av
cwd: /tmp/pip-install-c3atgp69/av/
Complete output (59 lines):
running install
running build
running build_py
creating build
creating build/lib.freebsd-11.2-STABLE-amd64-3.7
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av
copying av/deprecation.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av
copying av/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av
copying av/datasets.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av
copying av/main.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/decode_threads.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/audio_player.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/player.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/merge-filmstrip.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/seekmany.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/cctx_decode.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/cctx_encode.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/frame_seek_example.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/encode_frames.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/audio.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/experimental.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/graph.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/second_seek_example.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/show_frames_opencv.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/dump_format.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/average.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/filmstrip.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/decode.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/qtproxy.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/resource_use.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/encode.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/glproxy.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/save_subtitles.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
copying scratchpad/remux.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/scratchpad
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/filter
copying av/filter/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/filter
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/video
copying av/video/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/video
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/data
copying av/data/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/data
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/subtitles
copying av/subtitles/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/subtitles
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/codec
copying av/codec/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/codec
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/audio
copying av/audio/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/audio
creating build/lib.freebsd-11.2-STABLE-amd64-3.7/av/container
copying av/container/init.py β build/lib.freebsd-11.2-STABLE-amd64-3.7/av/container
running build_ext
running config
Could not find libavformat with pkg-config.
Could not find libavcodec with pkg-config.
Could not find libavdevice with pkg-config.
Could not find libavutil with pkg-config.
Could not find libavfilter with pkg-config.
Could not find libswscale with pkg-config.
Could not find libswresample with pkg-config.
----------------------------------------
ERROR: Command errored out with exit status 1: /srv/homeassistant/bin/python3.7 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = 'ββ"β/tmp/pip-install-c3atgp69/av/setup.pyββ'ββ; file=ββ'ββ/tmp/pip-install-c3atgp69/av/setup.pyββ'ββ;f=getattr(tokenize, β"βββopenβββββ, open)(file);code=f.read().replace(βββ"β\r\nββ'ββ, β"β"β\nββ'ββ);f.close();exec(compile(code, file, β"βββexecβββ"β))β install --record /tmp/pip-record-nro32dp6/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.7/av Check the logs for full command output.
The error log reminds me of what you can see in the troubleshooting section of the stream component and I tried to install some βmissingβ packages manually - without success as they do not seem to exist.
Would you have any hint as to what packages to manually install in a FreeBSD world??
However, your appdaemon installed as part of your scripted install doesnβt appear to be working if I try to follow the hass-app install instructions. The appdaemon install is probably different. There isnt a python_packages entry or an apps.yaml file. Any ideas?
The script install is really just to save keystrokes. It is nothing more then appdaemon installed in a virtualenv. After a look at your link, I think for hass-apps to work you need to install it manually to the already created appdaemon virtualenv
After those steps you should be able to configure hass-apps. I assume your using my example config files? If not then you would need to create your own appdaemon configuration before it will run
Real quick here, The python_packages in your link is for appdaemon in the hass io ecosystem. You are not using hassio if you have followed this guide or used my script. Your install is just a plain virtualenv.
For the apps.yamlI actually just realized I never added one. Again (assume you used my config) you can create your own with this hello_world app from the appdaemon docs.
I used /home/hass/appdaemon/apps for apps. I set that location in /home/hass/appdaemon/conf/appdaemon.yaml and you can look there to see and/or change anything.
I am just trying to get the Mobile App integration working and I get the following error in the log.
'Unable to install package PyNaCl==1.3.0: WARNING: The directory '/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
WARNING: The directory '/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
WARNING: Building wheel for PyNaCl failed: [Errno 13] Permission denied: '/.cache'
ERROR: Could not build wheels for PyNaCl which use PEP 517 and cannot be installed directly'
Checked permissions and they seem fine.
root@homeassistant:/home/hass # ls -la
total 40
drwxrwxr-x 7 hass hass 9 Feb 4 2019 .
drwxr-xr-x 3 root wheel 3 Jan 28 2019 ..
-rw------- 1 hass hass 3077 Nov 27 14:37 .bash_history
drwx------ 3 hass hass 3 Jan 28 2019 .cache
drwx------ 2 hass hass 3 Jan 29 2019 .ssh
-rw-r--r-- 1 hass hass 259 Aug 1 14:21 .wget-hsts
drwxrwxr-x 5 hass hass 5 Jan 28 2019 appdaemon
drwxrwxr-x 2 hass hass 3 Jan 28 2019 configurator
drwxrwxr-x 8 hass hass 21 Nov 27 15:13 homeassistant
Also since swapping over to python 3.7 I have SSL data and handshake error messages
'Error doing job: SSL error in data received
Traceback (most recent call last):
File "/usr/local/lib/python3.7/asyncio/sslproto.py", line 526, in data_received
ssldata, appdata = self._sslpipe.feed_ssldata(data)
File "/usr/local/lib/python3.7/asyncio/sslproto.py", line 189, in feed_ssldata
self._sslobj.do_handshake()
File "/usr/local/lib/python3.7/ssl.py", line 763, in do_handshake
self._sslobj.do_handshake()
ssl.SSLError: [SSL: HTTP_REQUEST] http request (_ssl.c:1056)'
Error doing job: SSL handshake failed
Traceback (most recent call last):
File "/usr/local/lib/python3.7/asyncio/sslproto.py", line 625, in _on_handshake_complete
raise handshake_exc
File "/usr/local/lib/python3.7/asyncio/sslproto.py", line 189, in feed_ssldata
self._sslobj.do_handshake()
File "/usr/local/lib/python3.7/ssl.py", line 763, in do_handshake
self._sslobj.do_handshake()
ssl.SSLError: [SSL: HTTP_REQUEST] http request (_ssl.c:1056)
Unfortunately I do not have any guess about the ssl error right nowβ¦ Maybe after PyNaCl install is will go away. If not let me know and Iβll try to investigate further.
That worked. I actually found your second bit of advice on a freenas forum late last night and used it. The SSL errors are still occurring but reading the message make me think itβs receiving http request on the SSL port.
Any other ideas how to upgrade or overcome SSL issue. Iβm still unable to manage my Ecobee Switches (homekit controller needed) and itβs failing on registration due to SSL issue.
Sorry no. From my understanding itβs not possible to upgrade the βbaseβ BSD that is used when creating jails and the jail can not run a newer βbaseβ version than the host. Iβve discovered this seems to be an ongoing issue for FreeNAS, itβs always been this way and likely always will. (I mean FreeNAS is usually behind the actual FreeBSD from which itβs based on. For example we are waiting for an update to FreeNAS 11.X but FreeBSD is actually on 12.X - In other words new FreeNAS is not even released yet and itβs already outdated in BSD terms)
You do have a few options but they not likely to be what you had in mind.
Personally I have no plans of switching to Hassio but I did follow @Koenβs link to give it a try. I was able to successfully get Hassio running using a VM in about 20 min.
This has been working perfectly for me for some months, with fairly infrequent updates. I think my last update to 0.102.3 has broken the mobile integration which now uses mobile_app: in the configuration.yaml.
With this added, I get the following error when checking the configuration:
Component error: mobile_app - Requirements for mobile_app not found: ['PyNaCl==1.3.0'].