From: Daniel Weismüller daniel.weismueller@ipfire.org
This has been broken because of other changes on the network scripts and since we now have support for bridges there is no point in supporting something else that has the same functionality.
Signed-off-by: Michael Tremer michael.tremer@ipfire.org --- config/collectd/collectd.conf | 1 - config/rootfiles/core/156/filelists/files | 3 +++ config/rootfiles/core/156/update.sh | 4 ++++ config/udev/network-hotplug-bridges | 9 --------- config/udev/network-hotplug-rename | 10 ---------- html/cgi-bin/zoneconf.cgi | 5 ----- 6 files changed, 7 insertions(+), 25 deletions(-)
diff --git a/config/collectd/collectd.conf b/config/collectd/collectd.conf index c2316e415..941c631c9 100644 --- a/config/collectd/collectd.conf +++ b/config/collectd/collectd.conf @@ -36,7 +36,6 @@ include "/etc/collectd.precache" <Plugin interface> Interface "lo" Interface "/[0-9]*phys$/" - Interface "/^macvtap[0-9]*$/" Interface "/^vnet[0-9]*$/" IgnoreSelected true </Plugin> diff --git a/config/rootfiles/core/156/filelists/files b/config/rootfiles/core/156/filelists/files index 7dfa5a044..ea8d7ca6b 100644 --- a/config/rootfiles/core/156/filelists/files +++ b/config/rootfiles/core/156/filelists/files @@ -1,5 +1,8 @@ +etc/collectd.conf etc/rc.d/init.d/suricata etc/sysctl.conf +lib/udev/network-hotplug-bridges +lib/udev/network-hotplug-rename srv/web/ipfire/cgi-bin/entropy.cgi srv/web/ipfire/cgi-bin/firewall.cgi srv/web/ipfire/cgi-bin/getrrdimage.cgi diff --git a/config/rootfiles/core/156/update.sh b/config/rootfiles/core/156/update.sh index d078c01cd..fd83d94ba 100644 --- a/config/rootfiles/core/156/update.sh +++ b/config/rootfiles/core/156/update.sh @@ -58,6 +58,10 @@ rm -rfv /usr/lib/perl5/5.30.0 # Reload sysctl.conf sysctl -p
+# Migrate any macvtap interfaces to bridge +sed -e "s/_MODE=macvtap/_MODE=bridge/g" \ + -i /var/ipfire/ethernet/settings + # Start services telinit u /etc/init.d/suricata restart diff --git a/config/udev/network-hotplug-bridges b/config/udev/network-hotplug-bridges index a2ee56b83..bacf722ef 100644 --- a/config/udev/network-hotplug-bridges +++ b/config/udev/network-hotplug-bridges @@ -112,15 +112,6 @@ case "${MODE}" in ip link set dev "${INTERFACE}" up ;;
- macvtap) - ADDRESS="$(</sys/class/net/${INTERFACE}/address)" - GENERATED_ADDRESS=$(random_mac_address) - - ip link add link "${INTERFACE}" "${BRIDGE}" address "${ADDRESS}" type macvlan mode bridge - ip link set "${INTERFACE}" address "${GENERATED_ADDRESS}" - ip link set "${INTERFACE}" up - ;; - "") exit 0 ;; diff --git a/config/udev/network-hotplug-rename b/config/udev/network-hotplug-rename index 8807e0ab8..73e811e94 100644 --- a/config/udev/network-hotplug-rename +++ b/config/udev/network-hotplug-rename @@ -78,16 +78,6 @@ for zone in ${ZONES}; do (( counter += 1 )) done ;; - - macvtap) - # MACVTAP mode doesn't work for WiFi devices - if [ -d "/sys/class/net/${INTERFACE}/phy80211" ]; then - logger -t network "MACVTAP mode is not supported for wireless devices" - echo "${!device}" - else - echo "${!device%0}phys0" - fi - ;; esac done
diff --git a/html/cgi-bin/zoneconf.cgi b/html/cgi-bin/zoneconf.cgi index ad0ec85fa..62f18e308 100644 --- a/html/cgi-bin/zoneconf.cgi +++ b/html/cgi-bin/zoneconf.cgi @@ -345,8 +345,6 @@ if ($cgiparams{"ACTION"} eq $Lang::tr{"save"}) { if ($zone_mode eq "BRIDGE") { $ethsettings{"${uc}_MODE"} = "bridge"; $ethsettings{"${uc}_SLAVES"} = $slave_string; - } elsif ($zone_mode eq "MACVTAP") { - $ethsettings{"${uc}_MODE"} = "macvtap"; }
# STP options @@ -423,8 +421,6 @@ foreach (@zones) { $mode_selected{"DEFAULT"} = "selected"; } elsif ($zone_mode eq "bridge") { $mode_selected{"BRIDGE"} = "selected"; - } elsif ($zone_mode eq "macvtap") { - $mode_selected{"MACVTAP"} = "selected"; }
print <<END @@ -432,7 +428,6 @@ foreach (@zones) { <select name="MODE $uc" data-zone="$uc" onchange="changeZoneMode(this)"> <option value="DEFAULT" $mode_selected{"DEFAULT"}>$Lang::tr{"zoneconf nicmode default"}</option> <option value="BRIDGE" $mode_selected{"BRIDGE"}>$Lang::tr{"zoneconf nicmode bridge"}</option> - <option value="MACVTAP" $mode_selected{"MACVTAP"}>$Lang::tr{"zoneconf nicmode macvtap"}</option> </select> </td> END