NetBSD Problem Report #16704

Received: (qmail 12480 invoked from network); 7 May 2002 21:15:29 -0000
Message-Id: <20020507211537.74DD9F98@snout.autonomica.se>
Date: Tue,  7 May 2002 23:15:37 +0200 (CEST)
From: johani@autonomica.se
Reply-To: johani@autonomica.se
To: gnats-bugs@gnats.netbsd.org
Subject: v4 over v4 through GRE tunnel causes panics.
X-Send-Pr-Version: 3.95

>Number:         16704
>Category:       kern
>Synopsis:       v4 over v4 through GRE tunnel causes panics.
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue May 07 21:16:01 +0000 2002
>Closed-Date:    
>Last-Modified:  Thu May 13 10:00:03 +0000 2010
>Originator:     Johan Ihren
>Release:        NetBSD 1.5ZC
>Organization:
	Autonomica, Sweden
>Environment:
System: NetBSD 1.5ZC (HAGRID) #1: Sat May 4 13:30:48 CEST 2002
Architecture: i386
Machine: i386
>Description:
	I recently set up a gre tunnel between two sites where I route a
	small prefix of v4 addresses from the first site to the other and
	hence need to use the tunnel as the default route at the downstream
	site. 

	During the configuration of this I've have any number of painful
	crashes on the machine with the downstream tunnel endpoint. These
	crashes come at different times, but are all "instant", in the sense
	of not ending up in ddb, nothing in the logs, just instant transfer
	to the BIOS and the box boots again. The quickest panic is in
	immediate response to a "route add default <other end of tunnel>"
	while the longest uptime is almost 24h.

	With more than a dozen panics in the past two days on a machine
	that otherwise only reboots for OS upgrades once every six months
	this is quite painful.

>How-To-Repeat:

I call on this script through /etc/rc.d/gretunnel. Obviously there is
a similar configuration at the other end with the difference that
instead of a default route into the tunnel there is a static route
into the tunnel for the small prefix 192.z.80.240/28

#!/bin/sh

# first make sure we have a more precise route to the tunnel end point
# 130.x.10.138 = publicly routed address at upstream site
# 213.y.164.129 = publicly routed address at this site (the downstream site)
route add -host 130.x.10.138 213.y.164.129

# then bring up gre0 using the tunnel addresses, upstream is 192.168.100.1
ifconfig gre0 create
ifconfig gre0 inet 192.168.100.2 192.168.100.1 netmask 255.255.255.255 link0 lin
k1 up

# do the rest of the GRE configuration using outside addresses
greconfig -v -i gre0 -s 213.y.164.150 -d 130.x.10.138

# finally fix the default route to point through the tunnel
route delete default
route add default 192.168.100.1

>Fix:
	Unknown.
>Release-Note:
>Audit-Trail:

From: Mihai Chelaru <kefren@netbsd.ro>
To: johani@autonomica.se
Cc: gnats-bugs@gnats.netbsd.org
Subject: Re: kern/16704: v4 over v4 through GRE tunnel causes panics.
Date: Wed, 8 May 2002 14:11:10 +0300

 Can you check http://mail-index.netbsd.org/netbsd-bugs/2001/11/08/0003.html ? 
 Could be the same problem.

 Cheers,
 Mihai

 On Wednesday 08 May 2002 00:15, johani@autonomica.se wrote:
 > >Number:         16704
 > >Category:       kern
 > >Synopsis:       v4 over v4 through GRE tunnel causes panics.
 > >Confidential:   no
 > >Severity:       serious
 > >Priority:       medium
 > >Responsible:    kern-bug-people
 > >State:          open
 > >Class:          sw-bug
 > >Submitter-Id:   net
 > >Arrival-Date:   Tue May 07 14:16:01 PDT 2002
 > >Closed-Date:
 > >Last-Modified:
 > >Originator:     Johan Ihren
 > >Release:        NetBSD 1.5ZC
 > >Organization:
 >
 > 	Autonomica, Sweden
 >
 > >Environment:
 >
 > System: NetBSD 1.5ZC (HAGRID) #1: Sat May 4 13:30:48 CEST 2002
 > Architecture: i386
 > Machine: i386
 >
 > >Description:
 >
 > 	I recently set up a gre tunnel between two sites where I route a
 > 	small prefix of v4 addresses from the first site to the other and
 > 	hence need to use the tunnel as the default route at the downstream
 > 	site.
 >
 > 	During the configuration of this I've have any number of painful
 > 	crashes on the machine with the downstream tunnel endpoint. These
 > 	crashes come at different times, but are all "instant", in the sense
 > 	of not ending up in ddb, nothing in the logs, just instant transfer
 > 	to the BIOS and the box boots again. The quickest panic is in
 > 	immediate response to a "route add default <other end of tunnel>"
 > 	while the longest uptime is almost 24h.
 >
 > 	With more than a dozen panics in the past two days on a machine
 > 	that otherwise only reboots for OS upgrades once every six months
 > 	this is quite painful.
 >
 > >How-To-Repeat:
 >
 > I call on this script through /etc/rc.d/gretunnel. Obviously there is
 > a similar configuration at the other end with the difference that
 > instead of a default route into the tunnel there is a static route
 > into the tunnel for the small prefix 192.z.80.240/28
 >
 > #!/bin/sh
 >
 > # first make sure we have a more precise route to the tunnel end point
 > # 130.x.10.138 = publicly routed address at upstream site
 > # 213.y.164.129 = publicly routed address at this site (the downstream
 > site) route add -host 130.x.10.138 213.y.164.129
 >
 > # then bring up gre0 using the tunnel addresses, upstream is 192.168.100.1
 > ifconfig gre0 create
 > ifconfig gre0 inet 192.168.100.2 192.168.100.1 netmask 255.255.255.255
 > link0 lin k1 up
 >
 > # do the rest of the GRE configuration using outside addresses
 > greconfig -v -i gre0 -s 213.y.164.150 -d 130.x.10.138
 >
 > # finally fix the default route to point through the tunnel
 > route delete default
 > route add default 192.168.100.1
 >
 > >Fix:
 >
 > 	Unknown.
 >
 > >Release-Note:
 > >Audit-Trail:
 > >Unformatted:
 >
 >  	-current as of May 4, 2002.

From: Johan Ihren <johani@autonomica.se>
To: Mihai Chelaru <kefren@netbsd.ro>
Cc: gnats-bugs@gnats.netbsd.org
Subject: Re: kern/16704: v4 over v4 through GRE tunnel causes panics.
Date: 08 May 2002 22:24:17 +0200

 Mihai Chelaru <kefren@netbsd.ro> writes:

 Hi, Mihai,

 > Can you check
 > http://mail-index.netbsd.org/netbsd-bugs/2001/11/08/0003.html ?
 > Could be the same problem.

 Hmm. Not sure.

 I think the symptoms are slightly different. I don't get any strange
 route and also my tunnel actually works (at least for a while).

 However, that said, one failure mode that I can repeat is 

 a) run dhclient to pick up IP adress and default route from ISP (this
    is what I do in practice).

 b) set up the tunnel with the script below. Redirect default route
    into the tunnel. Everything works fine. Traffic flows both ways.

 c) dhclient (or rather dhclient-script) get a default route from the
    ISP when it refreshes the lease. Everything still works nicely, in
    the sense that the box runs rather than crashes. Routing is
    obviously broken.

 d) route delete default ; route add default <other tunnel end
    point>. I.e. restore the default route into the tunnel that was
    working fine before (c) happened.

 e) send the first packet along the default route into the tunnel -->
    kaboom.

 My point is that although I get to the dangerous state in a different,
 somewhat more convoluted way than you, once I'm there it may be the
 same bug we both tickle.

 Regards,

 Johan


 > On Wednesday 08 May 2002 00:15, johani@autonomica.se wrote:
 > > >Number:         16704
 > > >Category:       kern
 > > >Synopsis:       v4 over v4 through GRE tunnel causes panics.
 > > >Confidential:   no
 > > >Severity:       serious
 > > >Priority:       medium
 > > >Responsible:    kern-bug-people
 > > >State:          open
 > > >Class:          sw-bug
 > > >Submitter-Id:   net
 > > >Arrival-Date:   Tue May 07 14:16:01 PDT 2002
 > > >Closed-Date:
 > > >Last-Modified:
 > > >Originator:     Johan Ihren
 > > >Release:        NetBSD 1.5ZC
 > > >Organization:
 > >
 > > 	Autonomica, Sweden
 > >
 > > >Environment:
 > >
 > > System: NetBSD 1.5ZC (HAGRID) #1: Sat May 4 13:30:48 CEST 2002
 > > Architecture: i386
 > > Machine: i386
 > >
 > > >Description:
 > >
 > > 	I recently set up a gre tunnel between two sites where I route a
 > > 	small prefix of v4 addresses from the first site to the other and
 > > 	hence need to use the tunnel as the default route at the downstream
 > > 	site.
 > >
 > > 	During the configuration of this I've have any number of painful
 > > 	crashes on the machine with the downstream tunnel endpoint. These
 > > 	crashes come at different times, but are all "instant", in the sense
 > > 	of not ending up in ddb, nothing in the logs, just instant transfer
 > > 	to the BIOS and the box boots again. The quickest panic is in
 > > 	immediate response to a "route add default <other end of tunnel>"
 > > 	while the longest uptime is almost 24h.
 > >
 > > 	With more than a dozen panics in the past two days on a machine
 > > 	that otherwise only reboots for OS upgrades once every six months
 > > 	this is quite painful.
 > >
 > > >How-To-Repeat:
 > >
 > > I call on this script through /etc/rc.d/gretunnel. Obviously there is
 > > a similar configuration at the other end with the difference that
 > > instead of a default route into the tunnel there is a static route
 > > into the tunnel for the small prefix 192.z.80.240/28
 > >
 > > #!/bin/sh
 > >
 > > # first make sure we have a more precise route to the tunnel end point
 > > # 130.x.10.138 = publicly routed address at upstream site
 > > # 213.y.164.129 = publicly routed address at this site (the downstream
 > > site) route add -host 130.x.10.138 213.y.164.129
 > >
 > > # then bring up gre0 using the tunnel addresses, upstream is 192.168.100.1
 > > ifconfig gre0 create
 > > ifconfig gre0 inet 192.168.100.2 192.168.100.1 netmask 255.255.255.255
 > > link0 lin k1 up
 > >
 > > # do the rest of the GRE configuration using outside addresses
 > > greconfig -v -i gre0 -s 213.y.164.150 -d 130.x.10.138
 > >
 > > # finally fix the default route to point through the tunnel
 > > route delete default
 > > route add default 192.168.100.1
 > >
 > > >Fix:
 > >
 > > 	Unknown.
 > >
 > > >Release-Note:
 > > >Audit-Trail:
 > > >Unformatted:
 > >
 > >  	-current as of May 4, 2002.
From: Martin Husemann <martin@duskware.de>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/16704: v4 over v4 through GRE tunnel causes panics
Date: Thu, 13 May 2010 11:57:54 +0200

 I just tested on -current

 The routing has been defered, so we don't panic any more, but the setup
 still does not work (gre0 never comes UP).

 Martin

>Unformatted:
 	-current as of May 4, 2002.

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.