USB Serial passthrough (Arduino) : Error: not a directory


(Tony Ducrocq) #1

Hello, I would like to use an bind an Arduino serial interface ( /dev/ttyACM0 ) to a LXD container. I have successfully done the pass-through while the container is running with this command :

sudo lxc config device add dev ttyACM0 unix-char path=/dev/ttyACM0 mode=0777 required=false

I do not care about the permissions yet but I plan to map the dialout group when it will work fine. By the way this works and I can read and write the serial interface inside the container. The problem is if I stop the container I cannot start it again because I get the error :

$ sudo lxc start dev
Error: not a directory
Try lxc info --show-log dev for more info

The info command is not really helpful by the way :

~$ sudo lxc info --show-log dev
Name: dev
Remote: unix://
Architecture: x86_64
Created: 2018/01/02 06:36 UTC
Status: Stopped
Type: persistent
Profiles: default
Log:
lxc 20180410192959.939 WARN lxc_conf - conf.c:lxc_map_ids:2831 - newuidmap binary is missing
lxc 20180410192959.939 WARN lxc_conf - conf.c:lxc_map_ids:2837 - newgidmap binary is missing
lxc 20180410192959.941 WARN lxc_conf - conf.c:lxc_map_ids:2831 - newuidmap binary is missing
lxc 20180410192959.941 WARN lxc_conf - conf.c:lxc_map_ids:2837 - newgidmap binary is missing
lxc 20180410193114.606 WARN lxc_conf - conf.c:lxc_map_ids:2831 - newuidmap binary is missing
lxc 20180410193114.606 WARN lxc_conf - conf.c:lxc_map_ids:2837 - newgidmap binary is missing

Maybe it’s a bug and I should fill one? Maybe I miss something? Thank you for helping!


(Stéphane Graber) #2

@brauner any idea? I wonder where the not a directory came from here.