[pve-devel] [PATCH pve-common] Inotify: allow bond of bond

Alexandre Derumier aderumier at odiso.com
Tue Oct 20 13:26:11 CEST 2020


for example,some users need to do active-backup bond, on top of 2 lacp bond.
---
 src/PVE/INotify.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/PVE/INotify.pm b/src/PVE/INotify.pm
index f524672..c5067de 100644
--- a/src/PVE/INotify.pm
+++ b/src/PVE/INotify.pm
@@ -1509,7 +1509,7 @@ sub __write_etc_network_interfaces {
 		die "bond '$iface' - unable to find slave '$p'\n"
 		    if !$n;
 		die "bond '$iface' - wrong interface type on slave '$p' " .
-		    "('$n->{type}' != 'eth')\n" if $n->{type} ne 'eth';
+		    "('$n->{type}' != 'eth or bond')\n" if ($n->{type} ne 'eth' && $n->{type} ne 'bond');
 		&$check_mtu($ifaces, $iface, $p);
 		$bond_primary_is_slave = 1 if $d->{'bond-primary'} && $d->{'bond-primary'} eq $p;
 	    }
-- 
2.20.1





More information about the pve-devel mailing list