GithubHelp home page GithubHelp logo

Parser problem for PS about check_idrac HOT 3 CLOSED

dangmocrang avatar dangmocrang commented on June 27, 2024
Parser problem for PS

from check_idrac.

Comments (3)

dangmocrang avatar dangmocrang commented on June 27, 2024

Hi,

When you remove the power its equal to the situation that you don't have
that power device, the script won't know if the device existed and be
removed or if its never exist before.
On Jan 20, 2016 2:44 AM, "mikehubert4012" [email protected] wrote:

Hi,

When I remove power on a PS to test a critical problem, i get that a
hardware not found (PS#2)

/usr/lib/nagios/plugins/check_idracpy -H 10xxx -v2c -c public -w PS#1
OK - PS 1: OK, Volt I/O: 264 V/208 V, Current: 04 A, Watt I/O: 9000 W/750 W

/usr/lib/nagios/plugins/check_idracpy -H 10xxx -v2c -c public -w PS#2
hardware not found! If you sure the hw exists then you may want to edit
TRANSLATOR code (line 612)

/usr/lib/nagios/plugins/check_idracpy -H 10xxx -v2c -c public -w PS
PS 1: OK, Volt I/O: 264 V/208 V, Current: 04 A, Watt I/O: 9000 W/750 W
PS 2: CRITICAL(!!), Volt I/O: 264 V/(N/A) V, Current: (N/A) A, Watt I/O:
9000 W/750 W

I was able to correct this, but i think the solution is not permanent one
I added thoses lines at line 388:

        if selfhardware[2] == 'PS' :
            output = outputreplace('No Such Instance currently exists at this OID','0')
        else:

That way I get a CRIT on PS#2
/usr/lib/nagios/plugins/check_idracpy -H 10xxx -v2c -c public -w PS#2
CRIT - PS 2: CRITICAL(!!), Volt I/O: 264 V/(N/A) V, Current: 00 A, Watt
I/O: 9000 W/750 W

Regards,
Mike


Reply to this email directly or view it on GitHub
#19.

from check_idrac.

mikehubert4012 avatar mikehubert4012 commented on June 27, 2024

The problem is that when you call the snmpwalk manually from the snmp_cli string (see the request and answer for PS#1 and PS#2 below)

/etc/nagios/conf.d$ snmpget 10.x.x.x -O q -v 2c -c public powerSupplyIndex.1.1 powerSupplyStatus.1.1 powerSupplyOutputWatts.1.1 powerSupplyInputVoltage.1.1 powerSupplyRatedInputWattage.1.1 amperageProbeReading.1.1 -m ALL IDRAC-MIB-SMIv2::powerSupplyIndex.1.1 1 IDRAC-MIB-SMIv2::powerSupplyStatus.1.1 ok IDRAC-MIB-SMIv2::powerSupplyOutputWatts.1.1 7500 IDRAC-MIB-SMIv2::powerSupplyInputVoltage.1.1 264 IDRAC-MIB-SMIv2::powerSupplyRatedInputWattage.1.1 9000 IDRAC-MIB-SMIv2::amperageProbeReading.1.1 4 /etc/nagios/conf.d$ snmpget 10.x.x.x -O q -v 2c -c public powerSupplyIndex.1.2 powerSupplyStatus.1.2 powerSupplyOutputWatts.1.2 powerSupplyInputVoltage.1.2 powerSupplyRatedInputWattage.1.2 amperageProbeReading.1.2 -m ALL IDRAC-MIB-SMIv2::powerSupplyIndex.1.2 2 IDRAC-MIB-SMIv2::powerSupplyStatus.1.2 critical IDRAC-MIB-SMIv2::powerSupplyOutputWatts.1.2 7500 IDRAC-MIB-SMIv2::powerSupplyInputVoltage.1.2 264 IDRAC-MIB-SMIv2::powerSupplyRatedInputWattage.1.2 9000 IDRAC-MIB-SMIv2::amperageProbeReading.1.2 No Such Instance currently exists at this OID

As you see, the information for this device is present, the "No Such Instance..." is only present for the amperage reading. The powerSupplyStatus is there. Since the script trap "No Such Instance..." globally, it generate an error. (In that case, the amperage reading should be ignored)

Suppose the power is removed accidentaly, you need to know that the server is in a critical state to take action.

Regards,
Mike

from check_idrac.

dangmocrang avatar dangmocrang commented on June 27, 2024

Ok i will check script logic later, i'm on rush for another task. Thanks
for your ideal.
On Jan 20, 2016 8:53 PM, "mikehubert4012" [email protected] wrote:

The problem is that when you call the snmpwalk manually from the snmp_cli
string (see the request and answer for PS#1 and PS#2 below)

/etc/nagios/conf.d$ snmpget 10.x.x.x -O q -v 2c -c public
powerSupplyIndex.1.1 powerSupplyStatus.1.1 powerSupplyOutputWatts.1.1
powerSupplyInputVoltage.1.1 powerSupplyRatedInputWattage.1.1
amperageProbeReading.1.1 -m ALL
IDRAC-MIB-SMIv2::powerSupplyIndex.1.1 1
IDRAC-MIB-SMIv2::powerSupplyStatus.1.1 ok
IDRAC-MIB-SMIv2::powerSupplyOutputWatts.1.1 7500
IDRAC-MIB-SMIv2::powerSupplyInputVoltage.1.1 264
IDRAC-MIB-SMIv2::powerSupplyRatedInputWattage.1.1 9000
IDRAC-MIB-SMIv2::amperageProbeReading.1.1 4

/etc/nagios/conf.d$ snmpget 10.x.x.x -O q -v 2c -c public
powerSupplyIndex.1.2 powerSupplyStatus.1.2 powerSupplyOutputWatts.1.2
powerSupplyInputVoltage.1.2 powerSupplyRatedInputWattage.1.2
amperageProbeReading.1.2 -m ALL
IDRAC-MIB-SMIv2::powerSupplyIndex.1.2 2
IDRAC-MIB-SMIv2::powerSupplyStatus.1.2 critical
IDRAC-MIB-SMIv2::powerSupplyOutputWatts.1.2 7500
IDRAC-MIB-SMIv2::powerSupplyInputVoltage.1.2 264
IDRAC-MIB-SMIv2::powerSupplyRatedInputWattage.1.2 9000
IDRAC-MIB-SMIv2::amperageProbeReading.1.2 No Such Instance currently
exists at this OID

As you see, the information for this device is present, the "No Such
Instance..." is only present for the amperage reading. The
powerSupplyStatus is there. Since the script trap "No Such Instance..."
globally, it generate an error.

Suppose the power is removed accidentaly, you need to know that the server
is in a critical state to take action.

Regards,
Mike


Reply to this email directly or view it on GitHub
#19 (comment)
.

from check_idrac.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.