El 06/10/21 a las 09:24, Martin-Éric Racine escribió:
> la 2. lokak. 2021 klo 11.13 Michael Biebl ([email protected]) kirjoitti:
> >
> > Am 02.10.21 um 09:05 schrieb Martin-Éric Racine:
> > > pe 1. lokak. 2021 klo 23.39 Santiago Ruano Rincón
> > > ([email protected]) kirjoitti:
> > >>
> > >> El 01/10/21 a las 17:05, Martin-Éric Racine escribió:
> > >>> pe 1. lokak. 2021 klo 16.21 Santiago Ruano Rincón
> > >>> ([email protected]) kirjoitti:
> > >>>> On Wed, 17 Feb 2021 14:32:24 +0200 Martin-Éric_Racine 
> > >>>> <[email protected]> wrote:
> > >>>>> Package: ifupdown
> > >>>>> Version: 0.8.36
> > >>>>> Severity: normal
> > >>>>>
> > >>>>> -----BEGIN PGP SIGNED MESSAGE-----
> > >>>>> Hash: SHA256
> > >>>>>
> > >>>>> The regex recipe below does not work as expected. I've tried both
> > >>>>>
> > >>>>> allow-hotplug /en*=en /wl*=wl
> > >>>>>
> > >>>>> and
> > >>>>>
> > >>>>> allow-hotplug /en*/=en /wl*/=wl
> > >>>>>
> > >>>>> but ifup still doesn't raise whatever interface match the regex. Have 
> > >>>>> I misunderstood the examples or am I missing something else?
> > >>>>>
> > >>>>> Thanks!
> > >>>>>
> > >>>>> - -- Package-specific info:
> > >>>>> - --- /etc/network/interfaces:
> > >>>>> allow-hotplug /en*=en /wl*=wl
> > >>>>>
> > >>>>> iface en inet dhcp
> > >>>>> iface en inet6 auto
> > >>>>>          privext 2
> > >>>>>          #dhcp 1
> > >>>>>
> > >>>>> iface wl inet dhcp
> > >>>>>          wpa-ssid AccessPoint
> > >>>>>          wpa-psk mypassword
> > >>>>> iface wl inet6 auto
> > >>>>>          privext 2
> > >>>>>          #dhcp 1
> > >>>
> > >>> [...]
> > >>>
> > >>>> I get both interfaces configured. Could you please run ifup with -v?
> > >>>
> > >>> I just tried. Here's an interesting difference:
> > >>>
> > >>> If I use 'sudo ifup -a -v' ifup won't find the mapped interfaces.
> > >>
> > >> ifup doesn't process them since they are not configured with `auto`
> > >
> > > OK, what processes interfaces with allow-hotplug then, if not ifupdown?
> > >
> > >> s/allow-hotplug/auto/ in my /e/n/interfaces makes this work.
> > >>>
> > >>> If I use 'sudo ifup --allow hotplug -a -v' ifup correctly finds and
> > >>> maps the wireless interfaces.
> > >>>
> > >>
> > >> I wonder if there is a problem related with udev instead.
> > >
> > > Added udev (systemd) maintainers in CC.
> >
> > If you are referring to
> > /lib/udev/ifupdown-hotplug and /lib/udev/rules.d/80-ifupdown.rules,
> > those files are maintained by the ifupdown package.
> >
> > The systemd package is not involved here.
> 
> Michael, I suspected as much. Thanks for confirming this.
> 
> Santiago, all evidences point to ifupdown pattern matching only
> working for auto interfaces, but not hotplug interfaces.

Not exactly, I think. 'sudo ifup --allow hotplug -a -v' works for you.

> Basically,
> hotplug works for named interfaces, but not for pattern matched
> interfaces.

ifupdown-hotplug receives as argument the name of the real
interface, so it execs ifup --allow=hotplug $INTERFACE
https://salsa.debian.org/debian/ifupdown/-/blob/master/debian/ifupdown-hotplug#L73
and it wouldn't find it in your configuration.

Maybe your use case matches better templates and inherits (See INTERFACE
TEMPLATES) in interfaces(5).

HTH,

 -- S

Attachment: signature.asc
Description: PGP signature

Reply via email to