Did you reboot or rerun the udev rules? This should work…
SUBSYSTEM=="tty", ATTRS{idVendor}=="0451", ATTRS{idProduct}=="16a8", ATTRS{serial}=="__0X00124B000E896C97", SYMLINK+="ttyUSB_cc2531", GROUP="dialout", MODE="0666"
You can test your udev rules running against a specific device, before actually running them, by using…
udevadm test `udevadm info -a /dev/ttyUSB_cc2531| grep "looking at device"| sed "s/looking at device '//"| sed "s/'://"`
The symlink won’t be put into the group, but the target of the symlink will be…
[root@fedora01 /]# ls -la /dev/ |grep ttyUSB
crw-rw-rw- 1 root dialout 188, 0 Aug 12 17:44 ttyUSB0
crw-rw-rw- 1 root dialout 188, 1 Aug 12 17:44 ttyUSB1
lrwxrwxrwx 1 root root 7 Aug 10 15:30 ttyUSB-5 -> ttyUSB0
lrwxrwxrwx 1 root root 7 Aug 10 15:30 ttyUSB-55 -> ttyUSB1
What do you see when you run (making sure you openhab account is in dialout and tty)…
# id openhab
uid=964(openhab) gid=963(openhab) groups=963(openhab),5(tty),18(dialout)
If you want to keep the nonstandard name, you may also want to try putting the EXTRA_JAVA_OPTS at the top of start.sh, in case the way you are doing it isnt working. This is what I have for setting up JSR223…
export EXTRA_JAVA_OPTS="-Xbootclasspath/a:/opt/openhab2/conf/jython/jython-standalone-2.7.0.jar -Dpython.home=/opt/openhab2/conf/jython -Dpython.path=/opt/openhab2/conf/lib"
A random thing to check when this is happening, is to look into /var/lock and see if you have a LCK..ttyUSB_cc2531
file. You should, if everything is working OK. I had been running OH as root, but when I changed it to an openhab account, I found that directory did not have permissions to allow the openhab account to write the lock file, and found errors showing this in journalctl…
Aug 12 18:35:15 fedora01 start.sh[7448]: Launching the openHAB runtime...
Aug 12 18:36:17 fedora01 start.sh[7448]: check_group_uucp(): error testing lock file creation Error details:Permission deniedcheck_lock_status: No permission to create lock file.
Aug 12 18:36:17 fedora01 start.sh[7448]: RXTX fhs_lock() Error: opening lock file: /var/lock/LCK..ttyUSB-55: Permission denied. FAILED TO OPEN: No such file or directory
This is a complete mystery that I’m currently looking into, but I’ve temporarily given rwx to everyone until I can figure it out. I’m also using snapshot 1325, so it may be related to some of the recent ESH changes or an updated nrjavaserial.