/dev/modem symlink gets wiped out on boot

Derek Broughton news at pointerstop.ca
Sat Nov 12 20:36:06 UTC 2005


D.Personne wrote:

> Le samedi 12 novembre 2005 à 11:48 -0500, stan a écrit :
>> I've just mamnaged to get my winmodem working using the ltmodem kernel
>> modules.
>> 
>> Only one remaining problem. The actual nevice node is /dev/ttyLM0, and
>> when I create a symbolic link for /dev/modem to it, this is not there
>> after I reboot the machine.
>> 
>> Why does this get removed, and how can I fix this?
> 
> Hi,
> Try this:
> 
> write a script (first line =>   #!/bin/sh
> then next line =>  symbolic linking)
> and put it in the /etc/init.d/ using update-rc.d
> 

That's the hard way to do the job.  

First make sure udev is installed.  Then add something like 
KERNEL=="ttyLM0", SYMLINK+="modem"

in /etc/udev/rules.d/15local.rules

(There's no real requirement for the name of that file, except that it ends
in .rules).

The answer to OP's question of "why" it gets removed is that all /dev/ names
are temporary, and are recreated at boot time (actually at the time their
modules are inserted into the kernel) by udev, so the correct place to set
symlinks is always in udev.
-- 
derek





More information about the ubuntu-users mailing list