NetBSD Problem Report #16761

Received: (qmail 6076 invoked from network); 11 May 2002 18:18:27 -0000
Message-Id: <200205111922.g4BJMrA00949@spagetti.localnet>
Date: Sat, 11 May 2002 19:22:53 GMT
From: jasper@pointless.net
Reply-To: jasper@pointless.net
To: gnats-bugs@gnats.netbsd.org
Subject: gre works fine with a larger mtu - needed for cisco interop.
X-Send-Pr-Version: 3.95

>Number:         16761
>Category:       kern
>Synopsis:       gre(4) interfaces work with a larger mtu
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    kern-bug-people
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat May 11 18:19:00 +0000 2002
>Closed-Date:    Sun Jun 09 09:48:36 +0000 2002
>Last-Modified:  Wed Nov 06 22:03:00 +0000 2002
>Originator:     Jasper Wallace
>Release:        NetBSD 1.5ZC
>Organization:
	none whatsoever.
>Environment:
System: NetBSD spagetti 1.5ZC NetBSD 1.5ZC (SPAGETTI) #0: Fri Apr 26 02:31:12 UTC 2002 jasper@spagetti:/usr/src/sys/arch/i386/compile/SPAGETTI i386
Architecture: i386
Machine: i386
>Description:
	When trying to use ospf over gre a tunnel to a cisco router i
noticed that the two machines where failing to sync beacause the mtu used at
either end of the link was different.

	The cisco was using 1476, where as NetBSD uses 1450.

	Unfortunatly there dosn't appear to be a way to change the mtu under
Cisco IOS, fortunatly NetBSD comes with source code.

	I've been running with the larger MTU on both -current and
1.5.3_whatever for a few weeks now without any problems.

>How-To-Repeat:

	Create a gre tunnel between a router running cisco IOS and one
running NetBSD and try to run OSPF over the tunnel.

look at the log messages complaining about "MTU missmatches".

>Fix:
Index: if_gre.c
===================================================================
RCS file: /cvsroot/syssrc/sys/net/if_gre.c,v
retrieving revision 1.26
diff -u -r1.26 if_gre.c
--- if_gre.c	2002/02/24 17:22:20	1.26
+++ if_gre.c	2002/05/11 17:44:11
@@ -107,7 +107,7 @@
  * before changing if state to up to find the
  * correct value
  */
-#define GREMTU 1450
+#define GREMTU 1476
 #define LINK_MASK (IFF_LINK0|IFF_LINK1|IFF_LINK2)

 struct gre_softc_head gre_softc_list;


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: martin 
State-Changed-When: Sun Jun 9 02:47:53 PDT 2002 
State-Changed-Why:  
Fixed, thanks for reporting. 

From: Matthias Scheler <tron@netbsd.org>
To: gnats-bugs@gnats.netbsd.org
Cc:  
Subject: pr/16761 CVS commit: [netbsd-1-6] syssrc/sys/net
Date: Wed,  6 Nov 2002 23:28:48 +0200 (EET)

 Module Name:	syssrc
 Committed By:	tron
 Date:		Wed Nov  6 21:28:47 UTC 2002

 Modified Files:
 	syssrc/sys/net [netbsd-1-6]: if_gre.c

 Log Message:
 Pull up revision 1.27 (requested by martin in ticket #226):
 Change default MTU to 1476 (same value that Cisco uses).
 Do not limit the MTU when set by the admin with ifconfig, per discussion
 on tech-net.
 This fixes PR 16761 from Jasper Wallace.


 To generate a diff of this commit:
 cvs rdiff -r1.26 -r1.26.10.1 syssrc/sys/net/if_gre.c

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.