[SOLVED] Symlinks not working

Hey all,

I organized my symlinks for the use in openhab according to this tutorial:
Tutorial

but unfortunately, the symlinks are not visible in openhab, see the following screenshot:

My /etc/udev/rules.d/99-usb-serial.rules looks like that:

SUBSYSTEM=="tty", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="204b", SYMLINK+="ttyUSB-maxcul", GROUP="dialout", MODE="0666"
SUBSYSTEM=="tty", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", ATTRS{serial}=="2701C904", SYMLINK+="ttyUSB-jeelink", GROUP="dialout", MODE="0666"
SUBSYSTEM=="tty", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", ATTRS{serial}=="AI03D96I", SYMLINK+="ttyUSB-amber", GROUP="dialout", MODE="0666"
SUBSYSTEM=="tty", ATTRS{idVendor}=="0658", ATTRS{idProduct}=="0200", SYMLINK+="ttyUSB-zwave", GROUP="dialout", MODE="0666"

ls /dev/tty* result is here (meaning that the symlinks are created):

/dev/tty    /dev/tty13  /dev/tty19  /dev/tty24  /dev/tty3   /dev/tty35  /dev/tty40  /dev/tty46  /dev/tty51  /dev/tty57  /dev/tty62    /dev/ttyACM1       /dev/ttyUSB-jeelink
/dev/tty0   /dev/tty14  /dev/tty2   /dev/tty25  /dev/tty30  /dev/tty36  /dev/tty41  /dev/tty47  /dev/tty52  /dev/tty58  /dev/tty63    /dev/ttyAMA0       /dev/ttyUSB-maxcul
/dev/tty1   /dev/tty15  /dev/tty20  /dev/tty26  /dev/tty31  /dev/tty37  /dev/tty42  /dev/tty48  /dev/tty53  /dev/tty59  /dev/tty7     /dev/ttyprintk     /dev/ttyUSB-zwave
/dev/tty10  /dev/tty16  /dev/tty21  /dev/tty27  /dev/tty32  /dev/tty38  /dev/tty43  /dev/tty49  /dev/tty54  /dev/tty6   /dev/tty8     /dev/ttyUSB0
/dev/tty11  /dev/tty17  /dev/tty22  /dev/tty28  /dev/tty33  /dev/tty39  /dev/tty44  /dev/tty5   /dev/tty55  /dev/tty60  /dev/tty9     /dev/ttyUSB1
/dev/tty12  /dev/tty18  /dev/tty23  /dev/tty29  /dev/tty34  /dev/tty4   /dev/tty45  /dev/tty50  /dev/tty56  /dev/tty61  /dev/ttyACM0  /dev/ttyUSB-amber

And in /etc/default/openhab2` i created the following entry:

EXTRA_JAVA_OPTS="-Dgnu.io.rxtx.SerialPorts=/dev/ttyUSB-maxcul:/dev/ttyUSB-jeelink:/dev/ttyUSB-zwave:/dev/ttyUSB-amber"

So i dont know where there is a mistake? Any ideas?

no ideas here?

It seems that, i dont know why, the permissions of the symlinks are not correctly set, even if (see above), the /etc/udev/rules.d/99-usb-serial.rules file contains the GROUP="dialout" information.

When i run ls -al /dev/ttyACM0 i got:

crw-rw-rw- 1 root dialout 166, 0 Oct  6 18:56 /dev/ttyACM0

But when i run ls -al /dev/ttyUSB-zwave i got:

lrwxrwxrwx 1 root root 7 Oct  6 18:49 /dev/ttyUSB-zwave -> ttyACM0

Can someone tell me why the /dev/ttyUSB-zwave is not in the dialout group?

i found the problem.
I manually installed this binding here: [ New Binding: Wireless M-Bus / Techem heat cost allocators](New Binding: Wireless M-Bus / Techem heat cost allocators)

At the moment, i dont know why, but this binding affects my configuration of openhab, meaning that no binding did work which needed a serial port.

after having deinstalled the binding again, everything works again.

Any ideas for the following issue?

After having updated to the newestr OpenHab release, my simlinks are not shown anymore.
No i had to choose between the following options:

grafik

But as written above, my simlinks are as follows:

ttyUSB-maxcul
ttyUSB-jeelink
ttyUSB-amber
ttyUSB-zwave

no one an idea? it seems that the updated version of openhab has some issues with simlinks?

for those who have also problems like me, the solution is, after an update of openhab, the following file is overwritten by the openhab update routine.

/etc/default/openhab2

bring it back to the origin version, update your EXTRA_JAVA_OPTS settings and everything is ok again.

1 Like

EXTRA_JAVA_OPTS="-Dgnu.io.rxtx.SerialPorts=/dev/ttyUSB-amber:/dev/ttyUSB-jeelink:/dev/ttyUSB-maxcul:/dev/ttyUSB-zigbee:/dev/ttyUSB-zwave"
EXTRA_JAVA_OPTS="-Xms250m -Xmx350m"

1 Like