{"id":644,"date":"2015-02-06T07:33:42","date_gmt":"2015-02-05T20:33:42","guid":{"rendered":"http:\/\/threemillion.net\/blog\/?p=644"},"modified":"2015-02-05T15:48:09","modified_gmt":"2015-02-05T04:48:09","slug":"configure-esx-power-management-with-powercli","status":"publish","type":"post","link":"https:\/\/threemillion.net\/blog\/?p=644","title":{"rendered":"Configure ESX Power Management with PowerCLI"},"content":{"rendered":"<p>View current Power Management Policy<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$vmhost = Get-VMHost -Name ESX01  \r\n$vmhostview = Get-View -ViewType Hostsystem -Filter @{&quot;Name&quot;=$($vmhost).Name} -Property ConfigManager.PowerSystem  \r\n$powerpolicy = Get-View $vmhostview.ConfigManager.PowerSystem  \r\n$powerpolicy | Select -ExpandProperty Info | Select -ExpandProperty CurrentPolicy\r\n\r\nKey             : 1\r\nName            : PowerPolicy.static.name\r\nShortName       : static\r\nDescription     : PowerPolicy.static.description\r\nDynamicType     : \r\nDynamicProperty :  \r\n<\/pre>\n<table>\n<tr>\n<th>Key<\/th>\n<th>ShortName<\/th>\n<th>GUI Equivilent<\/th>\n<\/tr>\n<tr>\n<td>1<\/td>\n<td>static<\/td>\n<td>High Performance<\/td>\n<\/tr>\n<tr>\n<td>2<\/td>\n<td>dynamic<\/td>\n<td>Balanced<\/td>\n<\/tr>\n<tr>\n<td>3<\/td>\n<td>low<\/td>\n<td>Low power<\/td>\n<\/tr>\n<tr>\n<td>4<\/td>\n<td>custom<\/td>\n<td>Custom<\/td>\n<\/tr>\n<\/table>\n<figure id=\"attachment_635\" aria-describedby=\"caption-attachment-635\" style=\"width: 434px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/threemillion.net\/blog\/wp-content\/uploads\/2015\/02\/Edit-Power-Policy-Settings-ESX.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/threemillion.net\/blog\/wp-content\/uploads\/2015\/02\/Edit-Power-Policy-Settings-ESX.png\" alt=\"Edit Power Policy Settings Screenshot\" width=\"434\" height=\"312\" class=\"size-full wp-image-635\" srcset=\"https:\/\/threemillion.net\/blog\/wp-content\/uploads\/2015\/02\/Edit-Power-Policy-Settings-ESX.png 434w, https:\/\/threemillion.net\/blog\/wp-content\/uploads\/2015\/02\/Edit-Power-Policy-Settings-ESX-300x216.png 300w\" sizes=\"auto, (max-width: 434px) 100vw, 434px\" \/><\/a><figcaption id=\"caption-attachment-635\" class=\"wp-caption-text\">Edit Power Policy Settings Screenshot<\/figcaption><\/figure>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$vmhostview = Get-View -ViewType Hostsystem -Filter @{&quot;Name&quot;=$($vmhost).Name} -Property ConfigManager.PowerSystem \r\n$powerpolicy = Get-View $vmhostview.ConfigManager.PowerSystem\r\n\r\n#Configure \r\n$powerpolicy.ConfigurePowerPolicy(1)\r\n<\/pre>\n<p><strong>Environmental Information<\/strong>:<br \/>\nESX 5.5<\/p>\n","protected":false},"excerpt":{"rendered":"<p>View current Power Management Policy Key ShortName GUI Equivilent 1 static High Performance 2 dynamic Balanced 3 low Low power 4 custom Custom Environmental Information: ESX 5.5<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"Layout":"","footnotes":""},"categories":[49,5],"tags":[87],"class_list":["entry","author-admin","post-644","post","type-post","status-publish","format-standard","category-powercli","category-scripting","tag-power-management"],"_links":{"self":[{"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=\/wp\/v2\/posts\/644","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=644"}],"version-history":[{"count":6,"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=\/wp\/v2\/posts\/644\/revisions"}],"predecessor-version":[{"id":650,"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=\/wp\/v2\/posts\/644\/revisions\/650"}],"wp:attachment":[{"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=644"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=644"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/threemillion.net\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=644"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}