Subject: Re: xenconsole and SNMP ?
To: None <port-xen@NetBSD.org>
From: Geert Hendrickx <ghen@NetBSD.org>
List: port-xen
Date: 09/13/2006 22:43:23
On Wed, Sep 13, 2006 at 09:27:44PM +0200, Geert Hendrickx wrote:
> Hi,
> 
> does sysutils/xenconsole work with SNMP for anyone?  I'm running an snmpd
> on all my domU's, which I can succesfully query from the commandline on the
> dom0.  I can't get it to work with xcon however.  A tcpdump(8) on a domU
> shows that xcon is requesting the values, but snmpd returns noSuchName.  

I found the two offending OID's, the workaround is to comment them out:

--- xsnmp.pm.orig       2006-09-13 22:41:10.000000000 +0200
+++ xsnmp.pm    2006-09-13 22:37:42.000000000 +0200
@@ -34,8 +34,8 @@
    swap_total  => OID_SWAP_TOTAL,
    swap_avail  => OID_SWAP_AVAIL,
    mem_avail   => OID_MEM_AVAIL,
-   mem_buffers => OID_MEM_BUFFERS,
-   mem_cache   => OID_MEM_CACHED,
+#  mem_buffers => OID_MEM_BUFFERS,
+#  mem_cache   => OID_MEM_CACHED,
    sys_descr   => OID_SYS_DESCR,
 );

I don't know what the proper MIBS should be though.
 
> Apart from that, the MIB used for the "uptime" value is sysUpTimeInstance,
> which gives the uptime of the snmpd, instead of hrSystemUptime, which gives
> the uptime of the OS.  I'll fix that (unless this is intended??) when I get
> xcon to work.

This is the right MIB for host uptime:

--- snmp_poll.pm.orig   2006-09-13 22:40:16.000000000 +0200
+++ snmp_poll.pm        2006-09-13 22:40:36.000000000 +0200
@@ -49,7 +49,7 @@
 
 # --- Common OIDs for application use
 # -------------------------------------
 
-use constant OID_UPTIME     => '1.3.6.1.2.1.1.3.0';
+use constant OID_UPTIME     => '1.3.6.1.2.1.25.1.1.0';
 use constant OID_LAVD_1MIN  => '1.3.6.1.4.1.2021.10.1.3.1';
 use constant OID_LAVD_5MIN  => '1.3.6.1.4.1.2021.10.1.3.2';
 use constant OID_LAVD_15MIN => '1.3.6.1.4.1.2021.10.1.3.3';

	Geert