- Community Home
- >
- Servers and Operating Systems
- >
- Servers - General
- >
- HP power protector does not run a script
-
-
Forums
- Products
- Servers and Operating Systems
- Storage
- Software
- Services
- HPE GreenLake
- Company
- Events
- Webinars
- Partner Solutions and Certifications
- Local Language
- China - 简体中文
- Japan - 日本語
- Korea - 한국어
- Taiwan - 繁體中文
-
- Advancing Life & Work
- Advantage EX
- Alliances
- Around the Storage Block
- HPE Ezmeral: Uncut
- OEM Solutions
- Servers & Systems: The Right Compute
- Tech Insights
- The Cloud Experience Everywhere
- HPE Blog, Austria, Germany & Switzerland
- Blog HPE, France
- HPE Blog, Italy
- HPE Blog, Japan
- HPE Blog, Middle East
- HPE Blog, Latin America
- HPE Blog, Russia
- HPE Blog, Saudi Arabia
- HPE Blog, South Africa
- HPE Blog, UK & Ireland
- HPE Blog, Poland
-
Blogs
- Advancing Life & Work
- Advantage EX
- Alliances
- Around the Storage Block
- HPE Blog, Latin America
- HPE Blog, Middle East
- HPE Blog, Saudi Arabia
- HPE Blog, South Africa
- HPE Blog, UK & Ireland
- HPE Ezmeral: Uncut
- OEM Solutions
- Servers & Systems: The Right Compute
- Tech Insights
- The Cloud Experience Everywhere
-
Information
- Community
- Welcome
- Getting Started
- FAQ
- Ranking Overview
- Rules of Participation
- Tips and Tricks
- Resources
- Announcements
- Email us
- Feedback
- Information Libraries
- Integrated Systems
- Networking
- Servers
- Storage
- Other HPE Sites
- Support Center
- Aruba Airheads Community
- Enterprise.nxt
- HPE Dev Community
- Cloud28+ Community
- Marketplace
-
Forums
-
Forums
-
Blogs
-
Information
-
English
- 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
03-22-2013 06:48 AM - edited 04-11-2013 12:56 AM
03-22-2013 06:48 AM - edited 04-11-2013 12:56 AM
Hello everyone,
I'm currently trying to use a script on HP power protector for running some commands on my ESXi server in case of power failure from my ups and I need some help.
I made a script for a SSH connection to the server which looks like :
plink -v -I c:\...\****.ppk root@192.168.1.1 <command>
(-v for the detail or the connection, -I for an authentication key, the .ppk)
If I launch the script on windows or I run the command on the console it work fine but when I use the "test shutdown" link on hppp nothing seems to work.
I tried to use an another bat for a test with these commands :
shutdown : OK
mkdir : OK
calc : KO
plink,putty : KO
Is there something that block my command ?
What can I do ?
--
best regards
John
EDIT :
vm with hppp : windows 7
server ESXi : hp proliant ml110
ups : hp T750 g2
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2013 02:00 AM
04-10-2013 02:00 AM
Re: HP power protector doesn't run my batch file
Hello
I tried with a .js script based on the sample of hppp :
UserScript = { name: "shutdownvm", enabled: true, // Set this property to true to enable the script. onEvent: true, // If true the script is called each time an event occurs. delay: 0, // This property can be used to delay first execution of the action in milliseconds. interval: 10000, // and every 10s from that onStart: function() // Startup function (optional) { // Use this place to insert initialization code }, action: function() // Script action definition { exec("plink -v -i c:\...\****.ppk root@192.168.1.1 /sbin/shutdown.sh && /sbin/poweroff"); }, onStop: function() // Ender function (optional) { // Use this place to insert finalization code } }
KO, don't work
if i change the command :
exec("shutdown -s -t 30"); KO
exec("shutdown -m \\192.168.1.2 -t 30 -t 30); KO
if you know something wich can help me don't be shy please :)
--
best regards
John
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-21-2013 08:36 PM
04-21-2013 08:36 PM
SolutionHi,
Please refer to the following document - HP Power Protector Software - Shutdown Script Does Not Work
Thanks & regards,
Lincy
I work for HP
A quick resolution to technical issues for your HP Enterprise products is just a click away HP Support Center Knowledge-base
See Self Help Post for more details
______________________________________________________
Was the post useful? Say thanks by clicking the white KUDOS Star!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-24-2013 05:48 AM - edited 04-24-2013 08:09 AM
04-24-2013 05:48 AM - edited 04-24-2013 08:09 AM
Re: HP power protector doesn't run my batch file
Hello,
woooo thank you very much !
It work now :)
just two details
first, the path specified 3 time at the end of the document is wrong for me :
/usr/local/HP/PowerProtector/bin/virt_tools/shtdownESXi.pl
-> /usr/local/HP/PowerProtector/bin/shutdownESXi.pl (no virt_tools and u to shutdownESXi.pl)
and second, there is a bug with perl when the shutdownESXi.pl run :
'https://<xx.xx.xx.xx>:443/sdk/vimService.wsdl'; at /usr/lib/perl5/5.10.0/VMware/VICommon.pm line 545.
There is a simple way to correct it : just add at the top of the shutdownESXi.pl script :
$ENV{PERL_LWP_SSL_VERIFY_HOSTNAME} = 0;
[EDIT] third, ssh is not allowed on VMa after an installation we need to edit /etc/hosts.allow and add a ligne :
sshd: ALL: ALLOW
It work fine for me now :)
Best regards
John
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-16-2018 02:38 PM
10-16-2018 02:38 PM
Re: HP power protector doesn't run my batch file
Hi john,
how do you do it.
i have same problem using the sample script.
on my case i realy need to use this sample script to shutdown ESX 6.0 with all vms, 3par and storeonce.
i have 1 script based in powershell, to do the job but all the options that i try do execute failed.
Hewlett Packard Enterprise International
- Communities
- HPE Blogs and Forum
© Copyright 2022 Hewlett Packard Enterprise Development LP