Whamcloud - gitweb
LU-12895 tests: stop running tests for SSK and SELinux
[fs/lustre-release.git] / snmp / lustre-snmp.c
index 0473852..3d8bcbc 100644 (file)
  *
  * You should have received a copy of the GNU General Public License
  * version 2 along with this program; If not, see
- * http://www.sun.com/software/products/lustre/docs/GPLv2.pdf
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
+ * http://www.gnu.org/licenses/gpl-2.0.html
  *
  * GPL HEADER END
  */
 #include <pthread.h>
 #include "lustre-snmp.h"
 
+#include <libcfs/util/param.h>
+
+#define LNET_CHECK_INTERVAL 500
+
 /* 
  * clusterFileSystems_variables_oid:
  *   this is the top level oid that we want to register under.  This
@@ -64,100 +64,614 @@ oid clusterFileSystems_variables_oid[] = { 1,3,6,1,4,1,13140 };
 
 
 struct variable7 clusterFileSystems_variables[] = {
-/*  magic number        , variable type , ro/rw , callback fn  , L, oidsuffix */
-
-  /* sytemInformation 2.1.1. */
-  { SYSVERSION          , ASN_OCTET_STR , RONLY , var_clusterFileSystems, 4, { 2,1,1,1 } },
-  { SYSKERNELVERSION    , ASN_OCTET_STR , RONLY , var_clusterFileSystems, 4, { 2,1,1,2 } },
-  { SYSHEALTHCHECK      , ASN_OCTET_STR , RONLY , var_clusterFileSystems, 4, { 2,1,1,3 } },
-  { SYSSTATUS           , ASN_INTEGER   , RWRITE, var_clusterFileSystems, 4, { 2,1,1,4 } },
-
-  /* objectStorageTargets 2.1.2 */
-  { OSDNUMBER           , ASN_UNSIGNED  , RONLY , var_clusterFileSystems, 4, { 2,1,2,1 } },
-
-  /* objectStorageTargets.osdTable.osdEntry 2.1.2.2.1 */
-  { OSDUUID             , ASN_OCTET_STR , RONLY , var_osdTable, 6, { 2,1,2,2,1,2 } },
-  { OSDCOMMONNAME       , ASN_OCTET_STR , RONLY , var_osdTable, 6, { 2,1,2,2,1,3 } },
-  { OSDCAPACITY         , ASN_COUNTER64 , RONLY , var_osdTable, 6, { 2,1,2,2,1,4 } },
-  { OSDFREECAPACITY     , ASN_COUNTER64 , RONLY , var_osdTable, 6, { 2,1,2,2,1,5 } },
-  { OSDOBJECTS          , ASN_COUNTER64 , RONLY , var_osdTable, 6, { 2,1,2,2,1,6 } },
-  { OSDFREEOBJECTS      , ASN_COUNTER64 , RONLY , var_osdTable, 6, { 2,1,2,2,1,7 } },
-
-  /* objectStorageClients 2.1.3 */
-  { OSCNUMBER           , ASN_UNSIGNED  , RONLY , var_clusterFileSystems, 4, { 2,1,3,1 } },
-
-  /* objectStorageClients.oscTable.oscEntry 2.1.3.2.1 */
-  { OSCUUID             , ASN_OCTET_STR , RONLY , var_oscTable, 6, { 2,1,3,2,1,2 } },
-  { OSCCOMMONNAME       , ASN_OCTET_STR , RONLY , var_oscTable, 6, { 2,1,3,2,1,3 } },
-  { OSCOSTSERVERUUID    , ASN_OCTET_STR , RONLY , var_oscTable, 6, { 2,1,3,2,1,4 } },
-  { OSCCAPACITY         , ASN_COUNTER64 , RONLY , var_oscTable, 6, { 2,1,3,2,1,5 } },
-  { OSCFREECAPACITY     , ASN_COUNTER64 , RONLY , var_oscTable, 6, { 2,1,3,2,1,6 } },
-  { OSCOBJECTS          , ASN_COUNTER64 , RONLY , var_oscTable, 6, { 2,1,3,2,1,7 } },
-  { OSCFREEOBJECTS      , ASN_COUNTER64 , RONLY , var_oscTable, 6, { 2,1,3,2,1,8 } },
-
-
-  /* metaDataServers 2.1.4 */
-  { MDDNUMBER           , ASN_UNSIGNED  , RONLY , var_clusterFileSystems, 4, { 2,1,4,1 } },
-
-  /* metaDataServers.mddTable.mddEntry 2.1.4.2.1 */
-  { MDDUUID             , ASN_OCTET_STR , RONLY , var_mdsTable, 6, { 2,1,4,2,1,2 } },
-  { MDDCOMMONNAME       , ASN_OCTET_STR , RONLY , var_mdsTable, 6, { 2,1,4,2,1,3 } },
-  { MDDCAPACITY         , ASN_COUNTER64 , RONLY , var_mdsTable, 6, { 2,1,4,2,1,4 } },
-  { MDDFREECAPACITY     , ASN_COUNTER64 , RONLY , var_mdsTable, 6, { 2,1,4,2,1,5 } },
-  { MDDFILES            , ASN_COUNTER64 , RONLY , var_mdsTable, 6, { 2,1,4,2,1,6 } },
-  { MDDFREEFILES        , ASN_COUNTER64 , RONLY , var_mdsTable, 6, { 2,1,4,2,1,7 } },
-  { MDSNBSAMPLEDREQ     , ASN_COUNTER64 , RONLY , var_mdsNbSampledReq, 4, { 2,1,4,3 } },
-
-  /* metaDataClients 2.1.5 */
-  { MDCNUMBER           , ASN_UNSIGNED  , RONLY , var_clusterFileSystems, 4, { 2,1,5,1 } },
-
-  /* metaDataClients.mdcTable.mdcEntry 2.1.5.2.1 */
-  { MDCUUID             , ASN_OCTET_STR , RONLY , var_mdcTable, 6, { 2,1,5,2,1,2 } },
-  { MDCCOMMONNAME       , ASN_OCTET_STR , RONLY , var_mdcTable, 6, { 2,1,5,2,1,3 } },
-  { MDCMDSSERVERUUID    , ASN_OCTET_STR , RONLY , var_mdcTable, 6, { 2,1,5,2,1,4 } },
-  { MDCCAPACITY         , ASN_COUNTER64 , RONLY , var_mdcTable, 6, { 2,1,5,2,1,5 } },
-  { MDCFREECAPACITY     , ASN_COUNTER64 , RONLY , var_mdcTable, 6, { 2,1,5,2,1,6 } },
-  { MDCOBJECTS          , ASN_COUNTER64 , RONLY , var_mdcTable, 6, { 2,1,5,2,1,7 } },
-  { MDCFREEOBJECTS      , ASN_COUNTER64 , RONLY , var_mdcTable, 6, { 2,1,5,2,1,8 } },
-
-  /* lustreClients 2.1.6 */
-  { CLIMOUNTNUMBER           , ASN_UNSIGNED  , RONLY , var_clusterFileSystems, 4, { 2,1,6,1 } },
-
-  /* lustreClients.cliMountTable.cliMountEntry 2.1.6.2.1 */
-  { CLIUUID             , ASN_OCTET_STR , RONLY , var_cliTable, 6, { 2,1,6,2,1,2 } },
-  { CLICOMMONNAME       , ASN_OCTET_STR , RONLY , var_cliTable, 6, { 2,1,6,2,1,3 } },
-  { CLIMDCUUID          , ASN_OCTET_STR , RONLY , var_cliTable, 6, { 2,1,6,2,1,4 } },
-  { CLIMDCCOMMONNAME    , ASN_OCTET_STR , RONLY , var_cliTable, 6, { 2,1,6,2,1,5 } },
-  { CLIUSESLOV          , ASN_INTEGER ,   RONLY , var_cliTable, 6, { 2,1,6,2,1,6 } },
-  { CLILOVUUID          , ASN_OCTET_STR , RONLY , var_cliTable, 6, { 2,1,6,2,1,7 } },
-  { CLILOVCOMMONNAME    , ASN_OCTET_STR , RONLY , var_cliTable, 6, { 2,1,6,2,1,8 } },
-
-  /* logicalObjectVolume 2.1.7 */
-  { LOVNUMBER           , ASN_UNSIGNED  , RONLY , var_clusterFileSystems, 4, { 2,1,7,1 } },
-
-  /* logicalObjectVolume.osdTable.lovTable 2.1.2.2.1 */
-  { LOVUUID             , ASN_OCTET_STR , RONLY , var_lovTable, 6, { 2,1,7,2,1,2 } },
-  { LOVCOMMONNAME       , ASN_OCTET_STR , RONLY , var_lovTable, 6, { 2,1,7,2,1,3 } },
-  { LOVNUMOBD           , ASN_UNSIGNED ,  RONLY , var_lovTable, 6, { 2,1,7,2,1,4 } },
-  { LOVNUMACTIVEOBD     , ASN_UNSIGNED ,  RONLY , var_lovTable, 6, { 2,1,7,2,1,5 } },
-  { LOVCAPACITY         , ASN_COUNTER64 , RONLY , var_lovTable, 6, { 2,1,7,2,1,6 } },
-  { LOVFREECAPACITY     , ASN_COUNTER64 , RONLY , var_lovTable, 6, { 2,1,7,2,1,7 } },
-  { LOVFILES            , ASN_COUNTER64 , RONLY , var_lovTable, 6, { 2,1,7,2,1,8 } },
-  { LOVFREEFILES        , ASN_COUNTER64 , RONLY , var_lovTable, 6, { 2,1,7,2,1,9 } },
-  { LOVSTRIPECOUNT      , ASN_UNSIGNED ,  RONLY , var_lovTable, 6, { 2,1,7,2,1,10} },
-  { LOVSTRIPEOFFSET     , ASN_UNSIGNED ,  RONLY , var_lovTable, 6, { 2,1,7,2,1,11} },
-  { LOVSTRIPESIZE       , ASN_UNSIGNED ,  RONLY , var_lovTable, 6, { 2,1,7,2,1,12} },
-  { LOVSTRIPETYPE       , ASN_UNSIGNED ,  RONLY , var_lovTable, 6, { 2,1,7,2,1,13} },
-
-  /* lustreLDLM 2.1.8 */
-  { LDLMNUMBER          , ASN_UNSIGNED  , RONLY , var_clusterFileSystems, 4, { 2,1,8,1 } },
-
-  /* lustreLDLM.ldlmTable.ldlmEntry 2.1.8.2.1 */
-  { LDLMNAMESPACE       , ASN_OCTET_STR , RONLY , var_ldlmTable, 6, { 2,1,8,2,1,2 } },
-  { LDLMLOCKCOUNT       , ASN_UNSIGNED  , RONLY , var_ldlmTable, 6, { 2,1,8,2,1,3 } },
-  { LDLMUNUSEDLOCKCOUNT , ASN_UNSIGNED  , RONLY , var_ldlmTable, 6, { 2,1,8,2,1,4 } },
-  { LDLMRESOURCECOUNT   , ASN_UNSIGNED  , RONLY , var_ldlmTable, 6, { 2,1,8,2,1,5 } },
-
+       /* systemInformation 2.1.1. */
+       {
+               .magic          = SYSVERSION,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 1, 1 }
+       },
+       {
+               .magic          = SYSKERNELVERSION,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 1, 2 }
+       },
+       {
+               .magic          = SYSHEALTHCHECK,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 1, 3 }
+       },
+       {
+               .magic          = SYSSTATUS,
+               .type           = ASN_INTEGER,
+               .acl            = RWRITE,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 1, 4 }
+       },
+
+       /* objectStorageTargets 2.1.2 */
+       {
+               .magic          = OSDNUMBER,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 2, 1 }
+       },
+
+       /* objectStorageTargets.osdTable.osdEntry 2.1.2.2.1 */
+       {
+               .magic          = OSDUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_osdTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 2, 2, 1, 2 }
+       },
+       {
+               .magic          = OSDCOMMONNAME,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_osdTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 2, 2, 1, 3 }
+       },
+       {
+               .magic          = OSDCAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_osdTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 2, 2, 1, 4 }
+       },
+       {
+               .magic          = OSDFREECAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_osdTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 2, 2, 1, 5 }
+       },
+       {
+               .magic          = OSDOBJECTS,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_osdTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 2, 2, 1, 6 }
+       },
+       {
+               .magic          = OSDFREEOBJECTS,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_osdTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 2, 2, 1, 7 }
+       },
+
+       /* objectStorageClients 2.1.3 */
+       {
+               .magic          = OSCNUMBER,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 3, 1 }
+       },
+
+       /* objectStorageClients.oscTable.oscEntry 2.1.3.2.1 */
+       {
+               .magic          = OSCUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_oscTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 3, 2, 1, 2 }
+       },
+       {
+               .magic          = OSCCOMMONNAME,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_oscTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 3, 2, 1, 3 }
+       },
+       {
+               .magic          = OSCOSTSERVERUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_oscTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 3, 2, 1, 4 }
+       },
+       {
+               .magic          = OSCCAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_oscTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 3, 2, 1, 5 }
+       },
+       {
+               .magic          = OSCFREECAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_oscTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 3, 2, 1, 6 }
+       },
+       {
+               .magic          = OSCOBJECTS,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_oscTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 3, 2, 1, 7 }
+       },
+       {
+               .magic          = OSCFREEOBJECTS,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_oscTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 3, 2, 1, 8 }
+       },
+
+
+       /* metaDataServers 2.1.4 */
+       {
+               .magic          = MDDNUMBER,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 4, 1 }
+       },
+
+       /* metaDataServers.mddTable.mddEntry 2.1.4.2.1 */
+       {
+               .magic          = MDDUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_mdsTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 4, 2, 1, 2 }
+       },
+       {
+               .magic          = MDDCOMMONNAME,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_mdsTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 4, 2, 1, 3 }
+       },
+       {
+               .magic          = MDDCAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdsTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 4, 2, 1, 4 }
+       },
+       {
+               .magic          = MDDFREECAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdsTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 4, 2, 1, 5 }
+       },
+       {
+               .magic          = MDDFILES,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdsTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 4, 2, 1, 6 }
+       },
+       {
+               .magic          = MDDFREEFILES,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdsTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 4, 2, 1, 7 }
+       },
+       {
+               .magic          = MDSNBSAMPLEDREQ,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdsNbSampledReq,
+               .namelen        = 4,
+               .name           = { 2, 1, 4, 3 }
+       },
+
+       /* metaDataClients 2.1.5 */
+       {
+               .magic          = MDCNUMBER,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 5, 1 }
+       },
+
+       /* metaDataClients.mdcTable.mdcEntry 2.1.5.2.1 */
+       {
+               .magic          = MDCUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_mdcTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 5, 2, 1, 2 }
+       },
+       {
+               .magic          = MDCCOMMONNAME,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_mdcTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 5, 2, 1, 3 }
+       },
+       {
+               .magic          = MDCMDSSERVERUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_mdcTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 5, 2, 1, 4 }
+       },
+       {
+               .magic          = MDCCAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdcTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 5, 2, 1, 5 }
+       },
+       {
+               .magic          = MDCFREECAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdcTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 5, 2, 1, 6 }
+       },
+       {
+               .magic          = MDCOBJECTS,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdcTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 5, 2, 1, 7 }
+       },
+       {
+               .magic          = MDCFREEOBJECTS,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_mdcTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 5, 2, 1, 8 }
+       },
+
+       /* lustreClients 2.1.6 */
+       {
+               .magic          = CLIMOUNTNUMBER,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 6, 1 }
+       },
+
+       /* lustreClients.cliMountTable.cliMountEntry 2.1.6.2.1 */
+       {
+               .magic          = CLIUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_cliTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 6, 2, 1, 2 }
+       },
+       {
+               .magic          = CLICOMMONNAME,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_cliTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 6, 2, 1, 3 }
+       },
+       {
+               .magic          = CLIMDCUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_cliTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 6, 2, 1, 4 }
+       },
+       {
+               .magic          = CLIMDCCOMMONNAME,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_cliTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 6, 2, 1, 5 }
+       },
+       {
+               .magic          = CLIUSESLOV,
+               .type           = ASN_INTEGER,
+               .acl            = RONLY,
+               .findVar        = var_cliTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 6, 2, 1, 6 }
+       },
+       {
+               .magic          = CLILOVUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_cliTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 6, 2, 1, 7 }
+       },
+       {
+               .magic          = CLILOVCOMMONNAME,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_cliTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 6, 2, 1, 8 }
+       },
+
+       /* logicalObjectVolume 2.1.7 */
+       {
+               .magic          = LOVNUMBER,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 7, 1 }
+       },
+
+       /* logicalObjectVolume.osdTable.lovTable 2.1.7.2.1 */
+       {
+               .magic          = LOVUUID,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 2 }
+       },
+       {
+               .magic          = LOVCOMMONNAME,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 3 }
+       },
+       {
+               .magic          = LOVNUMOBD,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 4 }
+       },
+       {
+               .magic          = LOVNUMACTIVEOBD,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 5 }
+       },
+       {
+               .magic          = LOVCAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 6 }
+       },
+       {
+               .magic          = LOVFREECAPACITY,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 7 }
+       },
+       {
+               .magic          = LOVFILES,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 8 }
+       },
+       {
+               .magic          = LOVFREEFILES,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 9 }
+       },
+       {
+               .magic          = LOVSTRIPECOUNT,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 10}
+       },
+       {
+               .magic          = LOVSTRIPEOFFSET,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 11}
+       },
+       {
+               .magic          = LOVSTRIPESIZE,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 12}
+       },
+       {
+               .magic          = LOVSTRIPETYPE,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lovTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 7, 2, 1, 13}
+       },
+
+       /* lustreLDLM 2.1.8 */
+       {
+               .magic          = LDLMNUMBER,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_clusterFileSystems,
+               .namelen        = 4,
+               .name           = { 2, 1, 8, 1 }
+       },
+
+       /* lustreLDLM.ldlmTable.ldlmEntry 2.1.8.2.1 */
+       {
+               .magic          = LDLMNAMESPACE,
+               .type           = ASN_OCTET_STR,
+               .acl            = RONLY,
+               .findVar        = var_ldlmTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 8, 2, 1, 2 }
+       },
+       {
+               .magic          = LDLMLOCKCOUNT,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_ldlmTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 8, 2, 1, 3 }
+       },
+       {
+               .magic          = LDLMUNUSEDLOCKCOUNT,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_ldlmTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 8, 2, 1, 4 }
+       },
+       {
+               .magic          = LDLMRESOURCECOUNT,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_ldlmTable,
+               .namelen        = 6,
+               .name           = { 2, 1, 8, 2, 1, 5 }
+       },
+
+       /* lnetInformation 2.1.9 */
+       {
+               .magic          = LNETMSGSALLOC,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 1 }
+       },
+       {
+               .magic          = LNETMSGSMAX,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 2 }
+       },
+       {
+               .magic          = LNETERRORS,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 3 }
+       },
+       {
+               .magic          = LNETSENDCOUNT,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 4 }
+       },
+       {
+               .magic          = LNETRECVCOUNT,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 5 }
+       },
+       {
+               .magic          = LNETROUTECOUNT,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 6 }
+       },
+       {
+               .magic          = LNETDROPCOUNT,
+               .type           = ASN_UNSIGNED,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 7 }
+       },
+       {
+               .magic          = LNETSENDBYTES,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 8 }
+       },
+       {
+               .magic          = LNETRECVBYTES,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 9 }
+       },
+       {
+               .magic          = LNETROUTEBYTES,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 10 }
+       },
+       {
+               .magic          = LNETDROPBYTES,
+               .type           = ASN_COUNTER64,
+               .acl            = RONLY,
+               .findVar        = var_lnetInformation,
+               .namelen        = 4,
+               .name           = { 2, 1, 9, 11 }
+       },
 };
 
 /*****************************************************************************
@@ -173,13 +687,14 @@ struct variable7 clusterFileSystems_variables[] = {
  
 void init_lustresnmp(void) {
 
-  /* register ourselves with the agent to handle our mib tree */
-  REGISTER_MIB("clusterFileSystems", clusterFileSystems_variables, variable7,
-               clusterFileSystems_variables_oid);
-               
-   initilize_trap_handler();
+       /* register ourselves with the agent to handle our mib tree */
+       REGISTER_MIB("clusterFileSystems",
+                    clusterFileSystems_variables, variable7,
+                    clusterFileSystems_variables_oid);
+
+       initialize_trap_handler();
 
-  DEBUGMSGTL(("lsnmpd", "%s %s \n", __FUNCTION__, "Initialization Done"));
+       DEBUGMSGTL(("lsnmpd", "%s %s\n", __func__, "Initialization Done"));
 }
 
 /*****************************************************************************
@@ -195,13 +710,14 @@ void init_lustresnmp(void) {
 
 void deinit_lustresnmp(void) {
 
-  /* deregister ourselves with the agent */
-  unregister_mib(clusterFileSystems_variables_oid,
-    sizeof(clusterFileSystems_variables_oid)/sizeof(clusterFileSystems_variables_oid));
-  
-  terminate_trap_handler();
-  
-  DEBUGMSGTL(("lsnmpd", "%s %s \n", __FUNCTION__, "Termination Done"));
+       /* deregister ourselves with the agent */
+       unregister_mib(clusterFileSystems_variables_oid,
+                      sizeof(clusterFileSystems_variables_oid)/
+                      sizeof(clusterFileSystems_variables_oid));
+
+       terminate_trap_handler();
+
+       DEBUGMSGTL(("lsnmpd", "%s %s\n", __func__, "Termination Done"));
 }
 
 /*****************************************************************************
@@ -222,7 +738,7 @@ var_clusterFileSystems(struct variable *vp,
   static long long_ret;
   static u_long ulong_ret;
   static unsigned char string[SPRINT_MAX_LEN];
-  char file_path[MAX_PATH_SIZE];
+  glob_t path;
   uint32_t num;
   char *dir_list;
 
@@ -237,23 +753,35 @@ var_clusterFileSystems(struct variable *vp,
   switch(vp->magic) {
 
     case SYSVERSION:
-        sprintf(file_path, "%s%s", LUSTRE_PATH,"version");
-        if( SUCCESS != read_string(file_path, (char *)string,sizeof(string)))
+        if (cfs_get_param_paths(&path, "version") != 0)
+            return NULL;
+        if( SUCCESS != read_string(path.gl_pathv[0], (char *)string,sizeof(string))){
+            cfs_free_param_data(&path);
             return NULL;
+        }
+        cfs_free_param_data(&path);
         *var_len = strlen((char *)string);
         return (unsigned char *) string;
 
     case SYSKERNELVERSION:
-        sprintf(file_path, "%s%s", LUSTRE_PATH,"kernel_version");
-        if( SUCCESS != read_string(file_path, (char *)string,sizeof(string)))
+        if (cfs_get_param_paths(&path, "kernel_version") != 0)
+            return NULL;
+        if( SUCCESS != read_string(path.gl_pathv[0], (char *)string,sizeof(string))){
+            cfs_free_param_data(&path);
             return NULL;
+        }
+        cfs_free_param_data(&path);
         *var_len = strlen((char *)string);
         return (unsigned char *) string;
 
     case SYSHEALTHCHECK:
-        sprintf(file_path, "%s%s", LUSTRE_PATH,FILENAME_SYSHEALTHCHECK);
-        if( SUCCESS != read_string(file_path, (char *)string,sizeof(string)))
+        if (cfs_get_param_paths(&path, "health_check") != 0)
             return NULL;
+        if( SUCCESS != read_string(path.gl_pathv[0], (char *)string,sizeof(string))){
+            cfs_free_param_data(&path);
+            return NULL;
+        }
+        cfs_free_param_data(&path);
         *var_len = strlen((char*)string);
         return (unsigned char *) string;
 
@@ -265,57 +793,92 @@ var_clusterFileSystems(struct variable *vp,
         return NULL;
                       
     case OSDNUMBER:
-        if( 0 == (dir_list = get_file_list(OSD_PATH, DIR_TYPE, &num)))
+        if (cfs_get_param_paths(&path, "obdfilter") != 0)
+            return NULL;
+        if( 0 == (dir_list = get_file_list(path.gl_pathv[0], DIR_TYPE, &num))){
+            cfs_free_param_data(&path);
             return NULL;
-        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",OSD_PATH,num));  
+        }
+        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",path.gl_pathv[0],num));
+        cfs_free_param_data(&path);
         ulong_ret =  num;
         free(dir_list);
         return (unsigned char *) &ulong_ret;
 
     case OSCNUMBER:
-        if( 0 == (dir_list = get_file_list(OSC_PATH, DIR_TYPE, &num)))
+        if (cfs_get_param_paths(&path, "osc") != 0)
+            return NULL;
+        if( 0 == (dir_list = get_file_list(path.gl_pathv[0], DIR_TYPE, &num))){
+            cfs_free_param_data(&path);
             return NULL;
-        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",OSC_PATH,num));  
+        }
+        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",path.gl_pathv[0],num));
+        cfs_free_param_data(&path);
         ulong_ret =  num;
         free(dir_list);
         return (unsigned char *) &ulong_ret;
 
     case MDDNUMBER:
-        if( 0 == (dir_list = get_file_list(MDS_PATH, DIR_TYPE, &num)))
+        if (cfs_get_param_paths(&path, "mds") != 0)
             return NULL;
-        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",MDS_PATH,num));  
+        if( 0 == (dir_list = get_file_list(path.gl_pathv[0], DIR_TYPE, &num))){
+            cfs_free_param_data(&path);
+            return NULL;
+        }
+        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",path.gl_pathv[0],num));
+        cfs_free_param_data(&path);
         ulong_ret =  num;
         free(dir_list);
         return (unsigned char *) &ulong_ret;
 
     case MDCNUMBER:
-        if( 0 == (dir_list = get_file_list(MDC_PATH, DIR_TYPE, &num)))
+        if (cfs_get_param_paths(&path, "mdc") != 0)
+            return NULL;
+        if( 0 == (dir_list = get_file_list(path.gl_pathv[0], DIR_TYPE, &num))){
+            cfs_free_param_data(&path);
             return NULL;
-        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",MDC_PATH,num));  
+        }
+        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",path.gl_pathv[0],num));
+        cfs_free_param_data(&path);
         ulong_ret =  num;
         free(dir_list);
         return (unsigned char *) &ulong_ret;
 
     case CLIMOUNTNUMBER:
-        if( 0 == (dir_list = get_file_list(CLIENT_PATH, DIR_TYPE, &num)))
+        if (cfs_get_param_paths(&path, "llite") != 0)
+            return NULL;
+        if( 0 == (dir_list = get_file_list(path.gl_pathv[0], DIR_TYPE, &num))){
+            cfs_free_param_data(&path);
             return NULL;
-        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",CLIENT_PATH,num));  
+        }
+        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",path.gl_pathv[0],num));
+        cfs_free_param_data(&path);
         ulong_ret =  num;
         free(dir_list);
         return (unsigned char *) &ulong_ret;
 
     case LOVNUMBER:
-        if( 0 == (dir_list = get_file_list(LOV_PATH, DIR_TYPE, &num)))
+        if (cfs_get_param_paths(&path, "lov") != 0)
             return NULL;
-        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",LOV_PATH,num));  
+        if( 0 == (dir_list = get_file_list(path.gl_pathv[0], DIR_TYPE, &num))){
+            cfs_free_param_data(&path);
+            return NULL;
+        }
+        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",path.gl_pathv[0],num));
+        cfs_free_param_data(&path);
         ulong_ret =  num;
         free(dir_list);
         return (unsigned char *) &ulong_ret;
 
     case LDLMNUMBER:
-        if( 0 == (dir_list = get_file_list(LDLM_PATH, DIR_TYPE, &num)))
+        if (cfs_get_param_paths(&path, "ldlm/namespaces") != 0)
+            return NULL;
+        if( 0 == (dir_list = get_file_list(path.gl_pathv[0], DIR_TYPE, &num))){
+            cfs_free_param_data(&path);
             return NULL;
-        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",LDLM_PATH,num));  
+        }
+        DEBUGMSGTL(("lsnmpd","num(%s)=%d\n",path.gl_pathv[0],num));
+        cfs_free_param_data(&path);
         ulong_ret =  num;
         free(dir_list);
         return (unsigned char *) &ulong_ret;
@@ -326,15 +889,42 @@ var_clusterFileSystems(struct variable *vp,
   return NULL;
 }
 
-struct oid_table osd_table[] =
-{ 
-    { OSDUUID,FILENAME_UUID,oid_table_string_handler},
-    { OSDCOMMONNAME,0,oid_table_obj_name_handler},
-    { OSDCAPACITY,FILENAME_KBYTES_TOTAL, oid_table_c64_kb_handler},
-    { OSDFREECAPACITY,FILENAME_KBYTES_FREE, oid_table_c64_kb_handler},
-    { OSDOBJECTS,FILENAME_FILES_TOTAL, oid_table_c64_kb_handler},
-    { OSDFREEOBJECTS,FILENAME_FILES_FREE, oid_table_c64_kb_handler},
-    { 0,0,0 } /*End of table*/
+struct oid_table osd_table[] = {
+       {
+               .magic          = OSDUUID,
+               .name           = FILENAME_UUID,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = OSDCOMMONNAME,
+               .name           = NULL,
+               .fhandler       = oid_table_obj_name_handler
+       },
+       {
+               .magic          = OSDCAPACITY,
+               .name           = FILENAME_KBYTES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = OSDFREECAPACITY,
+               .name           = FILENAME_KBYTES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = OSDOBJECTS,
+               .name           = FILENAME_FILES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = OSDFREEOBJECTS,
+               .name           = FILENAME_FILES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = 0,
+               .name           = NULL,
+               .fhandler       = NULL
+       } /*End of table*/
 };
 
 
@@ -350,20 +940,59 @@ var_osdTable(struct variable *vp,
            size_t  *var_len,
            WriteMethod **write_method)
 {
-    return var_genericTable(vp,name,length,exact,var_len,write_method,
-        OSD_PATH,osd_table);
+    unsigned char *table;
+    glob_t path;
+
+    if (cfs_get_param_paths(&path, "obdfilter") != 0)
+        return NULL;
+
+    table = var_genericTable(vp,name,length,exact,var_len,write_method,
+                             path.gl_pathv[0],osd_table);
+    cfs_free_param_data(&path);
+    return table;
 }
 
-struct oid_table osc_table[] =
-{ 
-    { OSCUUID,FILENAME_UUID,oid_table_string_handler},
-    { OSCCOMMONNAME,0,oid_table_obj_name_handler},
-    { OSCOSTSERVERUUID,"ost_server_uuid",oid_table_string_handler},
-    { OSCCAPACITY,FILENAME_KBYTES_TOTAL, oid_table_c64_kb_handler},
-    { OSCFREECAPACITY,FILENAME_KBYTES_FREE, oid_table_c64_kb_handler},
-    { OSCOBJECTS,FILENAME_FILES_TOTAL, oid_table_c64_kb_handler},
-    { OSCFREEOBJECTS,FILENAME_FILES_FREE, oid_table_c64_kb_handler},
-    { 0,0,0 } /*End of table*/
+struct oid_table osc_table[] = {
+       {
+               .magic          = OSCUUID,
+               .name           = FILENAME_UUID,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = OSCCOMMONNAME,
+               .name           = NULL,
+               .fhandler       = oid_table_obj_name_handler
+       },
+       {
+               .magic          = OSCOSTSERVERUUID,
+               .name           = "ost_server_uuid",
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = OSCCAPACITY,
+               .name           = FILENAME_KBYTES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = OSCFREECAPACITY,
+               .name           = FILENAME_KBYTES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = OSCOBJECTS,
+               .name           = FILENAME_FILES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = OSCFREEOBJECTS,
+               .name           = FILENAME_FILES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = 0,
+               .name           = NULL,
+               .fhandler       = NULL
+       } /*End of table*/
 };
 
 /*****************************************************************************
@@ -378,19 +1007,54 @@ var_oscTable(struct variable *vp,
            size_t  *var_len,
            WriteMethod **write_method)
 {
-    return var_genericTable(vp,name,length,exact,var_len,write_method,
-        OSC_PATH,osc_table);
+    unsigned char *table;
+    glob_t path;
+
+    if (cfs_get_param_paths(&path, "osc") != 0)
+        return NULL;
+
+    table = var_genericTable(vp,name,length,exact,var_len,write_method,
+                             path.gl_pathv[0],osd_table);
+    cfs_free_param_data(&path);
+    return table;
 }
 
-struct oid_table mds_table[] =
-{ 
-    { MDDUUID,FILENAME_UUID,oid_table_string_handler},
-    { MDDCOMMONNAME,0,oid_table_obj_name_handler},
-    { MDDCAPACITY,FILENAME_KBYTES_TOTAL, oid_table_c64_kb_handler},
-    { MDDFREECAPACITY,FILENAME_KBYTES_FREE, oid_table_c64_kb_handler},
-    { MDDFILES,FILENAME_FILES_TOTAL, oid_table_c64_kb_handler},
-    { MDDFREEFILES,FILENAME_FILES_FREE, oid_table_c64_kb_handler},
-    { 0,0,0 } /*End of table*/
+struct oid_table mds_table[] = {
+       {
+               .magic          = MDDUUID,
+               .name           = FILENAME_UUID,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = MDDCOMMONNAME,
+               .name           = NULL,
+               .fhandler       = oid_table_obj_name_handler
+       },
+       {
+               .magic          = MDDCAPACITY,
+               .name           = FILENAME_KBYTES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = MDDFREECAPACITY,
+               .name           = FILENAME_KBYTES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = MDDFILES,
+               .name           = FILENAME_FILES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = MDDFREEFILES,
+               .name           = FILENAME_FILES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = 0,
+               .name           = NULL,
+               .fhandler       = NULL
+       } /*End of table*/
 };
 
 /*****************************************************************************
@@ -405,20 +1069,59 @@ var_mdsTable(struct variable *vp,
            size_t  *var_len,
            WriteMethod **write_method)
 {
-    return var_genericTable(vp,name,length,exact,var_len,write_method,
-        MDS_PATH,mds_table);
+    unsigned char *table;
+    glob_t path;
+
+    if (cfs_get_param_paths(&path, "mds") != 0)
+        return NULL;
+
+    table = var_genericTable(vp,name,length,exact,var_len,write_method,
+                             path.gl_pathv[0],osd_table);
+    cfs_free_param_data(&path);
+    return table;
 }
 
-struct oid_table mdc_table[] =
-{ 
-    { MDCUUID,FILENAME_UUID,oid_table_string_handler},
-    { MDCCOMMONNAME,0,oid_table_obj_name_handler},
-    { MDCMDSSERVERUUID,"mds_server_uuid",oid_table_string_handler},
-    { MDCCAPACITY,FILENAME_KBYTES_TOTAL, oid_table_c64_kb_handler},
-    { MDCFREECAPACITY,FILENAME_KBYTES_FREE, oid_table_c64_kb_handler},
-    { MDCOBJECTS,FILENAME_FILES_TOTAL, oid_table_c64_kb_handler},
-    { MDCFREEOBJECTS,FILENAME_FILES_FREE, oid_table_c64_kb_handler},
-    { 0,0,0 } /*End of table*/
+struct oid_table mdc_table[] = {
+       {
+               .magic          = MDCUUID,
+               .name           = FILENAME_UUID,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = MDCCOMMONNAME,
+               .name           = NULL,
+               .fhandler       = oid_table_obj_name_handler
+       },
+       {
+               .magic          = MDCMDSSERVERUUID,
+               .name           = "mds_server_uuid",
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = MDCCAPACITY,
+               .name           = FILENAME_KBYTES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = MDCFREECAPACITY,
+               .name           = FILENAME_KBYTES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = MDCOBJECTS,
+               .name           = FILENAME_FILES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = MDCFREEOBJECTS,
+               .name           = FILENAME_FILES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = 0,
+               .name           = NULL,
+               .fhandler       = NULL
+       } /*End of table*/
 };
 
 
@@ -434,21 +1137,59 @@ var_mdcTable(struct variable *vp,
            size_t  *var_len,
            WriteMethod **write_method)
 {
-    return var_genericTable(vp,name,length,exact,var_len,write_method,
-        MDC_PATH,mdc_table);
-}
+    unsigned char *table;
+    glob_t path;
+
+    if (cfs_get_param_paths(&path, "mdc") != 0)
+        return NULL;
 
+    table = var_genericTable(vp,name,length,exact,var_len,write_method,
+                             path.gl_pathv[0],osd_table);
+    cfs_free_param_data(&path);
+    return table;
+}
 
-struct oid_table cli_table[] =
-{ 
-    { CLIUUID,FILENAME_UUID,oid_table_string_handler},
-    { CLICOMMONNAME,0,oid_table_obj_name_handler},
-    { CLIMDCUUID,"mdc/" FILENAME_UUID,oid_table_string_handler},
-    { CLIMDCCOMMONNAME,"mdc/" FILENAME_COMMON_NAME,oid_table_string_handler},
-    { CLIUSESLOV,"lov/",oid_table_is_directory_handler},
-    { CLILOVUUID,"lov/" FILENAME_UUID,oid_table_string_handler},
-    { CLILOVCOMMONNAME,"lov/" FILENAME_COMMON_NAME,oid_table_string_handler},
-    { 0,0,0 } /*End of table*/
+struct oid_table cli_table[] = {
+       {
+               .magic          = CLIUUID,
+               .name           = FILENAME_UUID,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = CLICOMMONNAME,
+               .name           = NULL,
+               .fhandler       = oid_table_obj_name_handler
+       },
+       {
+               .magic          = CLIMDCUUID,
+               .name           = "mdc/" FILENAME_UUID,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = CLIMDCCOMMONNAME,
+               .name           = "mdc/" FILENAME_COMMON_NAME,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = CLIUSESLOV,
+               .name           = "lov/",
+               .fhandler       = oid_table_is_directory_handler
+       },
+       {
+               .magic          = CLILOVUUID,
+               .name           = "lov/" FILENAME_UUID,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = CLILOVCOMMONNAME,
+               .name           = "lov/" FILENAME_COMMON_NAME,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = 0,
+               .name           = NULL,
+               .fhandler       = NULL
+       } /*End of table*/
 };
 
 /*****************************************************************************
@@ -463,26 +1204,84 @@ var_cliTable(struct variable *vp,
            size_t  *var_len,
            WriteMethod **write_method)
 {
-    return var_genericTable(vp,name,length,exact,var_len,write_method,
-        CLIENT_PATH,cli_table);
-}
+    unsigned char *table;
+    glob_t path;
+
+    if (cfs_get_param_paths(&path, "llite") != 0)
+        return NULL;
 
+    table = var_genericTable(vp,name,length,exact,var_len,write_method,
+                             path.gl_pathv[0],osd_table);
+    cfs_free_param_data(&path);
+    return table;
+}
 
-struct oid_table lov_table[] =
-{ 
-    { LOVUUID,FILENAME_UUID,oid_table_string_handler},
-    { LOVCOMMONNAME,0,oid_table_obj_name_handler},
-    { LOVNUMOBD,"numobd", oid_table_ulong_handler},
-    { LOVNUMACTIVEOBD,"activeobd", oid_table_ulong_handler},
-    { LOVCAPACITY,FILENAME_KBYTES_TOTAL, oid_table_c64_kb_handler},
-    { LOVFREECAPACITY,FILENAME_KBYTES_FREE, oid_table_c64_kb_handler},
-    { LOVFILES,FILENAME_FILES_TOTAL, oid_table_c64_kb_handler},
-    { LOVFREEFILES,FILENAME_FILES_FREE, oid_table_c64_kb_handler},
-    { LOVSTRIPECOUNT,"stripecount", oid_table_ulong_handler},
-    { LOVSTRIPEOFFSET,"stripeoffset", oid_table_ulong_handler},
-    { LOVSTRIPESIZE,"stripesize", oid_table_ulong_handler},
-    { LOVSTRIPETYPE,"stripetype", oid_table_ulong_handler},
-    { 0,0,0 } /*End of table*/
+struct oid_table lov_table[] = {
+       {
+               .magic          = LOVUUID,
+               .name           = FILENAME_UUID,
+               .fhandler       = oid_table_string_handler
+       },
+       {
+               .magic          = LOVCOMMONNAME,
+               .name           = NULL,
+               .fhandler       = oid_table_obj_name_handler
+       },
+       {
+               .magic          = LOVNUMOBD,
+               .name           = "numobd",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = LOVNUMACTIVEOBD,
+               .name           = "activeobd",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = LOVCAPACITY,
+               .name           = FILENAME_KBYTES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = LOVFREECAPACITY,
+               .name           = FILENAME_KBYTES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = LOVFILES,
+               .name           = FILENAME_FILES_TOTAL,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = LOVFREEFILES,
+               .name           = FILENAME_FILES_FREE,
+               .fhandler       = oid_table_c64_kb_handler
+       },
+       {
+               .magic          = LOVSTRIPECOUNT,
+               .name           = "stripecount",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = LOVSTRIPEOFFSET,
+               .name           = "stripeoffset",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = LOVSTRIPESIZE,
+               .name           = "stripesize",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = LOVSTRIPETYPE,
+               .name           = "stripetype",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = 0,
+               .name           = NULL,
+               .fhandler       = NULL
+       } /*End of table*/
 };
 
 
@@ -498,17 +1297,44 @@ var_lovTable(struct variable *vp,
            size_t  *var_len,
            WriteMethod **write_method)
 {
-    return var_genericTable(vp,name,length,exact,var_len,write_method,
-        LOV_PATH,lov_table);
+    unsigned char *table;
+    glob_t path;
+
+    if (cfs_get_param_paths(&path, "lov") != 0)
+        return NULL;
+
+    table = var_genericTable(vp,name,length,exact,var_len,write_method,
+                             path.gl_pathv[0],osd_table);
+    cfs_free_param_data(&path);
+    return table;
 }
 
-struct oid_table ldlm_table[] =
-{ 
-    { LDLMNAMESPACE,0,oid_table_obj_name_handler},
-    { LDLMLOCKCOUNT,"lock_count", oid_table_ulong_handler},
-    { LDLMUNUSEDLOCKCOUNT,"lock_unused_count", oid_table_ulong_handler},
-    { LDLMRESOURCECOUNT,"resource_count", oid_table_ulong_handler},
-    { 0,0,0 } /*End of table*/
+struct oid_table ldlm_table[] = {
+       {
+               .magic          = LDLMNAMESPACE,
+               .name           = NULL,
+               .fhandler       = oid_table_obj_name_handler
+       },
+       {
+               .magic          = LDLMLOCKCOUNT,
+               .name           = "lock_count",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = LDLMUNUSEDLOCKCOUNT,
+               .name           = "lock_unused_count",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = LDLMRESOURCECOUNT,
+               .name           = "resource_count",
+               .fhandler       = oid_table_ulong_handler
+       },
+       {
+               .magic          = 0,
+               .name           = NULL,
+               .fhandler       = NULL
+       } /*End of table*/
 };
 
 
@@ -524,10 +1350,111 @@ var_ldlmTable(struct variable *vp,
            size_t  *var_len,
            WriteMethod **write_method)
 {
-    return var_genericTable(vp,name,length,exact,var_len,write_method,
-        LDLM_PATH,ldlm_table);
+    unsigned char *table;
+    glob_t path;
+
+    if (cfs_get_param_paths(&path, "ldlm/namespaces") != 0)
+        return NULL;
+
+    table = var_genericTable(vp,name,length,exact,var_len,write_method,
+                             path.gl_pathv[0],osd_table);
+    cfs_free_param_data(&path);
+    return table;
 }
 
+/*****************************************************************************
+ * Function: var_lnetInformation
+ *
+ ****************************************************************************/
+unsigned char *
+var_lnetInformation(struct variable *vp,
+                    oid             *name,
+                    size_t          *length,
+                    int              exact,
+                    size_t          *var_len,
+                    WriteMethod    **write_method)
+{
+        /* variables we may use later */
+        static unsigned char      string[SPRINT_MAX_LEN];
+        static unsigned int       i[7];
+        static unsigned long long ull[4];
+        static unsigned long      next_update;
+        static counter64          c64;
+        static unsigned int       c32;
+        struct timeval            current_tv;
+        unsigned long             current;
+        glob_t                    file_path;
+
+        /* Update at most every LNET_STATS_INTERVAL milliseconds */
+        gettimeofday(&current_tv, NULL);
+        current = current_tv.tv_sec * 1000000 + current_tv.tv_usec;
+        if (current >= next_update) {
+                if (cfs_get_param_paths(&file_path, "stats") != 0)
+                        return NULL;
+                if (read_string(file_path.gl_pathv[0], (char *) string, sizeof(string))
+                    != SUCCESS) {
+                        cfs_free_param_data(&file_path);
+                        return NULL;
+                }
+                cfs_free_param_data(&file_path);
+
+                sscanf((char *) string,
+                       "%u %u %u %u %u %u %u %llu %llu %llu %llu",
+                       &i[0], &i[1], &i[2], &i[3], &i[4], &i[5], &i[6],
+                       &ull[0], &ull[1], &ull[2], &ull[3]);
+
+                next_update = current + (LNET_CHECK_INTERVAL * 1000);
+        }
+
+        if (header_generic(vp, name, length, exact, var_len, write_method)
+            == MATCH_FAILED)
+                return NULL;
+
+        switch (vp->magic) {
+        case LNETMSGSALLOC:
+                *var_len = sizeof(c32);
+                c32 = i[0];
+                return (unsigned char *) &c32;
+        case LNETMSGSMAX:
+                *var_len = sizeof(c32);
+                c32 = i[1];
+                return (unsigned char *) &c32;
+        case LNETERRORS:
+                *var_len = sizeof(c32);
+                c32 = i[2];
+                return (unsigned char *) &c32;
+        case LNETSENDCOUNT:
+                *var_len = sizeof(c32);
+                c32 = i[3];
+                return (unsigned char *) &c32;
+        case LNETRECVCOUNT:
+                *var_len = sizeof(c32);
+                c32 = i[4];
+                return (unsigned char *) &c32;
+        case LNETROUTECOUNT:
+                *var_len = sizeof(c32);
+                c32 = i[5];
+                return (unsigned char *) &c32;
+        case LNETDROPCOUNT:
+                *var_len = sizeof(c32);
+                c32 = i[6];
+                return (unsigned char *) &c32;
+        case LNETSENDBYTES:
+                convert_ull(&c64, ull[0], var_len);
+                return (unsigned char *) &c64;
+        case LNETRECVBYTES:
+                convert_ull(&c64, ull[1], var_len);
+                return (unsigned char *) &c64;
+        case LNETROUTEBYTES:
+                convert_ull(&c64, ull[2], var_len);
+                return (unsigned char *) &c64;
+        case LNETDROPBYTES:
+                convert_ull(&c64, ull[3], var_len);
+                return (unsigned char *) &c64;
+        default:
+                return NULL;
+        }
+}
 
 /*****************************************************************************
  * Function: var_mdsNbSampledReq