From 55525654a8cc9c7bd899beb7f63bfdcb20b48404 Mon Sep 17 00:00:00 2001 From: Nate Brown Date: Wed, 18 Dec 2019 16:49:46 -0800 Subject: [PATCH] Move tun mtu failing to an error log instead of fatal --- tun_linux.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tun_linux.go b/tun_linux.go index 9ae35f7..a41a274 100644 --- a/tun_linux.go +++ b/tun_linux.go @@ -187,7 +187,8 @@ func (c Tun) Activate() error { // Set the MTU on the device ifm := ifreqMTU{Name: devName, MTU: int32(c.MaxMTU)} if err = ioctl(fd, unix.SIOCSIFMTU, uintptr(unsafe.Pointer(&ifm))); err != nil { - return fmt.Errorf("failed to set tun mtu: %s", err) + // This is currently a non fatal condition because the route table must have the MTU set appropriately as well + l.WithError(err).Error("Failed to set tun mtu") } // Set the transmit queue length