- Community Home
- >
- Storage
- >
- Entry Storage Systems
- >
- Disk Enclosures
- >
- Re: Script to get storage information (with hpacuc...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-09-2008 03:28 PM
тАО09-09-2008 03:28 PM
I need to write a script to get nagios information.
I need to return with echo command.
If i use the hpacucli with this commands:
ctrl all show status
or
controller sn=PAB360NX3UC0AD array A physicaldrive all show status
or
controller sn=PAB360NX3UC0AD array A physicaldrive 1:1 show status
What can i do ???
lik....if i put:
echo ctrl all show status
the answer is:
ctrl all show status
and i need the real information:
MSA500 G2 in M57TLYPN8H
Controller Status: OK
Cache Status: OK
Battery Status: OK
Any help ?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-09-2008 04:10 PM
тАО09-09-2008 04:10 PM
Re: Script to get storage information (with hpacucli)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-10-2008 12:23 AM
тАО09-10-2008 12:23 AM
Re: Script to get storage information (with hpacucli)
If I am not mistaken it is
"ctrl all show" removing "status"
oly "ctrl all show"
regards
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-10-2008 03:59 AM
тАО09-10-2008 03:59 AM
Solutionctrl all show status > status_file.txt
or
status=`ctrl all show status`
Then you still have to parse the output and check if it says "OK" for further processing so you need additional code here to interface with nagios. Not sure of the details.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-10-2008 08:31 AM
тАО09-10-2008 08:31 AM
Re: Script to get storage information (with hpacucli)
Yes... i need to know how to do this in Unix. My OS is Linux Red Hat.
I will try this.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-10-2008 09:00 AM
тАО09-10-2008 09:00 AM
Re: Script to get storage information (with hpacucli)
My script:
#!/bin/bash
status='hpacucli controller sn=PAB360NX3UC0AD array A physicaldrive 1:1 show status'
echo "$status"
Don't work.
I already try echo status, echo $status..
Any help ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-10-2008 09:03 AM
тАО09-10-2008 09:03 AM
Re: Script to get storage information (with hpacucli)
#!/bin/bash
status=`hpacucli controller sn=PAB360NX3UC0AD array A physicaldrive 1:1 show status`
echo $status
I change ' to `
Thanks!