0

When my machine reboots it's a lottery which USB devices get assigned to which ttyUSBn.

Therefore I have to rename /etc/ppp/options.ttyUSB0 periodically.

I've tried /etc/ppp/options.usb-FTDI_FT232R_USB_UART_00000000-if00-port0 but that doesn't work.

Is there a way of doing it?

All I can think of is a cron @reboot job for root

#!/bin/sh
tty=$(ls -l /dev/serial/by-id | grep FTDI | cut -d '/' -f 3)
cp /etc/ppp/options.usb-FTDI_FT232R_USB_UART_00000000-if00-port0 "/dev/ppp/options.$(tty)"
5
  • (ppp in 2023?) Anyway... shouldn't udev do this for you? Commented Mar 20, 2023 at 11:58
  • 1
    It's for my 1993 Mac LCIII. Commented Mar 20, 2023 at 12:06
  • USB in a computer made before USB existed? Commented Mar 20, 2023 at 12:10
  • I would assume judicious use of some udev rules would work. Commented Mar 20, 2023 at 13:39
  • I don't know what udev is so I'll go with the cron script; never mind. Commented Mar 20, 2023 at 15:38

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.