All,

Were these patches eventually fed into the next iteration of the net-snmp 
release?


_____________________________________________
From:   Hindley Nick
Sent:   13 February 2009 09:34
To:     'Dave Shield'
Cc:     Net-snmp-users@lists.sourceforge.net
Subject:        RE: net-snmp and solaris dynamic reconfiguration

Hi Dave ,

the two patches that you cut seem to have stabilised net-snmp for my zones.

thanks


-----Original Message-----
From: dave.shi...@googlemail.com [mailto:dave.shi...@googlemail.com] On Behalf 
Of Dave Shield
Sent: 27 January 2009 11:15
To: Hindley Nick
Cc: Net-snmp-users@lists.sourceforge.net
Subject: Re: net-snmp and solaris dynamic reconfiguration

2009/1/26 Hindley Nick <nick.hind...@hfbp.co.uk>:
> A few weeks ago I noticed that I had a problem with snmpd core dumping.
> .... which is caused by an attempt to dereference cpu2 which is NULL
>
> (gdb) print cpu2
> $1 = (netsnmp_cpu_info *) 0x0

> Now what I think has happened, is that the cpu... structures have been
> instantiated with a view of what CPUs have been allocated to the zone
> which has subsequently been changed by the solaris dynamic
> reconfiguration.  This then means that when the new processor ID is
> introduced to the zone, its not found and a null pointer is returned.
>
> Does this make sense?

Yes.
The code does assume that the number of CPUs is constant.


> Any ideas how to fix?

One option would simply be to skip any "new" CPUs.
The attached patch is untested, but should handle that.
(Though I'm not sure whether it would work better with 'break'
 or continue - you should experiment).

If you change the 'break' statement to call 'init_cpu_kstat()'
instead, then this should cope with updating the list of CPUs.
Obviously, that's even more untested than the basic patch, but give it a go and 
let us know how you get on.

Dave


=======================================================================
              Scanned for virus infection by Messagelabs 
=======================================================================


------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to