[Openswan Users] kernel 2.4.26 + Openswan 2.1.4 + net-snmp-5.1 = Kernel Oops

Paul Wouters paul at xelerance.com
Thu Sep 23 16:12:34 CEST 2004


On Thu, 23 Sep 2004, Ted Kaczmarek wrote:

This bug has been assigned and is pending investigation:

http://bugs.xelerance.com/bug_view_page.php?bug_id=0000144

I hope Michael can find the time to look at it soon.

Paul

> Date: Thu, 23 Sep 2004 09:06:23 -0400
> From: Ted Kaczmarek <tedkaz at optonline.net>
> To: users at lists.openswan.org,
>     Net-Snmp-Users <net-snmp-users at lists.sourceforge.net>
> Subject: Re: [Openswan Users]  kernel 2.4.26 + Openswan 2.1.4 + net-snmp-5.1 =
>      Kernel Oops
> 
> On Sun, 2004-08-01 at 06:27, Martin Bene wrote:
>> Martin Bene wrote:
>>
>> Looked at this some more; Not restricted to Openswan 2.1.4, also happens
>> with 2.2.0dr2 and with current strongswan release.
>>
>> Problem occurs when snmpd tries to figure out transmission speed for the
>> interfaces:
>>
>> <agent/mibgroup/mibII/interfaces.c>
>> ...
>> if (ioctl(fd, 0x8947, &ifr) >= 0) {
>>      new_ioctl_nums = 1;
>> } else if (ioctl(fd, SIOCDEVPRIVATE, &ifr) >= 0) {
>>      new_ioctl_nums = 0;
>> ...
>>
>> So, it first tries SIOCGMIIREG ioctl; if that doesn't work, it falls
>> back to SIOCDEVPRIVATE which seems to have been previously used for this
>> purpose.
>>
>> ipsec however uses SIOCDEVPRIVATE completely differently:
>>
>> /* attach a virtual ipsec? device to a physical device */
>> #define IPSEC_SET_DEV (SIOCDEVPRIVATE)
>>
>> ==> Result: ipsec bombs out trying to handle SIOCDEVPRIVATE ioctl for
>> (already configured) ipsec0.
>>
>> which leaves us with the question: what's the right fix?
>> 	a) remove the fallback SIOCDEVPRIVATE call from snmpd
>> 	b) add a SIOCGMIIREG ioctl to ipsec
>> 	c) handle the spurious SIOCDEVPRIVATE ioctl more gracefully in ipsec.
>>
>> I've just verified that removing the fallback to SIOCDEVPRIVATE from
>> snmp works as a fix, no more problems with openswan+snmp daemon. What I
>> can't say if this might impact snmpd functionality when used with older
>> kernels/drivers that implement only SIOCDEVPRIVATE.
>>
>> Bye, Martin
>>
>>
> Would it be possible to get more info as to where this stands?
> Maybe the Openswan maintainers can touch base with the Net-snmp
> maintainers and work this out or vice versa.
>
> Ted
>
>
>
> _______________________________________________
> Users mailing list
> Users at openswan.org
> http://lists.openswan.org/mailman/listinfo/users
>

-- 
 	"Non cogitamus, ergo nihil sumus"


More information about the Users mailing list