git: de121c54781b - main - jail: copy MTU settings to vnet interface
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 09 May 2025 09:43:57 UTC
The branch main has been updated by oshogbo:
URL: https://cgit.FreeBSD.org/src/commit/?id=de121c54781b92d4287277eefa8fd3eb783c8290
commit de121c54781b92d4287277eefa8fd3eb783c8290
Author: Mariusz Zaborski <oshogbo@FreeBSD.org>
AuthorDate: 2025-05-09 09:42:07 +0000
Commit: Mariusz Zaborski <oshogbo@FreeBSD.org>
CommitDate: 2025-05-09 09:42:07 +0000
jail: copy MTU settings to vnet interface
Reported by: Arne Steinkamm <arne@steinkamm.com>
Reviewed by: bapt, thj
Differential Revision: https://reviews.freebsd.org/D48334
---
share/examples/jails/jng | 3 +++
1 file changed, 3 insertions(+)
diff --git a/share/examples/jails/jng b/share/examples/jails/jng
index 610b08f96840..53dc680e6312 100755
--- a/share/examples/jails/jng
+++ b/share/examples/jails/jng
@@ -314,6 +314,8 @@ jng_bridge()
ngctl name $iface:lower ${iface}bridge || return
fi
+ mtu=$(ifconfig ${iface} | sed -n '1s/^.*mtu //p;') || return
+
# Optionally create a secondary bridge
if [ "$bridge" != "bridge" ] &&
! ngctl info "$iface$bridge:" > /dev/null 2>&1
@@ -346,6 +348,7 @@ jng_bridge()
echo $2 ) || return
ngctl name "$iface$bridge:link$num" $eiface || return
ifconfig $new name $eiface || return
+ ifconfig $eiface mtu $mtu || return
ifconfig $eiface up || return
#