[systemd-devel] persistent network device names
Andrei Borzenkov
arvidjaar at gmail.com
Mon Jul 27 20:22:41 PDT 2015
В Mon, 27 Jul 2015 19:05:37 +0000
"Keller, Jacob E" <jacob.e.keller at intel.com> пишет:
> On Mon, 2015-07-27 at 21:53 +0300, Andrei Borzenkov wrote:
> > В Mon, 27 Jul 2015 18:29:57 +0000
> > "Keller, Jacob E" <jacob.e.keller at intel.com> пишет:
> >
> > > On Mon, 2015-07-27 at 21:12 +0300, Andrei Borzenkov wrote:
> > > > В Mon, 27 Jul 2015 17:52:59 +0000
> > > > "Keller, Jacob E" <jacob.e.keller at intel.com> пишет:
> > > >
> > > > > Hello,
> > > > >
> > > > > I am working with a network device that can create virtual
> > > > > function
> > > > > devices. When I create a large (>8) vfs for this device I get
> > > > > some
> > > > > weird device names,
> > > > >
> > > > > If I create 64 vfs, I see something like:
> > > > >
> > > > > ens8
> > > > > ens8f[1-7]
> > > > > ens8s[1-7]
> >
> > Are you sure? I do not see where such names would be generated.
> >
>
> Yes. These are generated via the hotplug section of udev-builtin
> -net_id.c rules
>
> on line: 230 or so.
>
I do not see where it generates double 's'.
> > > It looks like my issue comes from the "hotplug_slot" stuff, which
> > > overwrites the "enp8s0f0" into "ens8"... that is what causes this
> > > dual
> > > -name scheme confusion.
> > >
> >
> > You can disable hotplug slot-based naming by setting suitable
> > NamePolicy for network links (drop "slot").
>
> How can I define my own version of the net_id which does what I would
> like and run that in my udev rule?
man systemd.link
specifically description of NamePolicy
More information about the systemd-devel
mailing list