Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 416439 - dev-java/rxtx cannot connect to serial port
Summary: dev-java/rxtx cannot connect to serial port
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Java (show other bugs)
Hardware: AMD64 Linux
: Normal normal
Assignee: Java team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-17 21:43 UTC by Florian Kluge
Modified: 2023-01-29 19:48 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Kluge 2012-05-17 21:43:00 UTC
I just installed the Arduino IDE which is using the rxtx packet. During start, the following error message is thrown several times:

check_group_uucp(): error testing lock file creation Error details: Permission denied check_lock_status: No permission to create lock file.
please see: How can I use Lock Files with rxtx? in INSTALL

This problems stems from the rxtx package trying to create lock files in /var/lock. It can be resolved by changing the access privileges (as root):

$ chgrp uucp /var/lock/
$ chmod g+w /var/lock/

Another solution might be to build rxtx without using lockfiles (see http://rxtx.qbang.org/wiki/index.php/Trouble_shooting#How_can_I_use_Lock_Files_with_rxtx.3F), but I haven't tested it.
Comment 1 Ralph Sennhauser (RETIRED) gentoo-dev 2012-05-18 20:08:53 UTC
(In reply to comment #0)
> I just installed the Arduino IDE which is using the rxtx packet. During
> start, the following error message is thrown several times:
> 
> check_group_uucp(): error testing lock file creation Error details:
> Permission denied check_lock_status: No permission to create lock file.
> please see: How can I use Lock Files with rxtx? in INSTALL
> 
> This problems stems from the rxtx package trying to create lock files in
> /var/lock. It can be resolved by changing the access privileges (as root):
> 
> $ chgrp uucp /var/lock/
> $ chmod g+w /var/lock/
> 

/var/lock is supposed to belong to uucp, what was the group set to before? I can't help but think that systemd is the culprit here. Are you using systemd by chance?
Comment 2 Florian Kluge 2012-05-19 11:31:08 UTC
(In reply to comment #1)
> /var/lock is supposed to belong to uucp, what was the group set to before? I
> can't help but think that systemd is the culprit here. Are you using systemd
> by chance?

Ok, now that's something new for me. But no, systemd is not installed on my computer.
Comment 3 Manuel Rüger (RETIRED) gentoo-dev 2012-07-30 07:56:59 UTC
Which arduino version did you try?
Comment 4 Florian Kluge 2012-07-30 18:07:11 UTC
(In reply to comment #3)
> Which arduino version did you try?

Currently version 1.0 is installed on my system, but I'm not sure whether there was an update during the last weeks.
Comment 5 Tom Wijsman (TomWij) (RETIRED) gentoo-dev 2013-06-06 16:19:42 UTC
I can confirm that on systemd this is set to root.

 $ stat /var/lock | grep Gid
Access: (0777/lrwxrwxrwx)  Uid: (    0/    root)   Gid: (    0/    root)

When I was working on SunSPOTs I just ran things as root because the uucp suggestion I found didn't work, but I didn't realize at that point it's just because this directory had an incorrect group set.

Not sure why this is the way it is on systemd, probably an incorrect unit file?

CC-ing systemd@g.o them so they are aware, can look into it and explain it.

Florian: Which init system are you running?

sera: Do you know where the group permission comes from for OpenRC?
Comment 6 Florian Kluge 2013-06-06 17:40:01 UTC
(In reply to Tom Wijsman (TomWij) from comment #5)
> Florian: Which init system are you running?

I'm running openrc.
Comment 7 Patrice Clement (RETIRED) gentoo-dev 2016-10-05 08:28:31 UTC
Hi, is it still an issue? Thanks for letting us know.
Comment 8 Florian Kluge 2016-10-05 19:02:47 UTC
After I applied the chgrp/chmod, everything worked, and I have the whole system running since then. Privileges are as follows:

$ ll /var/lock
lrwxrwxrwx 1 root root 9 23. Nov 2012  /var/lock -> /run/lock

$ ll -d /run/lock/
drwxrwxr-x 4 root uucp 100  5. Okt 21:00 /run/lock/

Arduino is working fine so far.