Package: ifupdown
Version: 0.8.39+b1
Severity: minor

Dear Maintainer,


Editing /etc/network/interfaces


It appears that the 'up' command in an alias interface does not work correctly.
Moreover, since the 'up' command is run before the second alias interface is 
brought it, simply moving it does not help.

Fail1: brings up both the primary and alias IPs, but does NOT set up the route
Fail2: does not bring up the second alias interface at all.
Working: Brings up both IPs and the route.

This may just be a documentation issue (if you can't use aliases this way), but 
it appears to be a bug.
No journalctl messages are logged on the failures- just no route created.


=== START FAILING EXAMPLE 1 ===
allow-hotplug ens192
iface ens192 inet static
        address 123.123.123.146/24
        gateway 123.123.123.1


iface ens192 inet static
        address 10.200.2.201/16
        gateway 10.200.0.1
        up ip route add 10.201.0.0/16 dev $IFACE via 10.200.0.1
        down ip route del 10.201.0.0/16 dev $IFACE via 10.200.0.1 || true
=== END FAILING EXAMPLE 1 ===


=== START FAILING EXAMPLE 2 ===
allow-hotplug ens192
iface ens192 inet static
        address 123.123.123.146/24
        gateway 123.123.123.1
        up ip route add 10.201.0.0/16 dev $IFACE via 10.200.0.1
        down ip route del 10.201.0.0/16 dev $IFACE via 10.200.0.1 || true


iface ens192 inet static
        address 10.200.2.201/16
        gateway 10.200.0.1
=== END FAILING EXAMPLE 2 ===


=== START WORKING EXAMPLE ===
allow-hotplug ens192
iface ens192 inet static
        address 123.123.123.146/24
        gateway 123.123.123.1
        up ip addr add 10.200.2.201/16 dev $IFACE label $IFACE:0
        down ip addr del 10.200.2.201/16 dev $IFACE label $IFACE:0 || true
        up ip route add 10.201.0.0/16 dev $IFACE via 10.200.0.1
        down ip route del 10.201.0.0/16 dev $IFACE via 10.200.0.1 || true
=== END WORKING EXAMPLE ===


-- Package-specific info:
--- /etc/network/interfaces.d/*:
cat: '/etc/network/interfaces.d/*': No such file or directory


--- up and down scripts installed:
/etc/network/if-down.d:
total 4
-rwxr-xr-x 1 root root 759 Sep 27 09:09 resolved


/etc/network/if-post-down.d:
total 0


/etc/network/if-pre-up.d:
total 4
-rwxr-xr-x 1 root root 344 Jun 30  2016 ethtool


/etc/network/if-up.d:
total 12
-rwxr-xr-x 1 root root 1685 Jun 30  2016 ethtool
-rwxr-xr-x 1 root root 4663 Sep 27 09:09 resolved




-- System Information:
Debian Release: bookworm/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)


Kernel: Linux 6.0.0-4-amd64 (SMP w/4 CPU threads; PREEMPT)
Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_CA:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled


Versions of packages ifupdown depends on:
ii  adduser   3.129
ii  iproute2  6.0.0-1+b1
ii  libc6     2.36-4


Versions of packages ifupdown recommends:
ii  isc-dhcp-client [dhcp-client]  4.4.3-P1-1


Versions of packages ifupdown suggests:
pn  ppp     <none>
pn  rdnssd  <none>


-- no debconf information

Reply via email to