Check PSU Status

 
Thread Tools Search this Thread
Operating Systems Linux Red Hat Check PSU Status
# 1  
Old 02-23-2014
Check PSU Status

Hello,

We have a cluster and each server have 2 PSU.
An alarm should be raised in case of failure so we need to check periodically the PSU status wth a script.

The first idea was to check with ipmitool but this take some time to get the data and we face some other issues now due to that delay.
Using ipmitool we can parse the watt consumption for both supplies of each server and in case is 0 mean the PSU fails.

I was wondering if i can do the same with dmidecode which is executed faster.
I tried the following two commands but the problem is that i see only one PSU information.

Code:
#  dmidecode -t 39
# dmidecode 2.11
SMBIOS 2.7 present.

Handle 0x0079, DMI type 39, 22 bytes
System Power Supply
        Power Unit Group: 1
        Location: To Be Filled By O.E.M.
        Name: To Be Filled By O.E.M.
        Manufacturer: To Be Filled By O.E.M.
        Serial Number: To Be Filled By O.E.M.
        Asset Tag: To Be Filled By O.E.M.
        Model Part Number: To Be Filled By O.E.M.
        Revision: To Be Filled By O.E.M.
        Max Power Capacity: Unknown
        Status: Present, OK
        Type: Switching
        Input Voltage Range Switching: Auto-switch
        Plugged: Yes
        Hot Replaceable: No
        Input Voltage Probe Handle: 0x0075
        Cooling Device Handle: 0x0077
        Input Current Probe Handle: 0x0078
#



Code:
#  dmidecode -t chassis
# dmidecode 2.11
SMBIOS 2.7 present.

Handle 0x0003, DMI type 3, 22 bytes
Chassis Information
        Manufacturer: empty
        Type: Hand Held
        Lock: Not Present
        Version: empty
        Serial Number: empty
        Asset Tag: empty
        Boot-up State: Safe
        Power Supply State: Safe
        Thermal State: Safe
        Security Status: None
        OEM Information: 0x00000000
        Height: Unspecified
        Number Of Power Cords: 1
        Contained Elements: 0
        SKU Number: To be filled by O.E.M.
#


Any idea?

Thanks in advance
# 2  
Old 02-24-2014
Some hardware manufacturers (if not all) include their own set of tools for a specific server type (if it's not bundled with the OS you can download it from their respective sites).

ProLiant servers have hplog which can give you a deep understanding of the status of all PSUs.

Dell servers, on the other hand, have omreport which works in a similar fashion.

The information reported by dmidecode is vendor-independent and filled out by the manufacturer (usually by hand). So if the manufacturer choses to specify that the serial number is “0000001” or even an empty value, there’s nothing you can do to fix that since DMI information is stored in a read-only chip (some manufacturers are lazier than others when writing the DMI table)

Last edited by verdepollo; 02-24-2014 at 09:12 PM..
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Check status of process

Hi All, Have a query How to check for a process and if down start it , try if for 2 times and its not starting don't do it My code is working to some extent but while starting try starting both times. Please advise , whats wrong here ? if you have any other approach please do share. My... (1 Reply)
Discussion started by: abhaydas
1 Replies

2. Shell Programming and Scripting

Check HD status

I have some server ( IBM , Dell ) , our data center is not in the same location with office , therefore , I do not know if the HD lamp is flash when the HD is fault , can advise if I can write a script to check if the HD is normal running or not ? thanks (1 Reply)
Discussion started by: ust
1 Replies

3. Shell Programming and Scripting

shell script to check if PSU and fan needs to be replaced?

does anyone know any shell script command that can check if PSU and fan needs to be replaced? examples will also be greatly appreciated. thanks! (5 Replies)
Discussion started by: h0ujun
5 Replies

4. Shell Programming and Scripting

Check DB Status using expect

Hi all, I am using expect (novice) and would like to check a DB status before kicking off a batch job. Can anyone help me with such code? Just a simple check to see if the database is up and running would be suffice. Thanks (2 Replies)
Discussion started by: Hopper_no1
2 Replies

5. Shell Programming and Scripting

Need help to check the jobs status

Hello All, I'm new in shell scripting and would like to write an automated script that will check few jobs for the completion, and restart the process based on the jobs status. I am not quite sure how do I check the job status... Can someone please help? Any help will be appreciated. Thanks in... (1 Reply)
Discussion started by: mohullah
1 Replies

6. Shell Programming and Scripting

Check for exit status

Hi I have following code I want If whole code executes successfully then return true If found any error then print the error I tried if ; then But this checks only for the just upper line execution #!/bin/bash PATH1=/var/log/mysql PATH2=/home/ankur/log FILE1=mysql-bin.index... (4 Replies)
Discussion started by: kaushik02018
4 Replies

7. Shell Programming and Scripting

How to Check the process Status and do something

Hi we have weblogic deployed under Linux Enterprise 5 . Now i want to write a script that checks if weblogic is running or not I have found that weblogic uses Java as process . Can i do this way : my Script File : Echo Checking Status if then echo Server Running else echo... (2 Replies)
Discussion started by: Ravi Pavanv
2 Replies

8. Shell Programming and Scripting

How to check the FTP Status?

Hi, I wrote a script that is generating a file and then i have to ftp this file on another server. For this i am using mput to put the file. How can i make sure that the file was ftp'd correctly to the another server, is there any status check ? Thanks. (1 Reply)
Discussion started by: smc3
1 Replies

9. HP-UX

sftp status check

Hi All, I am having shell scripts that make use of ftp to fetch data from one hp-ux box to another. Currently we are migrating these scripts to sftp. Is it a straight forward one? Also, please clarify my following doubts: 1) In ftp we check the success of ftp by verifying the status codes... (4 Replies)
Discussion started by: fisa
4 Replies

10. Shell Programming and Scripting

check the status and send an email with status

Hi, We have a text file which has the following data. ISA~00~ ~00~ ~ZZ~VISTN ~ZZ~U1CAD ~051227~183 7~U~00200~000011258~0~P~< GS~FA~EE05J~U1CAD~051227~1831~000011258~X~002002 ST~997~0001 AK1~SH~247 AK2~856~2470001 AK5~A AK2~856~2470002 AK5~A... (3 Replies)
Discussion started by: isingh786
3 Replies
Login or Register to Ask a Question