device id question (usb and scsi)

Ryan Sommers ryans at
Thu Jan 20 05:24:30 PST 2005

Bram Van Steenlandt wrote:
> Hi,
> I've been having some problems with the following:
> ex1: I have two scsi scanners and I use sane to scan all works well my 
> two scanners are /dev/pass0 and /dev/pass1 however when one of them is 
> turned of the device are renumbered (wich is a problem because then I 
> have to change the sane configuration files)
> ex2: Same thing as above happens with usb printer, I work with cups and 
> printers get mixed from the moment you leave one of.
> I have a support pack for cups and they tell my there is no other 
> solution then to move to linux or osx because they have device id 
> numbers (they save the number kinda like a dhcp server and fixed ip 
> adresses). Or that I have to wait untill freebsd implements this.
> I am a very FreeBSD minded person (but also a newbie) and I find it very 
> hard to believe that such an advanced OS does not have some solution for 
> this.
> So if anybody has any hints or solutions please send them.

The problem is that devfs automatically assigns numbers based on when 
devices appear. In most cases this is a Godsend for system admins. In 
your case though, where devices come and go but need static naming, it 
doesn't work so well. Unfortunately I'm not a devfs guru. However, you 
might have a look at the devfs man page. You can add rule-sets to the 
devfs configuration file in /etc. If I remember correctly this can even 
work off the device ID tag. What you would do is add rules that create 
symlinks between the devfs dynamic rules and static symlinks you name.

Ryan Sommers
ryans at

More information about the freebsd-hackers mailing list