All of lore.kernel.org
 help / color / mirror / Atom feed
* Why is gre0 auto-created, and can we fix it?
@ 2012-01-03 19:49 Ben Greear
  2012-01-03 19:59 ` David Miller
  0 siblings, 1 reply; 11+ messages in thread
From: Ben Greear @ 2012-01-03 19:49 UTC (permalink / raw)
  To: netdev

While trying to figure out why 'gre0' doesn't
go away properly in my application, I noticed that
it is auto-created if you just run 'ifconfig gre0'.
(Same thing happens if you use 'ip link show gre0')

As far as I can tell, no other interfaces are auto-created
in this manner.

If I cook up a patch to 'fix' this, would it be acceptable,
or are we stuck with the current behaviour for backwards-compat
reasons?

[root@lec2010-ath9k-1 lanforge]# rmmod ip_gre
[root@lec2010-ath9k-1 lanforge]# ip link show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
     link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
     link/ether 00:90:0b:13:ed:ea brd ff:ff:ff:ff:ff:ff
3: eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN qlen 1000
     link/ether 00:90:0b:13:ed:eb brd ff:ff:ff:ff:ff:ff
[root@lec2010-ath9k-1 lanforge]# ifconfig gre0
gre0      Link encap:UNSPEC  HWaddr 00-00-00-00-00-00-01-00-00-00-00-00-00-00-00-00
           NOARP  MTU:1476  Metric:1

[root@lec2010-ath9k-1 lanforge]# ip link show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
     link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
     link/ether 00:90:0b:13:ed:ea brd ff:ff:ff:ff:ff:ff
3: eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN qlen 1000
     link/ether 00:90:0b:13:ed:eb brd ff:ff:ff:ff:ff:ff
76: gre0: <NOARP> mtu 1476 qdisc noop state DOWN
     link/gre 0.0.0.0 brd 0.0.0.0
[root@lec2010-ath9k-1 lanforge]# ifconfig tap0
tap0: error fetching interface information: Device not found

Thanks,
Ben

-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-03 19:49 Why is gre0 auto-created, and can we fix it? Ben Greear
@ 2012-01-03 19:59 ` David Miller
  2012-01-03 20:03   ` Ben Greear
  0 siblings, 1 reply; 11+ messages in thread
From: David Miller @ 2012-01-03 19:59 UTC (permalink / raw)
  To: greearb; +Cc: netdev

From: Ben Greear <greearb@candelatech.com>
Date: Tue, 03 Jan 2012 11:49:50 -0800

> As far as I can tell, no other interfaces are auto-created
> in this manner.

ip6tnl0 and sit0 do it too, just grep for alloc_netdev() under
net/{ipv4,ipv6}/

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-03 19:59 ` David Miller
@ 2012-01-03 20:03   ` Ben Greear
  2012-01-03 20:11     ` David Miller
  2012-01-21 17:39     ` Krzysztof Halasa
  0 siblings, 2 replies; 11+ messages in thread
From: Ben Greear @ 2012-01-03 20:03 UTC (permalink / raw)
  To: David Miller; +Cc: netdev

On 01/03/2012 11:59 AM, David Miller wrote:
> From: Ben Greear<greearb@candelatech.com>
> Date: Tue, 03 Jan 2012 11:49:50 -0800
>
>> As far as I can tell, no other interfaces are auto-created
>> in this manner.
>
> ip6tnl0 and sit0 do it too, just grep for alloc_netdev() under
> net/{ipv4,ipv6}/

So, no changing the behaviour?

Thanks,
Ben

-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-03 20:03   ` Ben Greear
@ 2012-01-03 20:11     ` David Miller
  2012-01-21 17:39     ` Krzysztof Halasa
  1 sibling, 0 replies; 11+ messages in thread
From: David Miller @ 2012-01-03 20:11 UTC (permalink / raw)
  To: greearb; +Cc: netdev

From: Ben Greear <greearb@candelatech.com>
Date: Tue, 03 Jan 2012 12:03:56 -0800

> On 01/03/2012 11:59 AM, David Miller wrote:
>> From: Ben Greear<greearb@candelatech.com>
>> Date: Tue, 03 Jan 2012 11:49:50 -0800
>>
>>> As far as I can tell, no other interfaces are auto-created
>>> in this manner.
>>
>> ip6tnl0 and sit0 do it too, just grep for alloc_netdev() under
>> net/{ipv4,ipv6}/
> 
> So, no changing the behaviour?

Probably too risky.  I think the exposure is on the order of ~16
years.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-03 20:03   ` Ben Greear
  2012-01-03 20:11     ` David Miller
@ 2012-01-21 17:39     ` Krzysztof Halasa
  2012-01-21 17:48       ` Ben Greear
  1 sibling, 1 reply; 11+ messages in thread
From: Krzysztof Halasa @ 2012-01-21 17:39 UTC (permalink / raw)
  To: Ben Greear; +Cc: David Miller, netdev

Ben Greear <greearb@candelatech.com> writes:

>>> As far as I can tell, no other interfaces are auto-created
>>> in this manner.
>>
>> ip6tnl0 and sit0 do it too, just grep for alloc_netdev() under
>> net/{ipv4,ipv6}/
>
> So, no changing the behaviour?

Perhaps making it CONFIGurable would be safe enough, not that I like
CONFIG options for all tiny details (one may argue it's not a tiny
detail).

Haven't looked at the actual code.
-- 
Krzysztof Halasa

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-21 17:39     ` Krzysztof Halasa
@ 2012-01-21 17:48       ` Ben Greear
  2012-01-21 18:40         ` David Miller
  0 siblings, 1 reply; 11+ messages in thread
From: Ben Greear @ 2012-01-21 17:48 UTC (permalink / raw)
  To: Krzysztof Halasa; +Cc: David Miller, netdev

On 01/21/2012 09:39 AM, Krzysztof Halasa wrote:
> Ben Greear<greearb@candelatech.com>  writes:
>
>>>> As far as I can tell, no other interfaces are auto-created
>>>> in this manner.
>>>
>>> ip6tnl0 and sit0 do it too, just grep for alloc_netdev() under
>>> net/{ipv4,ipv6}/
>>
>> So, no changing the behaviour?
>
> Perhaps making it CONFIGurable would be safe enough, not that I like
> CONFIG options for all tiny details (one may argue it's not a tiny
> detail).
>
> Haven't looked at the actual code.

Seems like it could be a run-time configurable, maybe module or boot option
or sysctl or something.

I haven't looked any more at the code either...maybe next week (tm).

Thanks,
Ben


-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-21 17:48       ` Ben Greear
@ 2012-01-21 18:40         ` David Miller
  2012-01-22 16:48           ` Ben Greear
  0 siblings, 1 reply; 11+ messages in thread
From: David Miller @ 2012-01-21 18:40 UTC (permalink / raw)
  To: greearb; +Cc: khc, netdev

From: Ben Greear <greearb@candelatech.com>
Date: Sat, 21 Jan 2012 09:48:52 -0800

> On 01/21/2012 09:39 AM, Krzysztof Halasa wrote:
>> Ben Greear<greearb@candelatech.com>  writes:
>>
>>>>> As far as I can tell, no other interfaces are auto-created
>>>>> in this manner.
>>>>
>>>> ip6tnl0 and sit0 do it too, just grep for alloc_netdev() under
>>>> net/{ipv4,ipv6}/
>>>
>>> So, no changing the behaviour?
>>
>> Perhaps making it CONFIGurable would be safe enough, not that I like
>> CONFIG options for all tiny details (one may argue it's not a tiny
>> detail).
>>
>> Haven't looked at the actual code.
> 
> Seems like it could be a run-time configurable, maybe module or boot
> option
> or sysctl or something.

I would seriously prefer that you not do this.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-21 18:40         ` David Miller
@ 2012-01-22 16:48           ` Ben Greear
  2012-01-22 19:14             ` David Miller
  0 siblings, 1 reply; 11+ messages in thread
From: Ben Greear @ 2012-01-22 16:48 UTC (permalink / raw)
  To: David Miller; +Cc: khc, netdev

On 01/21/2012 10:40 AM, David Miller wrote:
> From: Ben Greear<greearb@candelatech.com>
> Date: Sat, 21 Jan 2012 09:48:52 -0800
>
>> On 01/21/2012 09:39 AM, Krzysztof Halasa wrote:
>>> Ben Greear<greearb@candelatech.com>   writes:
>>>
>>>>>> As far as I can tell, no other interfaces are auto-created
>>>>>> in this manner.
>>>>>
>>>>> ip6tnl0 and sit0 do it too, just grep for alloc_netdev() under
>>>>> net/{ipv4,ipv6}/
>>>>
>>>> So, no changing the behaviour?
>>>
>>> Perhaps making it CONFIGurable would be safe enough, not that I like
>>> CONFIG options for all tiny details (one may argue it's not a tiny
>>> detail).
>>>
>>> Haven't looked at the actual code.
>>
>> Seems like it could be a run-time configurable, maybe module or boot
>> option
>> or sysctl or something.
>
> I would seriously prefer that you not do this.

Just to make sure I understand you:  You dislike any possible method of changing
the behaviour, not just the ones I listed?

If I do post a patch, it will be just for comment should someone
else want to carry the patch privately, and I'll just carry the patch
in my tree.

Thanks,
Ben

-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-22 16:48           ` Ben Greear
@ 2012-01-22 19:14             ` David Miller
  2012-01-22 19:43               ` Stephen Hemminger
  2012-01-22 21:00               ` Ben Greear
  0 siblings, 2 replies; 11+ messages in thread
From: David Miller @ 2012-01-22 19:14 UTC (permalink / raw)
  To: greearb; +Cc: khc, netdev

From: Ben Greear <greearb@candelatech.com>
Date: Sun, 22 Jan 2012 08:48:53 -0800

> Just to make sure I understand you: You dislike any possible method
> of changing the behaviour, not just the ones I listed?

That's correct.

And please don't create dependencies on such a change in behavior in
distributions, otherwise you obliterate the entire reason why I don't
want the behavior changed.

There is no reason to change this, it's been like this for more than
10 years and no alien planet has exploded as a result even after all
of this time.

Just leave it be, I beg you.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-22 19:14             ` David Miller
@ 2012-01-22 19:43               ` Stephen Hemminger
  2012-01-22 21:00               ` Ben Greear
  1 sibling, 0 replies; 11+ messages in thread
From: Stephen Hemminger @ 2012-01-22 19:43 UTC (permalink / raw)
  To: David Miller; +Cc: greearb, khc, netdev

On Sun, 22 Jan 2012 14:14:47 -0500 (EST)
David Miller <davem@davemloft.net> wrote:

> From: Ben Greear <greearb@candelatech.com>
> Date: Sun, 22 Jan 2012 08:48:53 -0800
> 
> > Just to make sure I understand you: You dislike any possible method
> > of changing the behaviour, not just the ones I listed?
> 
> That's correct.
> 
> And please don't create dependencies on such a change in behavior in
> distributions, otherwise you obliterate the entire reason why I don't
> want the behavior changed.
> 
> There is no reason to change this, it's been like this for more than
> 10 years and no alien planet has exploded as a result even after all
> of this time.
> 
> Just leave it be, I beg you.

Also, the iproute tunnel tools rely on the module autoload
of gre0.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Why is gre0 auto-created, and can we fix it?
  2012-01-22 19:14             ` David Miller
  2012-01-22 19:43               ` Stephen Hemminger
@ 2012-01-22 21:00               ` Ben Greear
  1 sibling, 0 replies; 11+ messages in thread
From: Ben Greear @ 2012-01-22 21:00 UTC (permalink / raw)
  To: David Miller; +Cc: khc, netdev

On 01/22/2012 11:14 AM, David Miller wrote:
> From: Ben Greear<greearb@candelatech.com>
> Date: Sun, 22 Jan 2012 08:48:53 -0800
>
>> Just to make sure I understand you: You dislike any possible method
>> of changing the behaviour, not just the ones I listed?
>
> That's correct.
>
> And please don't create dependencies on such a change in behavior in
> distributions, otherwise you obliterate the entire reason why I don't
> want the behavior changed.

No worries, I don't have a real distribution and I can't imagine any
real distribution picking up my changes against your wishes.  Just to
be safe, I'll default any changes to the current behaviour.

> There is no reason to change this, it's been like this for more than
> 10 years and no alien planet has exploded as a result even after all
> of this time.

Well, it breaks my (proprietary, and already optimized for my own kernel
hacks) user-space program, and though I could add hacks to
fix it eventually, I think it will be much easier to hack the kernel.

> Just leave it be, I beg you.

I think you may be over-estimating my influence :)

I have much more horrible patches I've been carrying for years and years
and as you say, the alien planets are all doing ok.

Thanks,
Ben

-- 
Ben Greear <greearb@candelatech.com>
Candela Technologies Inc  http://www.candelatech.com

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2012-01-22 21:00 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-01-03 19:49 Why is gre0 auto-created, and can we fix it? Ben Greear
2012-01-03 19:59 ` David Miller
2012-01-03 20:03   ` Ben Greear
2012-01-03 20:11     ` David Miller
2012-01-21 17:39     ` Krzysztof Halasa
2012-01-21 17:48       ` Ben Greear
2012-01-21 18:40         ` David Miller
2012-01-22 16:48           ` Ben Greear
2012-01-22 19:14             ` David Miller
2012-01-22 19:43               ` Stephen Hemminger
2012-01-22 21:00               ` Ben Greear

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.