Subject: Re: Automatically bumping device numbers
To: Garrett D'Amore <>
From: Marcin Jessa <>
List: current-users
Date: 03/24/2006 22:11:23
On Fri, 24 Mar 2006 13:59:28 -0800
"Garrett D'Amore" <> wrote:

> Marcin Jessa wrote:
> > Hi guys.
> >
> > Testing the CARP patch of Liam I noticed that creating 
> > of new devices like bridge or carp requires giving them a 
> > specific number, i.e bridge0 or carp0. 
> > I was wondering if you think it would be a good idea to have 
> > the device numbers being bumped up automatically like on 
> > FreeBSD if numbers are not explicitly given.
> > So ifconfig carp create would create carp0 and running 
> > the command again would create carp1, etc.
> > Is there any reason for this not being implemented?
> > One more thing that must be a heritage from the past is
> > ifconfig which needs -a flag to show all the network devices
> > instead of just ifconfig. Is there any reason for that too?
> >   
> You need to create device nodes in order to have dynamic device
> numbers.  This also means you need to create some persistent database
> containing the mapping.   Right now, we don't have anything like that. 
> The (mythical?) devfs project could address this, however.

Ok, thanks.
> As far as ifconfig, ifconfig behaves that way (needing -a to show all
> interfaces) on other operating systems as well.  For example, without
> arguments, ifconfig on Solaris shows a help message, just as on NetBSD.
> I would vote *against* changing that behavior of ifconfig.    The help
> message for ifconfig may actually be useful to some folks.

We already have ifconfig -h and man ifconfig...
To be honest it's pretty annoying if one has to type -a when simple ifconfig
could do the same thing.