Configuring serial ports to keep their ttys* location

Configuring serial ports to keep their ttys* location

Dotan Cohen dotancohen at gmail.com
Tue Jul 13 09:59:28 IDT 2010


On Ubuntu Linux we have many serial devices connected, they show in
the udev log like this:

KERNEL[1279002550.149087] add
/devices/pci0000:00/0000:00:14.4/0000:03:06.0/tty/ttyS4 (tty)
UDEV_LOG=3
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:14.4/0000:03:06.0/tty/ttyS4
SUBSYSTEM=tty
DEVNAME=ttyS4
SEQNUM=1212
MAJOR=4
MINOR=68

KERNEL[1279002550.149102] add
/devices/pci0000:00/0000:00:14.4/0000:03:06.0/tty/ttyS5 (tty)
UDEV_LOG=3
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:14.4/0000:03:06.0/tty/ttyS5
SUBSYSTEM=tty
DEVNAME=ttyS5
SEQNUM=1213
MAJOR=4
MINOR=69

KERNEL[1279002550.149116] add
/devices/pci0000:00/0000:00:14.4/0000:03:06.0/tty/ttyS6 (tty)
UDEV_LOG=3
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:14.4/0000:03:06.0/tty/ttyS6
SUBSYSTEM=tty
DEVNAME=ttyS6
SEQNUM=1214
MAJOR=4
MINOR=70


The SEQNUM is _not_ constant from boot to boot, therefore configuring
the mount point per SEQNUM does not work. I am not sure if the
KERNEL[1279002550.*] number is unique, is it supposed to be? If so,
which udev rule would configure the mount points to be as they are now
on next boot as well?

Thanks.


-- 
Dotan Cohen

http://gibberish.co.il
http://what-is-what.com



More information about the Linux-il mailing list