Re: string as index of a table

Niels Baggesen <[email protected]>
Newsgroups gmane.network.net-snmp.devel,gmane.network.net-snmp.user
Message-ID <[email protected]>
On Thu, Oct 16, 2014 at 11:04:54PM +0800, sarath azad wrote:
> I have tested it, it is feasible, but while giving the OID in snmpget,
> we needed to give the item name string index by dot separated ascii
> values of each character in the name. 
> eg. <OID of the table> .1.<column
> no.>.5."65.66.67.68.69"  where the item name is "ABCDE". 

I wonder where this is documented :-(

If you make sure that the shell passes the quotes to the command, you
can actually do it:

snmpwalk $host  <OID of table>.1.<column>.\"ABCDE\"

If the index is an IMPLIED string (one without a length prefix) you must
use single quotes in stead of double quotes.

See the -OE option to snmpcmd(1)

/Niels

-- 
Niels Baggesen - @home - Århus - Denmark - [email protected]
The purpose of computing is insight, not numbers   ---   R W Hamming

------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.