<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Shutdown ESXi 6.0 by APC UPS in ESXi Discussions</title>
    <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342466#M125893</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;An ESXi host is not like a normal Win or Linux server.&lt;/P&gt;&lt;P&gt;You should not power down a ESXi host without first putting it in maintenance mode (all VMs must be powered off or vMotion to another host).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPS controlled ESXi host shutdown can be very tricky as not many people put ESXi hosts under 1 UPS each....means 6 ESXi host with 6 UPS. If you put 6 ESXi host to 1 UPS....any UPS issues...u may have some very big issues as ALL VMs may start powering down. Even if you put staggered ESXi host shut down, you may see VMs being vMotion to other ESXi hosts....and what would you think will happen when u have 1 or 2 ESXi hosts holding all the VMs and it is forced to shut down ?&lt;/P&gt;&lt;P&gt;**BTW I am taking that you have set up the ESXi hosts to a shared storage using fast connectors like 10G iSCSI...so only the live VM state needs to be vMotion over.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 01 Sep 2015 09:40:34 GMT</pubDate>
    <dc:creator>adrianych</dc:creator>
    <dc:date>2015-09-01T09:40:34Z</dc:date>
    <item>
      <title>Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342463#M125890</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Community,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;as per specs, APC PCNS only works up to VS 5.5. Has anyone tried it with VS 6? Or is there any other way to gracefully shutdown an ESXi 6 Host through an UPS?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you an best regards,&lt;/P&gt;&lt;P&gt;Jens Graven&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Sep 2015 08:29:09 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342463#M125890</guid>
      <dc:creator>JensCoOrga</dc:creator>
      <dc:date>2015-09-01T08:29:09Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342464#M125891</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I did not try APC PCNS, but concerning other ways of handling UPS, there is "apcupsd", and "NUT" (which even has client vib-package for ESXi)...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Sep 2015 09:06:06 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342464#M125891</guid>
      <dc:creator>JarryG</dc:creator>
      <dc:date>2015-09-01T09:06:06Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342465#M125892</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, JarryG. However I have no idea what you are talking about. Do you possible a little more detailed information? Your help is greatly appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers Jens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Sep 2015 09:16:34 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342465#M125892</guid>
      <dc:creator>JensCoOrga</dc:creator>
      <dc:date>2015-09-01T09:16:34Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342466#M125893</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;An ESXi host is not like a normal Win or Linux server.&lt;/P&gt;&lt;P&gt;You should not power down a ESXi host without first putting it in maintenance mode (all VMs must be powered off or vMotion to another host).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPS controlled ESXi host shutdown can be very tricky as not many people put ESXi hosts under 1 UPS each....means 6 ESXi host with 6 UPS. If you put 6 ESXi host to 1 UPS....any UPS issues...u may have some very big issues as ALL VMs may start powering down. Even if you put staggered ESXi host shut down, you may see VMs being vMotion to other ESXi hosts....and what would you think will happen when u have 1 or 2 ESXi hosts holding all the VMs and it is forced to shut down ?&lt;/P&gt;&lt;P&gt;**BTW I am taking that you have set up the ESXi hosts to a shared storage using fast connectors like 10G iSCSI...so only the live VM state needs to be vMotion over.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Sep 2015 09:40:34 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342466#M125893</guid>
      <dc:creator>adrianych</dc:creator>
      <dc:date>2015-09-01T09:40:34Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342467#M125894</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you. I am aware of that. What I am looking for is a simple solution for small environments w/o DRS or HA. In the past we you used to configure APC PCNS. This worked just fine: On certain UPS events, PCNS passed the shutdown command to the hosts. According to the stop/start VM settings, the host then first gracefully shut down the VM's and subsequently itself. Is there a solution under VS 6 for this ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers Jens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Sep 2015 09:47:26 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342467#M125894</guid>
      <dc:creator>JensCoOrga</dc:creator>
      <dc:date>2015-09-01T09:47:26Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342468#M125895</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;FYI, "apcupsd" is software very similar to APC's "PowerChute Network Shutdown", but it is free (open-source) and much more universal. It works not only with APC, but with many other UPS-models/vendors too:&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.apcupsd.com/" title="http://www.apcupsd.com/"&gt;apcupsd | A daemon for controlling APC UPSes&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"NUT" (aka "Network UPS Tool") is another free (open-source) tool for UPS-management, but this one has one big advantage over the previous one: there is native client for ESXi, so there is no need to have one VM to connect to ESXi using login/password to shutdown ESXi-host:&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.networkupstools.org/" title="http://www.networkupstools.org/"&gt;Network UPS Tools - Welcome&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Sep 2015 10:42:43 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342468#M125895</guid>
      <dc:creator>JarryG</dc:creator>
      <dc:date>2015-09-01T10:42:43Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342469#M125896</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This is working for me using the PCNS 4.0 appliance and ESXi 6.0.0, 2494585&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Sep 2015 17:27:20 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342469#M125896</guid>
      <dc:creator>icehckyplyr22</dc:creator>
      <dc:date>2015-09-01T17:27:20Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342470#M125897</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;According to APC, this is not possible and you require Powerchute Network shutdown. We tried this a number of times with USB and found no solution.&lt;/P&gt;&lt;P&gt;&lt;A href="http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&amp;amp;cmd=displayKC&amp;amp;externalId=1007036" rel="nofollow"&gt;VMWare&lt;/A&gt; has info here on using the APC approved solution.&lt;/P&gt;&lt;P&gt;Would also think SmartUPS would be a better choice and you can fit with network card. Naturally more money but if your servers are at all important, that cost should be worth it. Also gives you more monitoring and alerting which might be useful at a remote site. You also need to assure sufficient runtime for all VMs to cleanly shutdown and then shutdown the host&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Sep 2015 17:31:18 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342470#M125897</guid>
      <dc:creator>VijaySendhur</dc:creator>
      <dc:date>2015-09-01T17:31:18Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342471#M125898</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you all for your comments. We are exclusively using Smart UPS with NIC. I will try PCNS 4 then first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers Jens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Sep 2015 08:15:26 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342471#M125898</guid>
      <dc:creator>JensCoOrga</dc:creator>
      <dc:date>2015-09-02T08:15:26Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342472#M125899</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have recent set up ESXi 6 auto shutdown using the APC PRO 1500 with the included PowerChute Personal Edition software.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: underline;"&gt;&lt;SPAN style="color: #000000; text-decoration: underline;"&gt;Windows 10&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;UL style="list-style-type: disc;"&gt;&lt;LI&gt;&lt;SPAN style="color: #000000;"&gt;Install Bash on Ubuntu for Windows&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="color: #000000;"&gt;Install PowerChute Personal Edition&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="color: #000000;"&gt;Test power outage by unplugging power and obtaining event number by going to Event Viewer.&amp;nbsp; In my case its "APC UPS Service:&amp;nbsp; Event ID: 174"&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="color: #000000;"&gt;Test power restore by restoring power and obtaining event number by going to Event Viewer.&amp;nbsp; In my case its "APC UPS Service:&amp;nbsp; Event ID: 61455"&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="color: #000000;"&gt;Using Windows' build in Task Schedule, create new Task and set so that when Event ID 174 is triggered, run execute.bat file.&amp;nbsp; This means that when APC is running on power, it will trigger these scripts.&lt;/SPAN&gt;&lt;UL&gt;&lt;LI&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;cd c:\Windows\System32\&lt;/P&gt;&lt;P&gt;bash -c -l '/mnt/c/&amp;lt;location of script&amp;gt;/execute.bat&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="color: #000000; font-family: Arial, sans-serif;"&gt;A bash script is then created to remote into all the ESXi host servers and run a script that resides inside the hosts.&amp;nbsp; The script has a sleep timer to continue only after 1200sec (20 minutes) in event power does come on to stop this process (see below).&lt;/SPAN&gt;&lt;UL&gt;&lt;LI&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;#!/bin/sh&lt;/P&gt;&lt;P&gt;sleep 1200&lt;/P&gt;&lt;P&gt;ssh root@&amp;lt;ip address of server&amp;gt; /shutdown.sh&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="color: #000000; font-family: Arial, sans-serif;"&gt;Using Windows' build in Task Schedule, create new Task and set so that when Event ID 61455 is triggered, run stop.bat file.&amp;nbsp; This means that when power comes back on, it will trigger the following batch file.&lt;/SPAN&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN style="color: #000000; font-family: Arial, sans-serif;"&gt;This script will kill all running cmd.exe process, hence it will stop the execute.bat that is currently being on sleep timer.&amp;nbsp; &lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;taskkill /im cmd.exe&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: underline;"&gt;ESXi Host&lt;/SPAN&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN style="color: #333333; font-family: Arial, sans-serif;"&gt;Each will need to allow the Windows 10 VM to connect via keypair to allow password-less access.&lt;/SPAN&gt;&lt;UL&gt;&lt;LI&gt;The SSH folder on the ESXi host is located at /etc/ssh/keys-&amp;lt;username&amp;gt;/authorized_keys&lt;/LI&gt;&lt;LI&gt;The public key of the Windows 10 VM will need to be added to the authorized_keys file&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN style="color: #333333; font-family: Arial, sans-serif;"&gt;A bash script that's located on the ESXi host needs to be created to execute the shutdown (shutdown.sh)&lt;/SPAN&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN style="color: #333333; font-family: Arial, sans-serif;"&gt;Note:&amp;nbsp; change the permission the script by doing "chmod a+x shutdown.sh"&amp;nbsp; &lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;#!/bin/sh&lt;/P&gt;&lt;P&gt;poweroff&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 May 2017 16:25:56 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342472#M125899</guid>
      <dc:creator>PigMan9080</dc:creator>
      <dc:date>2017-05-24T16:25:56Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown ESXi 6.0 by APC UPS</title>
      <link>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342473#M125900</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;(almost 3 years later...)&lt;/P&gt;&lt;P&gt;Hi Pigman, I liked the elegance of your solution and currently I am trying to get it to work. I run into a few hiccups.&lt;/P&gt;&lt;P&gt;First, the 2nd line in execute.bat refers to execute.bat itself. Shouldn't it refer to the name of a bash shell script?&lt;/P&gt;&lt;P&gt;Second, it seems cmd.exe instances that are run from Task Scheduler are sand-boxed these days. Running execute.bat and then stop.bat from command line works perfectly. But when I trigger 'run now' for both in the Task Scheduler, the stop.bat will not kill the running bash task and sub processes, so the shutdown will progress, even if power is restored.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did anyone run into this too? How did you solve it?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 08 Feb 2020 15:36:08 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/ESXi-Discussions/Shutdown-ESXi-6-0-by-APC-UPS/m-p/1342473#M125900</guid>
      <dc:creator>JacobIV</dc:creator>
      <dc:date>2020-02-08T15:36:08Z</dc:date>
    </item>
  </channel>
</rss>

