This is a discussion on RE: within the SNMP Coders forums, part of the Networking and Network Related category; This is a multi-part message in MIME format. --===============1767679051== Content-class: urn:content-classes:message Content-Type: multipart/alternative; ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
This is a multi-part message in MIME format.
--===============1767679051== Content-class: urn:content-classes:message Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C6A50E.D0BB24E5" This is a multi-part message in MIME format. ------_=_NextPart_001_01C6A50E.D0BB24E5 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Dave, Many thanks for your quick response. Any idea what the timeframe may be = of such a fix? We have a reasonably urgent need for it.=20 Dana -----Original Message----- From: Dave Shield [mailto:D.T.Shield@csc.liv.ac.uk] Sent: Tue 7/11/2006 5:12 AM To: Dana Heath Cc: net-snmp-coders@lists.sourceforge.net Subject: Re:=20 =20 Dana Heath wrote: > Turns out that when mount points change dynamically, there is a=20 > problem with how the hrStorage table reports these mount points. The=20 > following scenario describes my problem: > > An initial walk of the hrStorage tree returns the following data on my = > box [relevant part copied]: > HOST-RESOURCES-MIB::hrStorageDescr.11 =3D STRING: = /home/dana/mnt/cittio > HOST-RESOURCES-MIB::hrStorageDescr.12 =3D STRING: /fc4 > > Unmounting /fc4 ... Now let's add another mountpoint and examine the=20 > results: > HOST-RESOURCES-MIB::hrStorageDescr.11 =3D STRING: = /home/dana/mnt/cittio > HOST-RESOURCES-MIB::hrStorageDescr.13 =3D STRING: = /home/dana/mnt/chimera > > hold on here, Charlie! what happened to the table entry at index=3D12? = > Of course it was removed, but shouldn't the new mount point take=20 > position 12? > No. Check the MIB description for hrStorageIndex: "A unique value for each logical storage area contained by the host." Note "unique" - that means that different storage areas (in this case=20 disk partitions) should have different index values. /home/dana/mnt/chimera is=20 (presumably) not the same partition as /fc4, so it needs to have a different index. There's code towards the end of = host/hr_filesystem.c:Get_Next_HR_FileSys() explicitly to implement this behaviour. > Let's now examine what happens when we remount /fc4... one would think = > that since index 12 was skipped, it would be re-inserted at position = 12, > That's what ought to happen, certainly. > so let's take a look at the results: > HOST-RESOURCES-MIB::hrStorageDescr.11 =3D STRING: = /home/dana/mnt/cittio > HOST-RESOURCES-MIB::hrStorageDescr.13 =3D STRING: = /home/dana/mnt/chimera > That's definitely a bug. > if I now unmount the previously mounted entry: > HOST-RESOURCES-MIB::hrStorageDescr.11 =3D STRING: = /home/dana/mnt/cittio > HOST-RESOURCES-MIB::hrStorageDescr.12 =3D STRING: /fc4 > and there it is again. This behavior leads me to believe that there is = > a bug in the hrStorage code that is not indicative of a system=20 > problem, but rather the hrStorage code itself dealing with the list=20 > management of the mount points. > I've had a quick look, and think I've spotted the problem. The original implementation returned didn't have the special code for=20 persistent indexes, and simply returned entries from /etc/mtab (or equivalent) in the order that = they appeared there. The index values were strictly increasing, and everything worked fine. With the new persistent index handling, the index values returned from=20 Get_Next_HR_FileSys() can be in "random" order, which confuses the table handling code. I=20 suspect that if you: mount /fc4 mount /home/dana/mnt/chimera umount /fc4 mount /fc4 [so that walking hrStorageDescr skips /fc4], and then manually edit=20 /etc/mtab to move the entry for /fc4 *before* that for /home/dana/mnt/chimera, then things = will display correctly again. That's not a solution to the problem, obviously. We do need to fix the=20 code to handle this properly. Thanks for bringing it to our attention. Dave ------_=_NextPart_001_01C6A50E.D0BB24E5 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"> <HTML> <HEAD> <META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; = charset=3Diso-8859-1"> <META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version = 6.5.7638.1"> <TITLE>RE: </TITLE> </HEAD> <BODY> <!-- Converted from text/plain format --> <P><FONT SIZE=3D2>Dave,<BR> <BR> Many thanks for your quick response. Any idea what the timeframe may be = of such a fix? We have a reasonably urgent need for it.<BR> <BR> Dana<BR> <BR> <BR> -----Original Message-----<BR> From: Dave Shield [<A = HREF=3D"mailto:D.T.Shield@csc.liv.ac.uk">mailto:D. T.Shield@csc.liv.ac.uk<= /A>]<BR> Sent: Tue 7/11/2006 5:12 AM<BR> To: Dana Heath<BR> Cc: net-snmp-coders@lists.sourceforge.net<BR> Subject: Re:<BR> <BR> Dana Heath wrote:<BR> <BR> > Turns out that when mount points change dynamically, there is a<BR> > problem with how the hrStorage table reports these mount points. = The<BR> > following scenario describes my problem:<BR> ><BR> > An initial walk of the hrStorage tree returns the following data on = my<BR> > box [relevant part copied]:<BR> > HOST-RESOURCES-MIB::hrStorageDescr.11 =3D STRING: = /home/dana/mnt/cittio<BR> > HOST-RESOURCES-MIB::hrStorageDescr.12 =3D STRING: /fc4<BR> ><BR> > Unmounting /fc4 ... Now let's add another mountpoint and = examine the<BR> > results:<BR> > HOST-RESOURCES-MIB::hrStorageDescr.11 =3D STRING: = /home/dana/mnt/cittio<BR> > HOST-RESOURCES-MIB::hrStorageDescr.13 =3D STRING: = /home/dana/mnt/chimera<BR> ><BR> > hold on here, Charlie! what happened to the table entry at = index=3D12?<BR> > Of course it was removed, but shouldn't the new mount point = take<BR> > position 12?<BR> ><BR> No.<BR> Check the MIB description for hrStorageIndex:<BR> "A unique value for each logical storage area = contained by the host."<BR> <BR> Note "unique" - that means that different storage areas (in = this case<BR> disk partitions)<BR> should have different index values. /home/dana/mnt/chimera is<BR> (presumably) not the<BR> same partition as /fc4, so it needs to have a different index.<BR> <BR> There's code towards the end of = host/hr_filesystem.c:Get_Next_HR_FileSys()<BR> explicitly to implement this behaviour.<BR> <BR> > Let's now examine what happens when we remount /fc4... one would = think<BR> > that since index 12 was skipped, it would be re-inserted at = position 12,<BR> ><BR> That's what ought to happen, certainly.<BR> <BR> > so let's take a look at the results:<BR> > HOST-RESOURCES-MIB::hrStorageDescr.11 =3D STRING: = /home/dana/mnt/cittio<BR> > HOST-RESOURCES-MIB::hrStorageDescr.13 =3D STRING: = /home/dana/mnt/chimera<BR> ><BR> That's definitely a bug.<BR> <BR> > if I now unmount the previously mounted entry:<BR> > HOST-RESOURCES-MIB::hrStorageDescr.11 =3D STRING: = /home/dana/mnt/cittio<BR> > HOST-RESOURCES-MIB::hrStorageDescr.12 =3D STRING: /fc4<BR> > and there it is again. This behavior leads me to believe that there = is<BR> > a bug in the hrStorage code that is not indicative of a system<BR> > problem, but rather the hrStorage code itself dealing with the = list<BR> > management of the mount points.<BR> ><BR> I've had a quick look, and think I've spotted the problem.<BR> The original implementation returned didn't have the special code = for<BR> persistent indexes, and<BR> simply returned entries from /etc/mtab (or equivalent) in the order = that<BR> they appeared there.<BR> The index values were strictly increasing, and everything worked = fine.<BR> <BR> With the new persistent index handling, the index values returned = from<BR> Get_Next_HR_FileSys()<BR> can be in "random" order, which confuses the table handling = code. I<BR> suspect that if you:<BR> <BR> mount /fc4<BR> mount /home/dana/mnt/chimera<BR> umount /fc4<BR> mount /fc4<BR> <BR> [so that walking hrStorageDescr skips /fc4], and then manually edit<BR> /etc/mtab to move<BR> the entry for /fc4 *before* that for /home/dana/mnt/chimera, then = things<BR> will display<BR> correctly again.<BR> <BR> That's not a solution to the problem, obviously. We do need to fix = the<BR> code to handle<BR> this properly. Thanks for bringing it to our attention.<BR> <BR> Dave<BR> <BR> </FONT> </P> </BODY> </HTML> ------_=_NextPart_001_01C6A50E.D0BB24E5-- --===============1767679051== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=...057&dat=121642 --===============1767679051== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Net-snmp-coders mailing list Net-snmp-coders@lists.sourceforge.net https://lists.sourceforge.net/lists/...et-snmp-coders --===============1767679051==-- |
![]() |
| Thread Tools | |
| Display Modes | |
|
|