2

I have a USB device with a serial interface that masquerades as a USB modem. It gets assigned to /dev/ttyACM0, and udev rules set the group and mode as noted:

amm@AMM:~$ ls -l /dev/ttyACM0 
crw-rw----+ 1 root plugdev 166, 0 May 12 20:34 /dev/ttyACM0

My user is in the appropriate group:

amm@AMM:~$ groups
amm sudo plugdev

Yet this user cannot connect to the device without using sudo

amm@AMM:~$ screen /dev/ttyACM0 115200
[screen is terminating]
amm@AMM:~$ sudo !!
sudo screen /dev/ttyACM0 115200
[detached from 21073.pts-0.AMM]

What doesn't this user have access? This is arm64 linux running on (very) custom hardware, but I can connect with root access, so clearly the hardware works.

For reference, here's the udevadm test output:

amm@AMM:~$ sudo /sbin/udevadm test /devices/soc/6a00000.ssusb/6a00000.dwc3/xhci-hcd.0.auto/usb1/1-1/1-1.5/1-1.5:1.1/tty/ttyACM0
calling: test
version 232
This program is for debugging only, it does not run any program
specified by a RUN key. It may show incorrect results, because
some values may be different, or not available at a simulation run.

=== trie on-disk ===
tool version:          232
file size:         8669202 bytes
header size             80 bytes
strings            1850786 bytes
nodes              6818336 bytes
Load module index
Found container virtualization none
timestamp of '/etc/systemd/network' changed
timestamp of '/usr/lib/systemd/network' changed
timestamp of '/lib/systemd/network' changed
Parsed configuration file /lib/systemd/network/99-default.link
Created link configuration context.
timestamp of '/etc/udev/rules.d' changed
Reading rules file: /lib/udev/rules.d/39-usbmuxd.rules
Reading rules file: /lib/udev/rules.d/50-firmware.rules
Reading rules file: /lib/udev/rules.d/50-udev-default.rules
Reading rules file: /lib/udev/rules.d/55-dm.rules
Reading rules file: /lib/udev/rules.d/60-block.rules
Reading rules file: /lib/udev/rules.d/60-cdrom_id.rules
Reading rules file: /lib/udev/rules.d/60-crda.rules
Reading rules file: /lib/udev/rules.d/60-drm.rules
Reading rules file: /lib/udev/rules.d/60-evdev.rules
Reading rules file: /lib/udev/rules.d/60-fuse.rules
Reading rules file: /lib/udev/rules.d/60-libgphoto2-6.rules
Reading rules file: /lib/udev/rules.d/60-libsane.rules
Reading rules file: /lib/udev/rules.d/60-openocd.rules
Reading rules file: /lib/udev/rules.d/60-persistent-alsa.rules
Reading rules file: /lib/udev/rules.d/60-persistent-input.rules
Reading rules file: /lib/udev/rules.d/60-persistent-storage-dm.rules
Reading rules file: /lib/udev/rules.d/60-persistent-storage-tape.rules
Reading rules file: /lib/udev/rules.d/60-persistent-storage.rules
Reading rules file: /lib/udev/rules.d/60-persistent-v4l.rules
Reading rules file: /lib/udev/rules.d/60-serial.rules
Reading rules file: /lib/udev/rules.d/64-btrfs.rules
Reading rules file: /lib/udev/rules.d/64-xorg-xkb.rules
Reading rules file: /lib/udev/rules.d/65-libwacom.rules
Reading rules file: /lib/udev/rules.d/69-cd-sensors.rules
Reading rules file: /lib/udev/rules.d/69-wacom.rules
Reading rules file: /lib/udev/rules.d/70-debian-uaccess.rules
Reading rules file: /lib/udev/rules.d/70-mouse.rules
Reading rules file: /etc/udev/rules.d/70-persistent-net.rules
Reading rules file: /lib/udev/rules.d/70-power-switch.rules
Reading rules file: /lib/udev/rules.d/70-touchpad.rules
Reading rules file: /lib/udev/rules.d/70-uaccess.rules
Reading rules file: /lib/udev/rules.d/71-seat.rules
Reading rules file: /lib/udev/rules.d/73-seat-late.rules
Reading rules file: /lib/udev/rules.d/73-special-net-names.rules
Reading rules file: /lib/udev/rules.d/73-usb-net-by-mac.rules
Reading rules file: /lib/udev/rules.d/75-net-description.rules
Reading rules file: /lib/udev/rules.d/75-probe_mtd.rules
Reading rules file: /lib/udev/rules.d/78-sound-card.rules
Reading rules file: /lib/udev/rules.d/80-debian-compat.rules
Reading rules file: /lib/udev/rules.d/80-drivers.rules
Reading rules file: /lib/udev/rules.d/80-ifupdown.rules
Reading rules file: /lib/udev/rules.d/80-libinput-device-groups.rules
Reading rules file: /lib/udev/rules.d/80-net-setup-link.rules
Reading rules file: /lib/udev/rules.d/80-udisks2.rules
Reading rules file: /lib/udev/rules.d/85-hwclock.rules
Reading rules file: /lib/udev/rules.d/85-regulatory.rules
Reading rules file: /lib/udev/rules.d/90-libinput-model-quirks.rules
Reading rules file: /lib/udev/rules.d/90-pulseaudio.rules
Reading rules file: /lib/udev/rules.d/95-cd-devices.rules
Reading rules file: /lib/udev/rules.d/95-upower-csr.rules
Reading rules file: /lib/udev/rules.d/95-upower-hid.rules
Reading rules file: /lib/udev/rules.d/95-upower-wup.rules
Reading rules file: /lib/udev/rules.d/97-hid2hci.rules
Reading rules file: /etc/udev/rules.d/99-spidev-open.rules
Reading rules file: /lib/udev/rules.d/99-systemd.rules
rules contain 196608 bytes tokens (16384 * 12 bytes), 22832 bytes strings
11664 strings (98682 bytes), 9646 de-duplicated (77869 bytes), 2019 trie nodes used
GROUP 20 /lib/udev/rules.d/50-udev-default.rules:26
GROUP 46 /lib/udev/rules.d/60-openocd.rules:132
MODE 0660 /lib/udev/rules.d/60-openocd.rules:132
IMPORT builtin 'usb_id' /lib/udev/rules.d/60-serial.rules:8
/sys/devices/soc/6a00000.ssusb/6a00000.dwc3/xhci-hcd.0.auto/usb1/1-1/1-1.5/1-1.5:1.1: if_class 2 protocol 0
IMPORT builtin 'hwdb' /lib/udev/rules.d/60-serial.rules:8
IMPORT builtin 'path_id' /lib/udev/rules.d/60-serial.rules:15
LINK 'serial/by-path/platform-xhci-hcd.0.auto-usb-0:1.5:1.1' /lib/udev/rules.d/60-serial.rules:16
IMPORT builtin skip 'usb_id' /lib/udev/rules.d/60-serial.rules:19
LINK 'serial/by-id/usb-ARM_DAPLink_CMSIS-DAP_0311000032254e4500518006aebb0014bbf1000097969900-if01' /lib/udev/rules.d/60-serial.rules:23
RUN 'uaccess' /lib/udev/rules.d/73-seat-late.rules:15
handling device node '/dev/ttyACM0', devnum=c166:0, mode=0660, uid=0, gid=46
preserve permissions /dev/ttyACM0, 020660, uid=0, gid=46
preserve already existing symlink '/dev/char/166:0' to '../ttyACM0'
found 'c166:0' claiming '/run/udev/links/\x2fserial\x2fby-id\x2fusb-ARM_DAPLink_CMSIS-DAP_0311000032254e4500518006aebb0014bbf1000097969900-if01'
creating link '/dev/serial/by-id/usb-ARM_DAPLink_CMSIS-DAP_0311000032254e4500518006aebb0014bbf1000097969900-if01' to '/dev/ttyACM0'
preserve already existing symlink '/dev/serial/by-id/usb-ARM_DAPLink_CMSIS-DAP_0311000032254e4500518006aebb0014bbf1000097969900-if01' to '../../ttyACM0'
found 'c166:0' claiming '/run/udev/links/\x2fserial\x2fby-path\x2fplatform-xhci-hcd.0.auto-usb-0:1.5:1.1'
creating link '/dev/serial/by-path/platform-xhci-hcd.0.auto-usb-0:1.5:1.1' to '/dev/ttyACM0'
preserve already existing symlink '/dev/serial/by-path/platform-xhci-hcd.0.auto-usb-0:1.5:1.1' to '../../ttyACM0'
created db file '/run/udev/data/c166:0' for '/devices/soc/6a00000.ssusb/6a00000.dwc3/xhci-hcd.0.auto/usb1/1-1/1-1.5/1-1.5:1.1/tty/ttyACM0'
ACTION=add
DEVLINKS=/dev/serial/by-path/platform-xhci-hcd.0.auto-usb-0:1.5:1.1 /dev/serial/by-id/usb-ARM_DAPLink_CMSIS-DAP_0311000032254e4500518006aebb0014bbf1000097969900-if01
DEVNAME=/dev/ttyACM0
DEVPATH=/devices/soc/6a00000.ssusb/6a00000.dwc3/xhci-hcd.0.auto/usb1/1-1/1-1.5/1-1.5:1.1/tty/ttyACM0
ID_BUS=usb
ID_FOR_SEAT=tty-platform-xhci-hcd_0_auto-usb-0_1_5_1_1
ID_MODEL=DAPLink_CMSIS-DAP
ID_MODEL_ENC=DAPLink\x20CMSIS-DAP
ID_MODEL_FROM_DATABASE=LPC1768
ID_MODEL_ID=0204
ID_PATH=platform-xhci-hcd.0.auto-usb-0:1.5:1.1
ID_PATH_TAG=platform-xhci-hcd_0_auto-usb-0_1_5_1_1
ID_REVISION=1000
ID_SERIAL=ARM_DAPLink_CMSIS-DAP_0311000032254e4500518006aebb0014bbf1000097969900
ID_SERIAL_SHORT=0311000032254e4500518006aebb0014bbf1000097969900
ID_TYPE=generic
ID_USB_CLASS_FROM_DATABASE=Miscellaneous Device
ID_USB_DRIVER=cdc_acm
ID_USB_INTERFACES=:080650:030000:020201:0a0000:
ID_USB_INTERFACE_NUM=01
ID_USB_PROTOCOL_FROM_DATABASE=Interface Association
ID_VENDOR=ARM
ID_VENDOR_ENC=ARM
ID_VENDOR_FROM_DATABASE=NXP
ID_VENDOR_ID=0d28
MAJOR=166
MINOR=0
SUBSYSTEM=tty
TAGS=:uaccess:seat:systemd:
USEC_INITIALIZED=138162670
run: 'uaccess'
Unload module index
Unloaded link configuration context.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.