<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>logIt &#187; MIB</title>
	<atom:link href="https://lakm.us/logit/tag/mib/feed/" rel="self" type="application/rss+xml" />
	<link>https://lakm.us/logit</link>
	<description>Log Around The Clock</description>
	<lastBuildDate>Sat, 06 Jun 2015 14:17:37 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>SNMP: Mistake of Using Tabular OID in Practice</title>
		<link>https://lakm.us/logit/2012/03/snmp-mistake-tabular-oid-practice/</link>
		<comments>https://lakm.us/logit/2012/03/snmp-mistake-tabular-oid-practice/#comments</comments>
		<pubDate>Tue, 20 Mar 2012 07:57:58 +0000</pubDate>
		<dc:creator>Arif</dc:creator>
				<category><![CDATA[General Linux]]></category>
		<category><![CDATA[appliance]]></category>
		<category><![CDATA[MIB]]></category>
		<category><![CDATA[monitoring]]></category>
		<category><![CDATA[OSS]]></category>
		<category><![CDATA[proprietary]]></category>
		<category><![CDATA[snmp]]></category>

		<guid isPermaLink="false">http://lakm.us/logit/?p=372</guid>
		<description><![CDATA[Recently, I retrieve rectifier-related SNMP data from Eltek&#8217;s Smartpack Controller. This one has the following rear type where we can connect to the ethernet plug (see the purple area). It is presumably in its default configuration and I can snmpwalk through its corporate specific OIDs (under 12148 tree) to find i.e. output voltage, current, battery [...]]]></description>
				<content:encoded><![CDATA[<p>Recently, I retrieve rectifier-related SNMP data from <a href="http://www.eltek.com/wip4/detail_products.epl?k1=25507&#038;close=1&#038;id=1123846" title="Eltek Smartpack Controller" target="_blank">Eltek&#8217;s Smartpack Controller</a>. This one has the following rear type where we can connect to the ethernet plug (see the purple area).</p>
<div class="wp-caption aligncenter" style="width: 460px"><img alt="Eltek Smartpack Controller type with SNMP Support" src="../../../../images/eltek-smartpack-rear-1.jpg" title="Eltek Smartpack Controller type with SNMP Support" width="266" height="103" /><p class="wp-caption-text">Eltek Smartpack Controller rear view (type that comes with SNMP support)</p></div>
<p>It is presumably in its default configuration and I can <code>snmpwalk</code> through its corporate specific OIDs (under 12148 tree) to find i.e. output voltage, current, battery temperature, etc. Doing it without translating against the MIB will retrieve all the values perfectly fine. However, I want to show you a mistake in practice related to how the MIB is written and put to place, which is a version 4 by the name of <a href="http://forums.manageengine.com/viewFile.do?fileId=49000003919231&#038;forumGroupId=49000000002007" title="Manage Engine Forum: ELTEK-DISTRIBUTED-PLANTV4-MIB">ELTEK-DISTRIBUTED-PLANTV4-MIB</a>. It has tabular part as clipped in the following tree (see <a href="./2011/09/write-mib-file-tabular/" title="Write Your Own MIB File (Tabular)" target="_blank">previous post</a> on how to write such part in your own MIB):</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">            <span style="color: #000000; font-weight: bold;">|</span>     +--eltek<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">12148</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>        +--eltekDistributedPlantV4<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
...
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>     +--rectifierStatusTable<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>        +--rectifierStatusEntry<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>  Index: rectifierStatusID
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>           +-- <span style="color: #660033;">-R--</span> Integer32 rectifierStatusID<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>        Range: 1..100
...
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>           +-- <span style="color: #660033;">-R--</span> Integer32 rectifierStatusOutputVoltage<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">4</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>           <span style="color: #000000; font-weight: bold;">|</span>        Range: 0..65535</pre></div></div>

<p>Looking at the above <code>rectifierStatusEntry</code> branch, it marks a tabular entry expected to range from 1 to 100 as defined by <code>rectifierStatusID</code>. Hence, putting 0 as one of the output voltage index will confuse the OID reported by <code>GET</code> as</p>
<ol>
<li>belong to the scalar type (a misconception that is)</li>
<li>belong to the tabular type but out of index range</li>
</ol>
<p><code>GET</code> against the MIB will return the following error</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> snmpget <span style="color: #660033;">-m</span> +ELTEK-DISTRIBUTED-PLANTV4-MIB <span style="color: #660033;">-v</span> <span style="color: #000000;">1</span> <span style="color: #660033;">-c</span> public raddlex ELTEK-DISTRIBUTED-PLANTV4-MIB::rectifierStatusOutputCurrent.0
ELTEK-DISTRIBUTED-PLANTV4-MIB::rectifierStatusOutputCurrent.0: Unknown Object Identifier <span style="color: #7a0874; font-weight: bold;">&#40;</span>Index out of range: <span style="color: #000000;">0</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span>rectifierStatusID<span style="color: #7a0874; font-weight: bold;">&#41;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span></pre></div></div>

<p>while the item (output current) actually has value in it as found below</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #c20cb9; font-weight: bold;">sudo</span> snmpget <span style="color: #660033;">-v</span> <span style="color: #000000;">1</span> <span style="color: #660033;">-c</span> public raddlex .1.3.6.1.4.1.12148.9.5.5.2.1.3.0
SNMPv2-SMI::enterprises.12148.9.5.5.2.1.3.0 = INTEGER: <span style="color: #000000;">1</span></pre></div></div>

<p>By this time the MIB is already the latest to be used with firmware version 4.3.</p>
]]></content:encoded>
			<wfw:commentRss>https://lakm.us/logit/2012/03/snmp-mistake-tabular-oid-practice/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Write Your Own MIB File (Tabular)</title>
		<link>https://lakm.us/logit/2011/09/write-mib-file-tabular/</link>
		<comments>https://lakm.us/logit/2011/09/write-mib-file-tabular/#comments</comments>
		<pubDate>Fri, 09 Sep 2011 11:23:19 +0000</pubDate>
		<dc:creator>Arif</dc:creator>
				<category><![CDATA[General Linux]]></category>
		<category><![CDATA[MIB]]></category>
		<category><![CDATA[OSS]]></category>
		<category><![CDATA[snmp]]></category>

		<guid isPermaLink="false">http://lakm.us/logit/?p=355</guid>
		<description><![CDATA[When it comes to writing our own MIB, a practical choice might be to write the whole objects as of scalar type (RFC-1212). That means, let&#8217;s say we have 2 battery statuses, each of them must be explicitly written individually within the MIB file. Example of calling their voltages: $ snmpwalk -m +REKTRONIK-MIB -v 1 [...]]]></description>
				<content:encoded><![CDATA[<p>When it comes to writing our own <a href="http://en.wikipedia.org/wiki/Management_information_base" title="http://en.wikipedia.org/wiki/Management_information_base" target="_blank">MIB</a>, a practical choice might be to write the whole objects as of <strong>scalar</strong> type (<a href="http://tools.ietf.org/html/rfc1212#section-3" title="RFC-1212: Columnar Objects" target="_blank">RFC-1212</a>). That means, let&#8217;s say we have 2 battery statuses, each of them must be explicitly written individually within the MIB file. Example of calling their voltages:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ snmpwalk <span style="color: #660033;">-m</span> +REKTRONIK-MIB <span style="color: #660033;">-v</span> <span style="color: #000000;">1</span> <span style="color: #660033;">-c</span> public monitored-host .1.3.6.1.4.1.38610
...
REKTRONIK-MIB::battery1Voltage.0 = INTEGER: <span style="color: #000000;">9</span>
REKTRONIK-MIB::battery2Voltage.0 = INTEGER: <span style="color: #000000;">11</span>
...</pre></div></div>

<p>If additional 3rd battery is to be monitored, <code>REKTRONIK-MIB.txt</code> in this example must be modified. In small scale we don&#8217;t need consistent MIB as changes are manageable, but if a whole bunch of different people must reference to this, a better way is to have <strong>tabular</strong> object where the above batteries are indexed instead of ended with &#8220;<code>.0</code>&#8221; scalar identifier.</p>
<p>Quick approach by checking established <code><a href="http://www.observium.org/svn/observer/trunk/mibs/LM-SENSORS-MIB" title="LM-SENSORS-MIB" target="_blank">LM-SENSORS-MIB.txt</a></code> shows at least we need three object definitions inside the MIB file:</p>
<div class="wp-caption aligncenter" style="width: 510px"><img alt="snmp-mib-tabular-object-basics.jpg" src="../../../../images/snmp-mib-tabular-object-basics.jpg" title="snmp-mib-tabular-object-basics.jpg" width="154" height="173" /><p class="wp-caption-text">Components of writing tabular MIB</p></div>
<p>
Its stemmed MIB tree to show the (1) <code>Table</code>, (2) <code>Entry</code>, and (3) <code>Index</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">...
            <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     +--lmFanSensorsTable<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">3</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  +--lmFanSensorsEntry<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  Index: lmFanSensorsIndex
            <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>     +-- <span style="color: #660033;">-R--</span> Integer32 lmFanSensorsIndex<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>        Range: 0..65535
...</pre></div></div>

<p>Now the writing part of those three types to our MIB, plus the <code>batteryVoltage</code> which is the actual object to be indexed in the final SNMP monitoring.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
</pre></td><td class="code"><pre class="bash" style="font-family:monospace;">batteryTable OBJECT-TYPE
    SYNTAX     SEQUENCE OF BatteryEntry
    MAX-ACCESS not-accessible
    STATUS     current
    DESCRIPTION
        <span style="color: #ff0000;">&quot;The (conceptual) table of batteries contained by the
        module.&quot;</span>
    ::= <span style="color: #7a0874; font-weight: bold;">&#123;</span> monitor <span style="color: #000000;">1</span> <span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
batteryEntry OBJECT-TYPE
    SYNTAX     BatteryEntry
    MAX-ACCESS not-accessible
    STATUS     current
    DESCRIPTION
        <span style="color: #ff0000;">&quot;A (conceptual) entry for one battery contained by
        the module.  The batteryIndex in the index represents
        the entry in the batteryTable that corresponds to the
        batteryEntry.
&nbsp;
        As an example of how objects in this table are named,
        an instance of the batteryVoltage object might be
        named batteryVoltage.3&quot;</span>
    INDEX <span style="color: #7a0874; font-weight: bold;">&#123;</span> batteryIndex <span style="color: #7a0874; font-weight: bold;">&#125;</span>
    ::= <span style="color: #7a0874; font-weight: bold;">&#123;</span> batteryTable <span style="color: #000000;">1</span> <span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
batteryIndex OBJECT-TYPE
    SYNTAX      DeviceIndex
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            <span style="color: #ff0000;">&quot;A unique value, greater than zero, for each battery. 
            It is recommended that values are assigned contiguously
            starting from 1.&quot;</span>
    ::= <span style="color: #7a0874; font-weight: bold;">&#123;</span> batteryEntry <span style="color: #000000;">1</span> <span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
batteryVoltage    OBJECT-TYPE 
   SYNTAX Integer32 
   ACCESS read-only 
   STATUS current 
   DESCRIPTION 
      <span style="color: #ff0000;">&quot;Voltage A/D value&quot;</span> 
   ::= <span style="color: #7a0874; font-weight: bold;">&#123;</span> batteryEntry <span style="color: #000000;">2</span> <span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></td></tr></table></div>

<p>There are some header parts of course, check the resulting <code>REKTRONIK-MIB.txt</code> <a href="../../../../upload/REKTRONIK-MIB.txt" title="REKTRONIK-MIB.txt" target="_blank">here</a>.</p>
<p>The tree view becomes:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">            +--private<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">4</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>  +--enterprises<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>     +--rektronik<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">39559</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
...
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>        +--monitor<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  +--batteryTable<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>  +--batteryEntry<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>  Index: batteryIndex
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     +-- <span style="color: #660033;">-R--</span> Integer32 batteryIndex<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>        Textual Convention: DeviceIndex
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     <span style="color: #000000; font-weight: bold;">|</span>        Range: 1..2147483647
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     +-- <span style="color: #660033;">-R--</span> Integer32 batteryVoltage<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>     +-- <span style="color: #660033;">-R--</span> Integer32 batteryCurrent<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">3</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  +--environment<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>  +-- <span style="color: #660033;">-R--</span> Integer32 temperature<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
            <span style="color: #000000; font-weight: bold;">|</span>        <span style="color: #000000; font-weight: bold;">|</span>  <span style="color: #000000; font-weight: bold;">|</span>  +-- <span style="color: #660033;">-R--</span> Integer32 humidity<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
...</pre></div></div>

<p>and example of getting SNMP is</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ snmpwalk <span style="color: #660033;">-m</span> +REKTRONIK-MIB <span style="color: #660033;">-v</span> <span style="color: #000000;">1</span> <span style="color: #660033;">-c</span> public monitored-host .1.3.6.1.4.1.38610
REKTRONIK-MIB::name.0 = STRING: <span style="color: #ff0000;">&quot;RekMini&quot;</span>
REKTRONIK-MIB::version.0 = STRING: <span style="color: #ff0000;">&quot;1.0&quot;</span>
REKTRONIK-MIB::date.0 = STRING: <span style="color: #ff0000;">&quot;2011-09-08&quot;</span>
REKTRONIK-MIB::batteryIndex.22 = INTEGER: <span style="color: #000000;">22</span>
REKTRONIK-MIB::batteryIndex.23 = INTEGER: <span style="color: #000000;">23</span>
REKTRONIK-MIB::batteryVoltage.22 = INTEGER: <span style="color: #000000;">9</span>
REKTRONIK-MIB::batteryVoltage.23 = INTEGER: <span style="color: #000000;">11</span>
REKTRONIK-MIB::batteryCurrent.22 = INTEGER: <span style="color: #000000;">2</span>
REKTRONIK-MIB::batteryCurrent.23 = INTEGER: <span style="color: #000000;">2</span>
...</pre></div></div>

<p>in the above example any additional 3rd battery voltage insertion will be OID &#8220;<code>REKTRONIK-MIB::batteryVoltage<strong>.24</strong></code>&#8220;</p>
]]></content:encoded>
			<wfw:commentRss>https://lakm.us/logit/2011/09/write-mib-file-tabular/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
