<?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>ipunct &#187; Nagios</title>
	<atom:link href="http://www.ipunct.net/blog/category/monitoring/nagios/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ipunct.net</link>
	<description>IT-Lösungen auf den Punkt gebracht</description>
	<lastBuildDate>Sun, 05 Sep 2010 12:37:45 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher</title>
		<link>http://www.ipunct.net/blog/2009/06/temperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher/</link>
		<comments>http://www.ipunct.net/blog/2009/06/temperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher/#comments</comments>
		<pubDate>Tue, 30 Jun 2009 09:03:46 +0000</pubDate>
		<dc:creator>Mario Rasser</dc:creator>
				<category><![CDATA[Monitoring]]></category>
		<category><![CDATA[Nagios]]></category>
		<category><![CDATA[SNMP]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[3Ware]]></category>
		<category><![CDATA[NagiosGrapher]]></category>
		<category><![CDATA[smartctl]]></category>
		<category><![CDATA[smartmontools]]></category>

		<guid isPermaLink="false">http://blog.ipunct.net/?p=51</guid>
		<description><![CDATA[We have a 3Ware 9550SX-8LP installed in a Linuxserver running Ubuntu Server. What I am going to describe is, how we monitor the Harddisk Temperature via Nagios and graphing it via NagiosGrapher. This HowTo can easily be modified for other 3Ware Controllers. Installation and configuration of needed packages #aptitude install smartmontools snmpd Copy the a [...]]]></description>
			<content:encoded><![CDATA[<p>We have a <a href="http://www.3ware.com"target="_blank"rel="external"title="3Ware" >3Ware</a> 9550SX-8LP installed in a Linuxserver running <a href="http://www.ubuntu.org"target="_blank"rel="external"title="Ubuntu" >Ubuntu</a> Server. What I am going to describe is, how we monitor the Harddisk Temperature via <a href="http://www.nagios.org"target="_blank"rel="external"title="Nagios" >Nagios</a> and graphing it via NagiosGrapher. This HowTo can easily be modified for other 3Ware Controllers.<br />
<div id="attachment_313" class="wp-caption alignnone" style="width: 518px"><img class="size-large wp-image-313" title="Temperature graph from a 3Ware 9550SX-8LP with NagiosGrapher" src="http://www.ipunct.net/wp-content/uploads/2009/06/3ware_nagiographer_temp-508x335.png" alt="Temperature graph from a 3Ware 9550SX-8LP with NagiosGrapher" width="508" height="335" /><p class="wp-caption-text">Temperature graph from a 3Ware 9550SX-8LP with NagiosGrapher</p></div><span id="more-51"></span></p>
<h2>Installation and configuration of needed packages</h2>
<ul>
<li>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#aptitude install smartmontools snmpd</span></pre></div></div>

</li>
<li>Copy the a wrapper script for smartmontools to <strong>/usr/local/bin/get_smart_value.sh</strong>, it will be used by SNMP later

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#!/bin/bash</span>
<span style="color: #666666; font-style: italic;"># Extract the Temperature Value from the SMART values gained by smartclt</span>
<span style="color: #666666; font-style: italic;"># the value 194 contains the HDD Temperature</span>
smartctl <span style="color: #660033;">-a</span> <span style="color: #660033;">-d</span> 3ware,<span style="color: #800000;">${1}</span> <span style="color: #800000;">${2}</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> ^<span style="color: #000000;">194</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">awk</span> <span style="color: #ff0000;">'{print $10}'</span></pre></div></div>

<p>&#8230; and do a <strong>chmod +x  /usr/local/bin/get_smart_value.sh</strong></li>
<li>Configure SNMPd to to run extend-Commands (<strong>/etc/snmp/snmpd.conf</strong>) and add at the end of the file:

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">...
extend 3Ware_1_Port0 <span style="color: #ff0000;">'/usr/bin/sudo /usr/local/bin/get_smart_value.sh 0 /dev/twa0'</span>
extend 3Ware_1_Port1 <span style="color: #ff0000;">'/usr/bin/sudo /usr/local/bin/get_smart_value.sh 1 /dev/twa0'</span>
extend 3Ware_1_Port2 <span style="color: #ff0000;">'/usr/bin/sudo /usr/local/bin/get_smart_value.sh 2 /dev/twa0'</span>
extend 3Ware_1_Port3 <span style="color: #ff0000;">'/usr/bin/sudo /usr/local/bin/get_smart_value.sh 3 /dev/twa0'</span>
extend 3Ware_1_Port4 <span style="color: #ff0000;">'/usr/bin/sudo /usr/local/bin/get_smart_value.sh 4 /dev/twa0'</span>
extend 3Ware_1_Port5 <span style="color: #ff0000;">'/usr/bin/sudo /usr/local/bin/get_smart_value.sh 5 /dev/twa0'</span>
<span style="color: #666666; font-style: italic;">#in our system just 6 HDDs are connected so we will return 0 for the non used</span>
extend 3Ware_1_Port6 <span style="color: #ff0000;">'/bin/echo 0'</span>
extend 3Ware_1_Port7 <span style="color: #ff0000;">'/bin/echo 0'</span></pre></div></div>

<p>&#8230; and restart SNMPd with <strong>/etc/init.d/snmpd restart</strong></li>
<li>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># visudo</span></pre></div></div>

<p>and add the following line</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">snmp    ALL = NOPASSWD: <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>get_smart_value.sh</pre></div></div>

<p>&#8230; to allow <strong>snmp</strong> run the script as SuperUser, which is needed to get the S.M.A.R.T. values via smartctl</li>
</ul>
<h4>Nagios Temperature Checking</h4>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">define service<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        use                             generic-service
        host_name                       your-server-with-3ware.name.tld
        service_description             3Ware Temp. 9550SX-8LP
        flap_detection_enabled          <span style="color: #000000;">1</span>
        max_check_attempts              <span style="color: #000000;">4</span>
        check_period                    24x7
        notification_period             24x7
        check_command                   check_snmp<span style="color: #000000; font-weight: bold;">!</span><span style="color: #007800;">$HOSTADDRESS</span><span style="color: #007800;">$!</span>yourcommunitystring<span style="color: #000000; font-weight: bold;">!</span>2c<span style="color: #000000; font-weight: bold;">!</span>.1.3.6.1.4.1.8072.1.3.2.4.1.2.13.51.87.97.114.101.95.49.95.80.111.114.116.48.1,.1.3.6.1.4.1.8072.1.3.2.4.1.2.13.51.87.97.114.101.95.49.95.80.111.114.116.49.1,.1.3.6.1.4.1.8072.1.3.2.4.1.2.13.51.87.97.114.101.95.49.95.80.111.114.116.50.1,.1.3.6.1.4.1.8072.1.3.2.4.1.2.13.51.87.97.114.101.95.49.95.80.111.114.116.51.1,.1.3.6.1.4.1.8072.1.3.2.4.1.2.13.51.87.97.114.101.95.49.95.80.111.114.116.52.1,.1.3.6.1.4.1.8072.1.3.2.4.1.2.13.51.87.97.114.101.95.49.95.80.111.114.116.53.1,.1.3.6.1.4.1.8072.1.3.2.4.1.2.13.51.87.97.114.101.95.49.95.80.111.114.116.54.1,.1.3.6.1.4.1.8072.1.3.2.4.1.2.13.51.87.97.114.101.95.49.95.80.111.114.116.55.1<span style="color: #000000; font-weight: bold;">!</span>NET-SNMP-EXTEND-MIB<span style="color: #000000; font-weight: bold;">!</span><span style="color: #000000;">45</span>,<span style="color: #000000;">45</span>,<span style="color: #000000;">45</span>,<span style="color: #000000;">45</span>,<span style="color: #000000;">45</span>,<span style="color: #000000;">45</span>,<span style="color: #000000;">2</span>,<span style="color: #000000;">2</span><span style="color: #000000; font-weight: bold;">!</span><span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">4</span>,<span style="color: #000000;">4</span><span style="color: #000000; font-weight: bold;">!</span><span style="color: #ff0000;">'Port Temperatures'</span><span style="color: #000000; font-weight: bold;">!</span><span style="color: #ff0000;">'C'</span>,<span style="color: #ff0000;">'C'</span>,<span style="color: #ff0000;">'C'</span>,<span style="color: #ff0000;">'C'</span>,<span style="color: #ff0000;">'C'</span>,<span style="color: #ff0000;">'C'</span>,<span style="color: #ff0000;">'C'</span>,<span style="color: #ff0000;">'C'</span>
<span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></div></div>

<h4>Nagiosgrapher</h4>
<p>in our config the Nagios Service is called &#8220;3Ware Temp. 9550SX-8LP&#8221;, so we put a config for nagiosgrapher into <strong>/etc/nagiosgrapher/ngraph.d</strong> called <strong>check_temp_3ware_smart_9550SX-8LP.ncfg</strong> that matches the serivce name and defines the needed RegExp to match the wanted data:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        graph_legend    Port <span style="color: #000000;">0</span>
        graph_legend_eol        none
        graph_perf_regex Port0\.1=<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">0</span>-<span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>+<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        graph_units     degree C
        graph_value     Temp1
        hide            no
        rrd_color       ff0000
        rrd_plottype    LINE1
        service_name    ^3Ware Temp. 9550SX-8LP
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        graph_legend    Port <span style="color: #000000;">1</span>
        graph_legend_eol        LEFT
        graph_perf_regex Port1\.1=<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">0</span>-<span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>+<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        graph_units     degree C
        graph_value     temp2
        hide    no
        rrd_color       0000ff
        rrd_plottype    LINE1
        service_name    ^3Ware Temp. 9550SX-8LP
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        graph_legend    Port <span style="color: #000000;">2</span>
        graph_legend_eol        LEFT
        graph_perf_regex Port2\.1=<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">0</span>-<span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>+<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        graph_units     degree C
        graph_value     temp3
        hide    no
        rrd_color       00ffff
        rrd_plottype    LINE1
        service_name    ^3Ware Temp. 9550SX-8LP
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        graph_legend    Port <span style="color: #000000;">3</span>
        graph_legend_eol        LEFT
        graph_perf_regex Port3\.1=<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">0</span>-<span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>+<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        graph_units     degree C
        graph_value     temp4
        hide    no
        rrd_color       00ff00
        rrd_plottype    LINE1
        service_name    ^3Ware Temp. 9550SX-8LP
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        graph_legend    Port <span style="color: #000000;">4</span>
        graph_legend_eol        LEFT
        graph_perf_regex Port4\.1=<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">0</span>-<span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>+<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        graph_units     degree C
        graph_value     temp5
        hide    no
        rrd_color       45ff00
        rrd_plottype    LINE1
        service_name    ^3Ware Temp. 9550SX-8LP
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        graph_legend    Port <span style="color: #000000;">5</span>
        graph_legend_eol        LEFT
        graph_perf_regex Port5\.1=<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">0</span>-<span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>+<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        graph_units     degree C
        graph_value     temp6
        hide    no
        rrd_color       00ff33
        rrd_plottype    LINE1
        service_name    ^3Ware Temp. 9550SX-8LP
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        graph_legend    Port <span style="color: #000000;">6</span>
        graph_legend_eol        LEFT
        graph_perf_regex Port6\.1=<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">0</span>-<span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>+<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        graph_units     degree C
        graph_value     temp7
        hide    no
        rrd_color       DDFFDD
        rrd_plottype    LINE1
        service_name    ^3Ware Temp. 9550SX-8LP
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        graph_legend    Port <span style="color: #000000;">7</span>
        graph_legend_eol        LEFT
        graph_perf_regex Port7\.1=<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000;">0</span>-<span style="color: #000000;">9</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>+<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        graph_units     degree C
        graph_value     temp8
        hide    no
        rrd_color       aaffaa
        rrd_plottype    LINE1
        service_name    ^3Ware Temp. 9550SX-8LP
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Latest:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  LAST
        print_source    Temp1
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Maximum:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  MAX
        print_source    Temp1
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Average:
        print_eol       left
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  AVERAGE
        print_source    Temp1
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Latest:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  LAST
        print_source    temp2
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Maximum:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  MAX
        print_source    temp2
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Average:
        print_eol       left
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  AVERAGE
        print_source    temp2
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Latest:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  LAST
        print_source    temp3
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Maximum:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  MAX
        print_source    temp3
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Average:
        print_eol       left
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  AVERAGE
        print_source    temp3
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Latest:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  LAST
        print_source    temp4
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Maximum:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  MAX
        print_source    temp4
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Average:
        print_eol       left
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  AVERAGE
        print_source    temp4
        service_name    ^3Ware Temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Latest:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  LAST
        print_source    temp5
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Maximum:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  MAX
        print_source    temp5
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Average:
        print_eol       left
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  AVERAGE
        print_source    temp5
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Latest:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  LAST
        print_source    temp6
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Maximum:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  MAX
        print_source    temp6
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Average:
        print_eol       left
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  AVERAGE
        print_source    temp6
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Latest:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  LAST
        print_source    temp7
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Maximum:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  MAX
        print_source    temp7
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Average:
        print_eol       left
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  AVERAGE
        print_source    temp7
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Latest:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  LAST
        print_source    temp8
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Maximum:
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  MAX
        print_source    temp8
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
define ngraph<span style="color: #7a0874; font-weight: bold;">&#123;</span>
        print_description       Average:
        print_eol       left
        print_format    <span style="color: #000000; font-weight: bold;">%</span>2.2lf
        print_function  AVERAGE
        print_source    temp8
        service_name    ^3Ware temp. 9550SX-8LP
        <span style="color: #7a0874; font-weight: bold;">type</span>    GPRINT
<span style="color: #7a0874; font-weight: bold;">&#125;</span></pre></div></div>

<h4>BONUS: Short smartctl/3Ware excures</h4>
<ul>
<li>smartctl that comes with the smartmontools package is able to read the S.M.A.R.T. values from HDDs on a 3Ware Controller</li>
<li>it needs the 3Ware Port that should by queried for data and the 3ware blockdevice, on the newer controller series of 3Ware they are /dev/twaX, where X is the controller number and is starting at 0. So the first controller ist /dev/twa0 the second /dev/twa1 and so on.</li>
<li>older 3Ware controllers are using /dev/twe instead, just have a look and maybe modify the SNMP extend section to get the info from the correct controller/devive</li>
<li>Output on one of our System:

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># smartctl -a -d 3ware,0 /dev/twa0</span>
smartctl version <span style="color: #000000;">5.37</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span>x86_64-unknown-linux-gnu<span style="color: #7a0874; font-weight: bold;">&#93;</span> Copyright <span style="color: #7a0874; font-weight: bold;">&#40;</span>C<span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #000000;">2002</span>-<span style="color: #000000;">6</span> Bruce Allen
Home page is http:<span style="color: #000000; font-weight: bold;">//</span>smartmontools.sourceforge.net<span style="color: #000000; font-weight: bold;">/</span>
&nbsp;
=== START OF INFORMATION SECTION ===
Model Family:     Western Digital Caviar RE Serial ATA series
Device Model:     WDC WD4000YS-01MPB1
Serial Number:    WD-WCANU1569566
Firmware Version: 09.02E09
User Capacity:    400.088.457.216 bytes
Device is:        In smartctl database <span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #000000; font-weight: bold;">for</span> details use: <span style="color: #660033;">-P</span> show<span style="color: #7a0874; font-weight: bold;">&#93;</span>
ATA Version is:   <span style="color: #000000;">7</span>
ATA Standard is:  Exact ATA specification draft version not indicated
Local Time is:    Fri Jul <span style="color: #000000;">10</span> <span style="color: #000000;">10</span>:<span style="color: #000000;">53</span>:<span style="color: #000000;">57</span> <span style="color: #000000;">2009</span> CEST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled
&nbsp;
=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment <span style="color: #7a0874; font-weight: bold;">test</span> result: PASSED
&nbsp;
General SMART Values:
Offline data collection status:  <span style="color: #7a0874; font-weight: bold;">&#40;</span>0x84<span style="color: #7a0874; font-weight: bold;">&#41;</span> Offline data collection activity
                                        was suspended by an interrupting <span style="color: #7a0874; font-weight: bold;">command</span> from host.
                                        Auto Offline Data Collection: Enabled.
Self-test execution status:      <span style="color: #7a0874; font-weight: bold;">&#40;</span>   <span style="color: #000000;">0</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> The previous self-test routine completed
                                        without error or no self-test has ever
                                        been run.
Total <span style="color: #000000; font-weight: bold;">time</span> to <span style="color: #7a0874; font-weight: bold;">complete</span> Offline
data collection:                 <span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">11880</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> seconds.
Offline data collection
capabilities:                    <span style="color: #7a0874; font-weight: bold;">&#40;</span>0x7b<span style="color: #7a0874; font-weight: bold;">&#41;</span> SMART execute Offline immediate.
                                        Auto Offline data collection on<span style="color: #000000; font-weight: bold;">/</span>off support.
                                        Suspend Offline collection upon new
                                        command.
                                        Offline surface scan supported.
                                        Self-test supported.
                                        Conveyance Self-test supported.
                                        Selective Self-test supported.
SMART capabilities:            <span style="color: #7a0874; font-weight: bold;">&#40;</span>0x0003<span style="color: #7a0874; font-weight: bold;">&#41;</span> Saves SMART data before entering
                                        power-saving mode.
                                        Supports SMART auto save timer.
Error logging capability:        <span style="color: #7a0874; font-weight: bold;">&#40;</span>0x01<span style="color: #7a0874; font-weight: bold;">&#41;</span> Error logging supported.
                                        General Purpose Logging supported.
Short self-test routine
recommended polling <span style="color: #000000; font-weight: bold;">time</span>:        <span style="color: #7a0874; font-weight: bold;">&#40;</span>   <span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> minutes.
Extended self-test routine
recommended polling <span style="color: #000000; font-weight: bold;">time</span>:        <span style="color: #7a0874; font-weight: bold;">&#40;</span> <span style="color: #000000;">149</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> minutes.
Conveyance self-test routine
recommended polling <span style="color: #000000; font-weight: bold;">time</span>:        <span style="color: #7a0874; font-weight: bold;">&#40;</span>   <span style="color: #000000;">6</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> minutes.
&nbsp;
SMART Attributes Data Structure revision number: <span style="color: #000000;">16</span>
Vendor Specific SMART Attributes with Thresholds:
ID<span style="color: #666666; font-style: italic;"># ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE</span>
  <span style="color: #000000;">1</span> Raw_Read_Error_Rate     0x000f   <span style="color: #000000;">200</span>   <span style="color: #000000;">200</span>   051    Pre-fail  Always       -       <span style="color: #000000;">0</span>
  <span style="color: #000000;">3</span> Spin_Up_Time            0x0003   <span style="color: #000000;">218</span>   <span style="color: #000000;">218</span>   021    Pre-fail  Always       -       <span style="color: #000000;">6100</span>
  <span style="color: #000000;">4</span> Start_Stop_Count        0x0032   <span style="color: #000000;">100</span>   <span style="color: #000000;">100</span>   000    Old_age   Always       -       <span style="color: #000000;">19</span>
  <span style="color: #000000;">5</span> Reallocated_Sector_Ct   0x0033   <span style="color: #000000;">200</span>   <span style="color: #000000;">200</span>   <span style="color: #000000;">140</span>    Pre-fail  Always       -       <span style="color: #000000;">0</span>
  <span style="color: #000000;">7</span> Seek_Error_Rate         0x000f   <span style="color: #000000;">200</span>   <span style="color: #000000;">200</span>   051    Pre-fail  Always       -       <span style="color: #000000;">0</span>
  <span style="color: #000000;">9</span> Power_On_Hours          0x0032   085   085   000    Old_age   Always       -       <span style="color: #000000;">11445</span>
 <span style="color: #000000;">10</span> Spin_Retry_Count        0x0013   <span style="color: #000000;">100</span>   <span style="color: #000000;">253</span>   051    Pre-fail  Always       -       <span style="color: #000000;">0</span>
 <span style="color: #000000;">11</span> Calibration_Retry_Count 0x0012   <span style="color: #000000;">100</span>   <span style="color: #000000;">253</span>   051    Old_age   Always       -       <span style="color: #000000;">0</span>
 <span style="color: #000000;">12</span> Power_Cycle_Count       0x0032   <span style="color: #000000;">100</span>   <span style="color: #000000;">100</span>   000    Old_age   Always       -       <span style="color: #000000;">18</span>
<span style="color: #000000;">194</span> Temperature_Celsius     0x0022   <span style="color: #000000;">114</span>   <span style="color: #000000;">113</span>   000    Old_age   Always       -       <span style="color: #000000;">38</span>
<span style="color: #000000;">196</span> Reallocated_Event_Count 0x0032   <span style="color: #000000;">200</span>   <span style="color: #000000;">200</span>   000    Old_age   Always       -       <span style="color: #000000;">0</span>
<span style="color: #000000;">197</span> Current_Pending_Sector  0x0012   <span style="color: #000000;">200</span>   <span style="color: #000000;">200</span>   000    Old_age   Always       -       <span style="color: #000000;">0</span>
<span style="color: #000000;">198</span> Offline_Uncorrectable   0x0010   <span style="color: #000000;">200</span>   <span style="color: #000000;">200</span>   000    Old_age   Offline      -       <span style="color: #000000;">0</span>
<span style="color: #000000;">199</span> UDMA_CRC_Error_Count    0x003e   <span style="color: #000000;">200</span>   <span style="color: #000000;">200</span>   000    Old_age   Always       -       <span style="color: #000000;">0</span>
<span style="color: #000000;">200</span> Multi_Zone_Error_Rate   0x0009   <span style="color: #000000;">200</span>   <span style="color: #000000;">200</span>   051    Pre-fail  Offline      -       <span style="color: #000000;">0</span>
&nbsp;
SMART Error Log Version: <span style="color: #000000;">1</span>
No Errors Logged
&nbsp;
SMART Self-test log structure revision number <span style="color: #000000;">1</span>
Num  Test_Description    Status                  Remaining  LifeTime<span style="color: #7a0874; font-weight: bold;">&#40;</span>hours<span style="color: #7a0874; font-weight: bold;">&#41;</span>  LBA_of_first_error
<span style="color: #666666; font-style: italic;"># 1  Short captive       Interrupted (host reset)      90%      4274         -</span>
<span style="color: #666666; font-style: italic;"># 2  Short offline       Completed without error       00%      4122         -</span>
<span style="color: #666666; font-style: italic;"># 3  Short offline       Completed without error       00%      3954         -</span>
<span style="color: #666666; font-style: italic;"># 4  Short offline       Completed without error       00%      3786         -</span>
<span style="color: #666666; font-style: italic;"># 5  Short offline       Completed without error       00%      3618         -</span>
<span style="color: #666666; font-style: italic;"># 6  Short offline       Completed without error       00%      3451         -</span>
<span style="color: #666666; font-style: italic;"># 7  Short offline       Completed without error       00%      3283         -</span>
<span style="color: #666666; font-style: italic;"># 8  Short offline       Completed without error       00%      3115         -</span>
<span style="color: #666666; font-style: italic;"># 9  Short offline       Completed without error       00%      2947         -</span>
<span style="color: #666666; font-style: italic;">#10  Short offline       Completed without error       00%      2779         -</span>
<span style="color: #666666; font-style: italic;">#11  Short offline       Completed without error       00%      2611         -</span>
<span style="color: #666666; font-style: italic;">#12  Short offline       Completed without error       00%      2443         -</span>
<span style="color: #666666; font-style: italic;">#13  Short offline       Completed without error       00%      2275         -</span>
<span style="color: #666666; font-style: italic;">#14  Short offline       Completed without error       00%      2107         -</span>
<span style="color: #666666; font-style: italic;">#15  Short offline       Completed without error       00%      1940         -</span>
<span style="color: #666666; font-style: italic;">#16  Short offline       Completed without error       00%      1772         -</span>
<span style="color: #666666; font-style: italic;">#17  Short offline       Completed without error       00%      1604         -</span>
<span style="color: #666666; font-style: italic;">#18  Short offline       Completed without error       00%      1436         -</span>
<span style="color: #666666; font-style: italic;">#19  Short offline       Completed without error       00%      1268         -</span>
<span style="color: #666666; font-style: italic;">#20  Short offline       Completed without error       00%      1101         -</span>
<span style="color: #666666; font-style: italic;">#21  Short offline       Completed without error       00%       933         -</span>
&nbsp;
SMART Selective self-test log data structure revision number <span style="color: #000000;">1</span>
 SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    <span style="color: #000000;">1</span>        <span style="color: #000000;">0</span>        <span style="color: #000000;">0</span>  Not_testing
    <span style="color: #000000;">2</span>        <span style="color: #000000;">0</span>        <span style="color: #000000;">0</span>  Not_testing
    <span style="color: #000000;">3</span>        <span style="color: #000000;">0</span>        <span style="color: #000000;">0</span>  Not_testing
    <span style="color: #000000;">4</span>        <span style="color: #000000;">0</span>        <span style="color: #000000;">0</span>  Not_testing
    <span style="color: #000000;">5</span>        <span style="color: #000000;">0</span>        <span style="color: #000000;">0</span>  Not_testing
Selective self-test flags <span style="color: #7a0874; font-weight: bold;">&#40;</span>0x0<span style="color: #7a0874; font-weight: bold;">&#41;</span>:
  After scanning selected spans, <span style="color: #000000; font-weight: bold;">do</span> NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after <span style="color: #000000;">0</span> minute delay.</pre></div></div>

</li>
</ul>
<ul class="socialwrap size24 row">
<li class="iconOnly share">Teilen:</li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="delicious" href="http://delicious.com/post?url=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F06%2Ftemperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher%2F&amp;title=Temperature+Monitoring+of+3Ware+Controller+with+smartmontools%2C+Nagios+and+NagiosGrapher" title="Bookmark this post : Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher on Delicious"><span class="head">Delicious</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="digg" href="http://digg.com/submit?url=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F06%2Ftemperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher%2F&amp;title=Temperature+Monitoring+of+3Ware+Controller+with+smartmontools%2C+Nagios+and+NagiosGrapher&amp;bodytext=We+have+a+3Ware+9550SX-8LP+installed+in+a+Linuxserver+running+Ubuntu+Server.+What+I+am+going+to+describe+is%2C+how+we+monitor+the+Harddisk+Temperature+via+Nagios+and+graphing+it+via+NagiosGrapher.+This+HowTo+can+easily+be+modified+for+other+3Ware+Controllers.%0D%0A%5Bcaption+id%3D%22attachment_313%22+align%3D%22alignnone%22+width%3D%22508%22+ca" title="Digg this post : Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher"><span class="head">Digg this post</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="facebook" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F06%2Ftemperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher%2F&amp;t=Temperature+Monitoring+of+3Ware+Controller+with+smartmontools%2C+Nagios+and+NagiosGrapher" title="Recommend this post : Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher on Facebook"><span class="head">Facebook</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="linkedin" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F06%2Ftemperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher%2F&amp;title=Temperature+Monitoring+of+3Ware+Controller+with+smartmontools%2C+Nagios+and+NagiosGrapher&amp;&amp;summary=" title="Share this post : Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher on Linkedin"><span class="head">Linkedin</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="twitter" href="http://twitter.com/home/?status=Temperature+Monitoring+of+3Ware+Controller+with+smartmontools%2C+Nagios+and+NagiosGrapher+-+http%3A%2F%2Fbit.ly%2FaL5sK3" title="Tweet this post : Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher on Twitter"><span class="head">Twitter</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="xing" href="http://www.xing.com/app/user?op=share;url=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F06%2Ftemperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher%2F" title="Share this post : Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher on xing"><span class="head">Share on xing</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="" class="rss" href="http://www.ipunct.net/blog/2009/06/temperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher/feed" title="Follow this post : Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher comments"><span class="head">Subscribe to the comments on this post</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="" class="bookmark" href="javascript:window.bookMark('http://www.ipunct.net/blog/2009/06/temperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher/', 'Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher');" title="Bookmark this post : Temperature Monitoring of 3Ware Controller with smartmontools, Nagios and NagiosGrapher"><span class="head">Bookmark in Browser</span></a></li>
</ul>
<div class="clean"></div>
]]></content:encoded>
			<wfw:commentRss>http://www.ipunct.net/blog/2009/06/temperature-monitoring-of-3ware-controller-with-smartmontools-nagios-and-nagiosgrapher/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Cisco Catalyst 2970 monitoring via SNMP</title>
		<link>http://www.ipunct.net/blog/2009/03/cisco-catalyst-2970-monitoring-via-snmp/</link>
		<comments>http://www.ipunct.net/blog/2009/03/cisco-catalyst-2970-monitoring-via-snmp/#comments</comments>
		<pubDate>Mon, 23 Mar 2009 14:29:56 +0000</pubDate>
		<dc:creator>Mario Rasser</dc:creator>
				<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Monitoring]]></category>
		<category><![CDATA[Nagios]]></category>
		<category><![CDATA[SNMP]]></category>
		<category><![CDATA[Catalayst]]></category>
		<category><![CDATA[NagiosGrapher]]></category>

		<guid isPermaLink="false">http://blog.ipunct.net/?p=3</guid>
		<description><![CDATA[This article will explain some parts of monitoring a Cisco Catalyst 2970 switch via SNMP and Nagios. Together with NagiosGrapher it gets an powerful combination to have a longtime overview about that device and you can create nice graphics like that: Prepare the switch for SNMP requests from a SNMP polling host (here 192.168.200.200) : [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: left;">This article will explain some parts of monitoring a<strong> <a href="http://www.cisco.com"target="_blank"rel="external"title="Cisco" >Cisco</a> Catalyst 2970</strong> switch via <strong>SNMP</strong> and <strong><a href="http://www.nagios.org"target="_blank"rel="external"title="Nagios" >Nagios</a></strong>. Together with NagiosGrapher it gets an powerful combination to have a longtime overview about that device and you can create nice graphics like that:</p>
<p style="text-align: center;"><img class="aligncenter size-full wp-image-4" title="switch_gigabitethernet0_10_1current" src="http://www.ipunct.net/wp-content/uploads/2009/03/switch_gigabitethernet0_10_1current.png" alt="switch_gigabitethernet0_10_1current" width="490" height="223" /></p>
<h4>Prepare the switch for SNMP requests from a SNMP polling host (here <code>192.168.200.200)</code> :</h4>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">access-list <span style="color: #000000;">60</span> permit 192.168.200.200
snmp-server community yoursnmpcommunitystring RO <span style="color: #000000;">60</span>
snmp-server location <span style="color: #ff0000;">&quot;near the backbone&quot;</span>
snmp-server contact <span style="color: #ff0000;">&quot;admin@myswitch.de&quot;</span></pre></div></div>

<p style="text-align: left;"><span id="more-7"></span></p>
<h4>Play around with SNMP</h4>
<p>First install snmp and get the CISCO-MIBS and install them on your system (optional).</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">aptitude</span> <span style="color: #c20cb9; font-weight: bold;">install</span> snmp
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>tmp<span style="color: #000000; font-weight: bold;">/</span>
<span style="color: #c20cb9; font-weight: bold;">wget</span> <span style="color: #c20cb9; font-weight: bold;">ftp</span>:<span style="color: #000000; font-weight: bold;">//</span>ftp.cisco.com<span style="color: #000000; font-weight: bold;">/</span>pub<span style="color: #000000; font-weight: bold;">/</span>mibs<span style="color: #000000; font-weight: bold;">/</span>v2<span style="color: #000000; font-weight: bold;">/</span>v2.tar.gz</pre></div></div>

<p>Extract the needed MIBS from the <code>v2.tar.gz</code>, e.g. <code>CISCO-ENVMON-MIB.my</code> to <code>/usr/share/snmp/mibs/CISCO-ENVMON-MIB.my</code>. Maybe you&#8217;ve to have a look in the files dependencies.</p>
<p>Get some Status information from the ENVMON mib:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">snmpwalk <span style="color: #660033;">-m</span> CISCO-ENVMON-MIB <span style="color: #660033;">-v2c</span> <span style="color: #660033;">-OS</span> <span style="color: #660033;">-c</span>  yoursnmpcommunitystring switch-fqdn .1.3.6.1.4.1.9.9.13
CISCO-ENVMON-MIB::ciscoEnvMonPresent.0 = INTEGER: <span style="color: #000000;">100</span>
CISCO-ENVMON-MIB::ciscoEnvMonFanStatusDescr.1004 = STRING: Switch<span style="color: #666666; font-style: italic;">#1, Fan#1, Status is Normal</span>
CISCO-ENVMON-MIB::ciscoEnvMonFanState.1004 = INTEGER: normal<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
CISCO-ENVMON-MIB::ciscoEnvMonSupplyStatusDescr.1003 = STRING: Switch<span style="color: #666666; font-style: italic;">#1, PowerSupply#1, Status is Normal, RPS Not Present</span>
CISCO-ENVMON-MIB::ciscoEnvMonSupplyState.1003 = INTEGER: normal<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
CISCO-ENVMON-MIB::ciscoEnvMonSupplySource.1003 = INTEGER: ac<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
CISCO-ENVMON-MIB::ciscoEnvMonEnableShutdownNotification.0 = INTEGER: <span style="color: #c20cb9; font-weight: bold;">false</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
CISCO-ENVMON-MIB::ciscoEnvMonEnableTemperatureNotification.0 = INTEGER: <span style="color: #c20cb9; font-weight: bold;">false</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
CISCO-ENVMON-MIB::ciscoEnvMonEnableFanNotification.0 = INTEGER: <span style="color: #c20cb9; font-weight: bold;">false</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
CISCO-ENVMON-MIB::ciscoEnvMonEnableRedundantSupplyNotification.0 = INTEGER: <span style="color: #c20cb9; font-weight: bold;">false</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">2</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
CISCO-ENVMON-MIB::ciscoEnvMonEnableStatChangeNotif.0 = INTEGER: <span style="color: #c20cb9; font-weight: bold;">false</span><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>.. as you can see you can get health information like PowerSupply and FanStatus informations. We can use these SNMP values in Nagios to monitor the PSU and Fan status.</p>
<p>You can find further informations about the CISCO Enterprise SNMP tree <a href="http://support.ipmonitor.com/mibs_byoidtree.aspx?oid=.1.3.6.1.4.1.9.9#h">here.</a></p>
<p>Looking around in the tree, you will find many information that you want to monitor.
<ul class="socialwrap size24 row">
<li class="iconOnly share">Teilen:</li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="delicious" href="http://delicious.com/post?url=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F03%2Fcisco-catalyst-2970-monitoring-via-snmp%2F&amp;title=Cisco+Catalyst+2970+monitoring+via+SNMP" title="Bookmark this post : Cisco Catalyst 2970 monitoring via SNMP on Delicious"><span class="head">Delicious</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="digg" href="http://digg.com/submit?url=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F03%2Fcisco-catalyst-2970-monitoring-via-snmp%2F&amp;title=Cisco+Catalyst+2970+monitoring+via+SNMP&amp;bodytext=This+article+will+explain+some+parts+of+monitoring+a+Cisco+Catalyst+2970+switch+via+SNMP+and+Nagios.+Together+with+NagiosGrapher+it+gets+an+powerful+combination+to+have+a+longtime+overview+about+that+device+and+you+can+create+nice+graphics+like+that%3A%0A%0A%0APrepare+the+switch+for+SNMP+requests+from+a+SNMP+polling+host+%28here" title="Digg this post : Cisco Catalyst 2970 monitoring via SNMP"><span class="head">Digg this post</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="facebook" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F03%2Fcisco-catalyst-2970-monitoring-via-snmp%2F&amp;t=Cisco+Catalyst+2970+monitoring+via+SNMP" title="Recommend this post : Cisco Catalyst 2970 monitoring via SNMP on Facebook"><span class="head">Facebook</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="linkedin" href="http://www.linkedin.com/shareArticle?mini=true&amp;url=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F03%2Fcisco-catalyst-2970-monitoring-via-snmp%2F&amp;title=Cisco+Catalyst+2970+monitoring+via+SNMP&amp;&amp;summary=" title="Share this post : Cisco Catalyst 2970 monitoring via SNMP on Linkedin"><span class="head">Linkedin</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="twitter" href="http://twitter.com/home/?status=Cisco+Catalyst+2970+monitoring+via+SNMP+-+http%3A%2F%2Fbit.ly%2FaPCBLw" title="Tweet this post : Cisco Catalyst 2970 monitoring via SNMP on Twitter"><span class="head">Twitter</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="_blank" class="xing" href="http://www.xing.com/app/user?op=share;url=http%3A%2F%2Fwww.ipunct.net%2Fblog%2F2009%2F03%2Fcisco-catalyst-2970-monitoring-via-snmp%2F" title="Share this post : Cisco Catalyst 2970 monitoring via SNMP on xing"><span class="head">Share on xing</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="" class="rss" href="http://www.ipunct.net/blog/2009/03/cisco-catalyst-2970-monitoring-via-snmp/feed" title="Follow this post : Cisco Catalyst 2970 monitoring via SNMP comments"><span class="head">Subscribe to the comments on this post</span></a></li>
<li class="iconOnly"><a rel="nofollow" target="" class="bookmark" href="javascript:window.bookMark('http://www.ipunct.net/blog/2009/03/cisco-catalyst-2970-monitoring-via-snmp/', 'Cisco Catalyst 2970 monitoring via SNMP');" title="Bookmark this post : Cisco Catalyst 2970 monitoring via SNMP"><span class="head">Bookmark in Browser</span></a></li>
</ul>
<div class="clean"></div>
]]></content:encoded>
			<wfw:commentRss>http://www.ipunct.net/blog/2009/03/cisco-catalyst-2970-monitoring-via-snmp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
