Serial Error: Port /dev/ttyUSB0 does not exist

  • Platform information:

    • Hardware: Intel® Celeron® CPU G1840 @ 2.80GHz/3696356 Bytes of RAM/36G SSD (18G free)
    • OS: Linux hass 4.15.0-39-generic #42-Ubuntu SMP Tue Oct 23 15:48:01 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux (Ubuntu 18.04 LTS)
    • Java Runtime Environment: OpenJDK Runtime Environment (Zulu 8.33.0.1-linux64) (build 1.8.0_192-b01)
    • openHAB version: 2.3.0 Release Build
    • Z-wave/Zigbee Device: From lsusb: Cygnal Integrated Products, Inc. from udevadm:
      ATTRS{manufacturer}==“Silicon Labs” ATTRS{product}==“HubZ Smart Home Controller”
  • Issue of the topic:
    Fresh installation of OpenHAB from the Install guide and am unable to get the Zwave portion of this device visible.

    I’ve followed all the instructions with regard to updating the /etc/default/openhab2 file with the EXTRA_JAVA_OPTS as specified. Found I didn’t have librxtx-java installed, so installed that but no change. I’ve rebooted about 3,000 times now and disabled apparmor just to make sure it wasn’t blocking any access - no change there.

    OpenHAB runs as the openhab user/group with the following auxiliary groups:

$ id openhab
uid=999(openhab) gid=998(openhab) groups=998(openhab),5(tty),10(uucp),20(dialout)

Permissions of the /dev/ttyUSB devices are:

$ ls -al /dev/ttyUSB?
crw-rw---- 1 root dialout 188, 0 Nov 30 18:18 /dev/ttyUSB0
crw-rw---- 1 root dialout 188, 1 Nov 30 18:34 /dev/ttyUSB1

Runtime for Java:

openhab   5208  3.3 12.6 3630784 467100 ?      Ssl  18:24   0:40 /usr/bin/java -Dopenhab.home=/usr/share/openhab2 -Dopenhab.conf=/etc/openhab2 -Dopenhab.runtime=/usr/share/openhab2/runtime -Dopenhab.userdata=/var/lib/openhab2 -Dopenhab.logdir=/var/log/openhab2 -Dfelix.cm.dir=/var/lib/openhab2/config -Djetty.host=0.0.0.0 -Djetty.http.compliance=RFC2616 -Dorg.ops4j.pax.web.listening.addresses=0.0.0.0 -Dorg.osgi.service.http.port=8080 -Dorg.osgi.service.http.port.secure=8443 -Djava.awt.headless=true -XX:+UseG1GC -Dgnu.io.rxtx.SerialPorts=/dev/ttyUSB0:/dev/ttyUSB1 -Djava.endorsed.dirs=/usr/lib/jvm/zulu-8-amd64/jre/lib/endorsed:/usr/lib/jvm/zulu-8-amd64/lib/endorsed:/usr/share/openhab2/runtime/lib/endorsed -Djava.ext.dirs=/usr/lib/jvm/zulu-8-amd64/jre/lib/ext:/usr/lib/jvm/zulu-8-amd64/lib/ext:/usr/share/openhab2/runtime/lib/ext -Dkaraf.instances=/var/lib/openhab2/tmp/instances -Dkaraf.home=/usr/share/openhab2/runtime -Dkaraf.base=/var/lib/openhab2 -Dkaraf.data=/var/lib/openhab2 -Dkaraf.etc=/var/lib/openhab2/etc -Dkaraf.logs=/var/log/openhab2 -Dkaraf.restart.jvm.supported=true -Djava.io.tmpdir=/var/lib/openhab2/tmp -Djava.util.logging.config.file=/var/lib/openhab2/etc/java.util.logging.properties -Dkaraf.startLocalConsole=false -Dkaraf.startRemoteShell=true -classpath /usr/share/openhab2/runtime/lib/boot/org.apache.karaf.diagnostic.boot-4.1.5.jar:/usr/share/openhab2/runtime/lib/boot/org.apache.karaf.jaas.boot-4.1.5.jar:/usr/share/openhab2/runtime/lib/boot/org.apache.karaf.main-4.1.5.jar:/usr/share/openhab2/runtime/lib/boot/org.osgi.core-6.0.0.jar org.apache.karaf.main.Main

From that process:

-Dgnu.io.rxtx.SerialPorts=/dev/ttyUSB0:/dev/ttyUSB1

Choice snippets from the logs:

/var/log/openhab2/events.log:2018-11-30 18:24:36.524 [hingStatusInfoChangedEvent] - 'zwave:serial_zstick:52156442' changed from OFFLINE (COMMUNICATION_ERROR): Serial Error: Port /dev/ttyUSB0 does not exist to UNINITIALIZED
/var/log/openhab2/events.log:2018-11-30 18:24:50.316 [hingStatusInfoChangedEvent] - 'zwave:serial_zstick:52156442' changed from OFFLINE (BRIDGE_OFFLINE): Controller is offline to OFFLINE (COMMUNICATION_ERROR): Serial Error: Port /dev/ttyUSB0 does not exist


Also permissions from /run/lock (read those might need tweaking somewhere):

$ ls -al /run/lock/
total 0
drwxrwxrwt  4 root root   80 Nov 30 18:17 .
drwxr-xr-x 29 root root 1000 Nov 30 18:18 ..
drwx------  2 root root   40 Nov 30 18:17 lvm
drwxr-xr-x  2 root root   40 Nov 30 18:17 subsys

Verified the sticky bit permissions work in that director:

$ touch /run/lock/my-test-touch
$ ls -al /run/lock
total 0
drwxrwxrwt  4 root      root       100 Nov 30 18:49 .
drwxr-xr-x 29 root      root      1000 Nov 30 18:18 ..
drwx------  2 root      root        40 Nov 30 18:17 lvm
-rw-rw-r--  1 myuser    myuser       0 Nov 30 18:49 my-test-touch
drwxr-xr-x  2 root      root        40 Nov 30 18:17 subsys

Bundle information:

208 │ Active   │  80 │ 2.3.0                  │ ZigBee Binding
209 │ Active   │  80 │ 2.3.0                  │ ZigBee CC2531 Binding
210 │ Active   │  80 │ 2.3.0                  │ ZigBee Ember Binding
211 │ Active   │  80 │ 2.3.0                  │ ZigBee Telegesis Binding
212 │ Active   │  80 │ 2.3.0                  │ ZigBee XBee Binding
213 │ Active   │  80 │ 2.3.0                  │ ZWave Binding

Thing info:

openhab> things list
zwave:serial_zstick:52156442 (Type=Bridge, Status=OFFLINE (COMMUNICATION_ERROR): Serial Error: Port /dev/ttyUSB0 does not exist, Label=Z-Wave Serial Controller, Bridge=null)
network:pingdevice:192_168_7_55 (Type=Thing, Status=ONLINE, Label=Google Home Mini (Aiden's Room), Bridge=null)
network:pingdevice:192_168_7_53 (Type=Thing, Status=ONLINE, Label=Google Home (Kitchen), Bridge=null)
network:pingdevice:192_168_7_58 (Type=Thing, Status=ONLINE, Label=Google Home Mini (Garage), Bridge=null)
zigbee:coordinator_ember:e7f0cbe0 (Type=Bridge, Status=ONLINE, Label=Ember EM35x Coordinator, Bridge=null)
  • If logs where generated please post these here using code fences:
$ grep '11-30 18:5' /var/log/openhab2/*.log
/var/log/openhab2/events.log:2018-11-30 18:54:41.984 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_58' changed from ONLINE to UNINITIALIZED
/var/log/openhab2/events.log:2018-11-30 18:54:41.991 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_58' changed from UNINITIALIZED to UNINITIALIZED (HANDLER_MISSING_ERROR)
/var/log/openhab2/events.log:2018-11-30 18:54:41.997 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_55' changed from ONLINE to UNINITIALIZED
/var/log/openhab2/events.log:2018-11-30 18:54:42.005 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_55' changed from UNINITIALIZED to UNINITIALIZED (HANDLER_MISSING_ERROR)
/var/log/openhab2/events.log:2018-11-30 18:54:42.007 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_53' changed from ONLINE to UNINITIALIZED
/var/log/openhab2/events.log:2018-11-30 18:54:42.007 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_53' changed from UNINITIALIZED to UNINITIALIZED (HANDLER_MISSING_ERROR)
/var/log/openhab2/events.log:2018-11-30 18:54:42.010 [hingStatusInfoChangedEvent] - 'zigbee:coordinator_ember:e7f0cbe0' changed from ONLINE to UNINITIALIZED
/var/log/openhab2/events.log:2018-11-30 18:54:42.083 [hingStatusInfoChangedEvent] - 'zigbee:coordinator_ember:e7f0cbe0' changed from UNINITIALIZED to UNINITIALIZED (HANDLER_MISSING_ERROR)
/var/log/openhab2/events.log:2018-11-30 18:54:42.108 [hingStatusInfoChangedEvent] - 'zwave:serial_zstick:52156442' changed from OFFLINE (COMMUNICATION_ERROR): Serial Error: Port /dev/ttyUSB0 does not exist to UNINITIALIZED
/var/log/openhab2/events.log:2018-11-30 18:54:42.110 [hingStatusInfoChangedEvent] - 'zwave:serial_zstick:52156442' changed from UNINITIALIZED to UNINITIALIZED (HANDLER_MISSING_ERROR)
/var/log/openhab2/events.log:2018-11-30 18:54:53.136 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_55' changed from UNINITIALIZED to INITIALIZING
/var/log/openhab2/events.log:2018-11-30 18:54:53.213 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_55' changed from INITIALIZING to ONLINE
/var/log/openhab2/events.log:2018-11-30 18:54:53.247 [me.event.ThingUpdatedEvent] - Thing 'network:pingdevice:192_168_7_55' has been updated.
/var/log/openhab2/events.log:2018-11-30 18:54:53.252 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_53' changed from UNINITIALIZED to INITIALIZING
/var/log/openhab2/events.log:2018-11-30 18:54:53.316 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_53' changed from INITIALIZING to ONLINE
/var/log/openhab2/events.log:2018-11-30 18:54:53.330 [me.event.ThingUpdatedEvent] - Thing 'network:pingdevice:192_168_7_53' has been updated.
/var/log/openhab2/events.log:2018-11-30 18:54:53.337 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_58' changed from UNINITIALIZED to INITIALIZING
/var/log/openhab2/events.log:2018-11-30 18:54:53.401 [hingStatusInfoChangedEvent] - 'network:pingdevice:192_168_7_58' changed from INITIALIZING to ONLINE
/var/log/openhab2/events.log:2018-11-30 18:54:53.423 [me.event.ThingUpdatedEvent] - Thing 'network:pingdevice:192_168_7_58' has been updated.
/var/log/openhab2/events.log:2018-11-30 18:54:53.456 [hingStatusInfoChangedEvent] - 'zigbee:coordinator_ember:e7f0cbe0' changed from UNINITIALIZED to INITIALIZING
/var/log/openhab2/events.log:2018-11-30 18:54:53.473 [hingStatusInfoChangedEvent] - 'zigbee:coordinator_ember:e7f0cbe0' changed from INITIALIZING to UNKNOWN
/var/log/openhab2/events.log:2018-11-30 18:54:55.809 [hingStatusInfoChangedEvent] - 'zigbee:coordinator_ember:e7f0cbe0' changed from UNKNOWN to OFFLINE: Failed to startup ZigBee transport layer
/var/log/openhab2/events.log:2018-11-30 18:54:56.696 [hingStatusInfoChangedEvent] - 'zwave:serial_zstick:52156442' changed from UNINITIALIZED to INITIALIZING
/var/log/openhab2/events.log:2018-11-30 18:54:56.705 [hingStatusInfoChangedEvent] - 'zwave:serial_zstick:52156442' changed from INITIALIZING to OFFLINE (BRIDGE_OFFLINE): Controller is offline
/var/log/openhab2/events.log:2018-11-30 18:54:56.715 [hingStatusInfoChangedEvent] - 'zwave:serial_zstick:52156442' changed from OFFLINE (BRIDGE_OFFLINE): Controller is offline to OFFLINE (COMMUNICATION_ERROR): Serial Error: Port /dev/ttyUSB0 does not exist
/var/log/openhab2/events.log:2018-11-30 18:54:58.370 [me.event.ThingUpdatedEvent] - Thing 'network:pingdevice:192_168_7_55' has been updated.
/var/log/openhab2/events.log:2018-11-30 18:54:58.425 [me.event.ThingUpdatedEvent] - Thing 'network:pingdevice:192_168_7_53' has been updated.
/var/log/openhab2/events.log:2018-11-30 18:54:58.528 [me.event.ThingUpdatedEvent] - Thing 'network:pingdevice:192_168_7_58' has been updated.
/var/log/openhab2/events.log:2018-11-30 18:55:02.571 [hingStatusInfoChangedEvent] - 'zigbee:coordinator_ember:e7f0cbe0' changed from OFFLINE: Failed to startup ZigBee transport layer to ONLINE
/var/log/openhab2/events.log:2018-11-30 18:55:02.584 [nt.FirmwareStatusInfoEvent] - Firmware status of thing zigbee:coordinator_ember:e7f0cbe0 changed to UNKNOWN.
/var/log/openhab2/events.log:2018-11-30 18:55:02.942 [me.event.ThingUpdatedEvent] - Thing 'zigbee:coordinator_ember:e7f0cbe0' has been updated.
/var/log/openhab2/openhab.log:2018-11-30 18:54:05.816 [INFO ] [basic.internal.servlet.WebAppServlet] - Stopped Basic UI
/var/log/openhab2/openhab.log:2018-11-30 18:54:42.108 [INFO ] [ing.zwave.handler.ZWaveSerialHandler] - Stopped ZWave serial handler
/var/log/openhab2/openhab.log:2018-11-30 18:54:42.359 [INFO ] [arthome.ui.paper.internal.PaperUIApp] - Stopped Paper UI
/var/log/openhab2/openhab.log:2018-11-30 18:54:42.366 [INFO ] [panel.internal.HABPanelDashboardTile] - Stopped HABPanel
/var/log/openhab2/openhab.log:2018-11-30 18:54:42.372 [INFO ] [er.internal.HomeBuilderDashboardTile] - Stopped Home Builder
/var/log/openhab2/openhab.log:2018-11-30 18:54:42.382 [INFO ] [.dashboard.internal.DashboardService] - Stopped Dashboard
/var/log/openhab2/openhab.log:2018-11-30 18:54:47.365 [INFO ] [er.internal.HomeBuilderDashboardTile] - Started Home Builder at /homebuilder
/var/log/openhab2/openhab.log:2018-11-30 18:54:48.268 [WARN ] [g.eclipse.smarthome.core.net.NetUtil] - Found multiple local interfaces - ignoring 172.17.0.1
/var/log/openhab2/openhab.log:2018-11-30 18:54:48.285 [WARN ] [g.eclipse.smarthome.core.net.NetUtil] - Found multiple local interfaces - ignoring 192.168.7.62
/var/log/openhab2/openhab.log:2018-11-30 18:54:48.329 [INFO ] [.dashboard.internal.DashboardService] - Started Dashboard at http://172.30.32.1:8080
/var/log/openhab2/openhab.log:2018-11-30 18:54:48.329 [INFO ] [.dashboard.internal.DashboardService] - Started Dashboard at https://172.30.32.1:8443
/var/log/openhab2/openhab.log:2018-11-30 18:54:52.614 [INFO ] [thome.model.lsp.internal.ModelServer] - Started Language Server Protocol (LSP) service on port 5007
/var/log/openhab2/openhab.log:2018-11-30 18:54:53.231 [INFO ] [ternal.dhcp.DHCPPacketListenerServer] - DHCP request packet listener online
/var/log/openhab2/openhab.log:2018-11-30 18:54:54.636 [INFO ] [basic.internal.servlet.WebAppServlet] - Started Basic UI at /basicui/app
/var/log/openhab2/openhab.log:2018-11-30 18:54:54.676 [INFO ] [arthome.ui.paper.internal.PaperUIApp] - Started Paper UI at /paperui
/var/log/openhab2/openhab.log:2018-11-30 18:54:54.693 [INFO ] [panel.internal.HABPanelDashboardTile] - Started HABPanel at /habpanel
/var/log/openhab2/openhab.log:2018-11-30 18:54:56.708 [INFO ] [ing.zwave.handler.ZWaveSerialHandler] - Connecting to serial port '/dev/ttyUSB0'

Here’s a link that might help.

I’m a total dumbass!

I figured it out. I was playing with HASS and forgot to disable the supervisor that starts up with the system boot. Disabled that and everything is working fine now!

Thanks for the reply though @H102

1 Like

I think we all have these moments from time to time.:rofl:

Glad you got it fixed.:sunglasses:

1 Like