[patch for review] Fwd: CURRENT: ifconfig tap0 results in core dump
From: Peter Edwards (peadar.edwards_at_gmail.com)
Date: 05/24/05
- Previous message: skshyam: "LDAP Server hangs"
- Next in thread: Maksim Yevmenkin: "Re: [patch for review] Fwd: CURRENT: ifconfig tap0 results in core dump"
- Reply: Maksim Yevmenkin: "Re: [patch for review] Fwd: CURRENT: ifconfig tap0 results in core dump"
- Reply: Brooks Davis: "Re: [patch for review] Fwd: CURRENT: ifconfig tap0 results in core dump"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 24 May 2005 16:38:02 +0100 To: freebsd-net@freebsd.org
Does anyone have any objection to me committing the patch in this thread?
(Note: I inadvertently included a local change that no longer prevents
non-root users from opening up /dev/tap*: I don't intend to commit
that part of it)
---------- Forwarded message ----------
From: Peter Edwards <peadar.edwards@gmail.com>
Date: May 19, 2005 4:34 PM
Subject: Re: CURRENT: ifconfig tap0 results in core dump
To: Matti Saarinen <mjsaarin@cc.helsinki.fi>, Scot Hetzel
<swhetzel@gmail.com>, freebsd-current@freebsd.org
Cc: peadar@freebsd.org
> > % ifconfig tap0
> > tap0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> mtu 1500
> > inet6 fe80::2bd:9ff:fe7c:100%tap0 prefixlen 64 scopeid 0x5
> > zsh: segmentation fault (core dumped) ifconfig tap0
> >
> >
> > I remember that ifconfig didn't dump core when my laptop ran CURRENT
> > from a few months ago.
> >
> You'll probably need to build a version of ifconfig with debugging
> symbols. And then provide a backtrace of the core dump.
>
> How soon after killing openvpn, do you use the ifconfig command. It
> might be possible that devfs was in the process of removing tap0, when
> you used the ifconfig command.
>
Hm.
It looks like the "close" code for if_tap clears out the addresses of
the interface with a pretty blunt-edged "bzero", rather than removing
them in any clean fashion. As a result, ifconfig gets confused over
the address families in the tags it sees on the addresses it
enumerates off the tap interface, and collapses with a corefile.
if_tap's "close" seems to be trying to do part of what's done in
if_detach, so I split out what I think are the relevant bits from
there and used it in both places.
Any networking experts care to take a look at the patch? I suspect
there's a whole mess of locking I'm not doing for a start, but I think
it might be an improvement over the current situation.
Cheers,
Peadar.
_______________________________________________
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"
- text/plain attachment: iftap.txt
- Previous message: skshyam: "LDAP Server hangs"
- Next in thread: Maksim Yevmenkin: "Re: [patch for review] Fwd: CURRENT: ifconfig tap0 results in core dump"
- Reply: Maksim Yevmenkin: "Re: [patch for review] Fwd: CURRENT: ifconfig tap0 results in core dump"
- Reply: Brooks Davis: "Re: [patch for review] Fwd: CURRENT: ifconfig tap0 results in core dump"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|