Skip to content

Unable to access serial device in Docker container #2511

@sidmodi-mw

Description

@sidmodi-mw

Describe the bug

OrbStack 2.2.1 USB serial device works in an OrbStack Linux machine, but opening the same forwarded serial device from a Docker container crashes userspace tools with "*** stack smashing detected ***".

To Reproduce

Device:

/dev/tty.usbmodem11101

Works in OrbStack VM:

stty -F /dev/tty.usbmodem11101 -a

Fails in Docker:

docker run --rm --privileged --device=/dev/tty.usbmodem11101:/dev/ACM0 ubuntu:24.04 bash -lc 'uname -m; ls -l /dev/ACM0; stty -F /dev/ACM0 -a'

Expected behavior

stty prints serial settings.

Diagnostic report (REQUIRED)

Output from failing docker run command:

aarch64
crw-rw---- 1 root dialout 240, 0 Jun  5 08:44 /dev/ACM0
*** stack smashing detected ***: terminated

Screenshots and additional context (optional)

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    t/bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions