Table of Contents

Serial Interface

Router Setting

Please change the mode of the serial Interface you want to use to “none”

lxc settings

The Serial intefaces is already available for the lxc containter and needed to be add as a filesystem node in the guest.

Before you create the node you need to get the MAJOR and MINOR Number which can seen in the /dev directory with the ls -al | grep ttyS in the router root shell.

USER
crw-rw-rw- 1 root root 4, 64 Sep 30 15:59 /dev/ttyS0 crw-rw-rw- 1 root root 4, 65 Jan 1 1970 /dev/ttyS1 crw-rw-rw- 1 root root 4, 66 Jan 1 1970 /dev/ttyS2 crw-rw-rw- 1 root root 4, 67 Jan 1 1970 /dev/ttyS3 crw-rw-rw- 1 root root 4, 68 Jan 1 1970 /dev/ttyS4 crw-rw-rw- 1 root root 4, 69 Jan 1 1970 /dev/ttyS5 crw-rw-rw- 1 root root 4, 70 Jan 1 1970 /dev/ttyS6 crw-rw-rw- 1 root root 4, 71 Jan 1 1970 /dev/ttyS7

then in the lxc container you can create the the device with the commands

ROOT
mknod /dev/ttyHostSerial0 c 4 64 mknod /dev/ttyHostSerial1 c 4 65

and then access the interface with microcom for example

ROOT
microcom -s 115200 -p /dev/ttyHostSerial0 microcom -s 115200 -p /dev/ttyHostSerial1