Supermicro VMware Home Lab Automatic Power On and Power Off

0

Running a VMware vSphere home lab is a great way to learn and grow as a virtualization professional. I have a home lab that I have built up over the past few years with Supermicro server hardware. The Supermicro servers have served me very well over the past few years and I have not been disappointed with the stability, performance, and efficiency of the platform. Recently, I added a Supermicro SYS-E301-9D server to the mix for some extra compute, memory, and storage for the home lab. This host is one that I am not really running any “production” VMs on for my home lab.

So, it made me think about spinning this host up and down to cut down on power consumption, heat, and wear and tear on the hardware, especially in the summer months. One of the great things with the Supermicro hardware is the out-of-band management you get with the IPMI. Using this you can effectively power up and power down your Supermicro hardware. Essentially, you can accomplish VMware home lab automatic power on and power off with Supermicro IPMI and the VMware vSphere automatic VM startup/shutdown. Let’s see how.

Supermicro BMC Management with SMCIPMITool

If you have experience with the Supermicro platform, you have no doubt interacted with the BMC controller with the IPMI management capabilities. With the IPMI, you have a fully functional out-of-band management platform that allows you to manage your Supermicro platform at a low level, outside of your ESXi operating system running on top.

Supermicro has a handy little command line tool called the SMCIPMITool that allows you to interact with your Supermicro IPMI from the command line. You will no doubt already know where I am going with this.

If you can interact with the Supermicro IPMI at the command line level, you can essentially automate various interactions with your Supermicro server such as power management features.

First of all, let’s get a little more familiar with the SMCIPMITool that we are referring to.

What is Supermicro SMCIPMITool?

The SMCIPMITool is a command line tool that allows you to interact with the IPMI devices. There is an OS command line mode and a shell mode. What are its key features?

  • Remote System Management
    • SuperBlade Management
    • MicroBlade Management
    • System Power Control
    • HDD and NVMe Management
    • FRU Management
    • System Diagnostic (w/ Super Diagnostics Offline)
    • NM(Node Manager) Management
    • Group Management
  • Remote IPMI Management
    • IPv6 Supported
    • Serial-over-LAN
    • Boot Override
    • Firmware Upgrade
    • Sensors and Event log
    • Power Supply and BBP Monitoring
    • MultiNode System Information
    • Virtual Media Management (Node Product Key is required)
    • Remote Screen Capture (Node Product Key is required)

You can download the SMCIPMITool here:

With the tool, there is nothing to install. Simply extract the ZIP file to a folder. The program you run from the command line is the SMCIPMITool.exe.

You can see the options available if you simply execute the command, passing in your IPMI IP address, ADMIN user, and password.

Running-the-Supermicro-SMCIPMITool-from-the-command-line Supermicro VMware Home Lab Automatic Power On and Power Off
Running the Supermicro SMCIPMITool from the command line

Supermicro VMware Home Lab Automatic Power On and Power Off

There are two commands we are interested in specifically for the home lab – power up and power softshutdown. They intuitively do what you think. The softshutdown is like pressing the power button (not holding it in). This signals a graceful shutdown. VMware ESXi will honor the VM Startup/Shutdown Configuration you have set before shutting down.

Testing-the-power-up-and-soft-power-down-commands Supermicro VMware Home Lab Automatic Power On and Power Off
Testing the power up and soft power down commands

Below, as you can see, I have configured the Automatic Ordered startup and shutdown as well as the startup and shutdown delay. Make sure you select for the Shutdown action to perform a guest shutdown. This will trigger the VMs to perform a graceful shutdown.

You may have to play around with the startup delay as this will vary depending on your storage and hardware configuration. Below is fairly aggressive, but is on NVMe storage.

Configuring-VM-Startup-and-Graceful-VM-shutdown Supermicro VMware Home Lab Automatic Power On and Power Off
Configuring VM Startup and Graceful VM shutdown

After initiating the softshutdown command, I watch as the VMs slowly start shutting down based on the order.

VMs-starting-to-power-down-in-vSphere-inventory-after-a-soft-shutdown-with-SMCIPMITool Supermicro VMware Home Lab Automatic Power On and Power Off
VMs starting to power down in vSphere inventory after a soft shutdown with SMCIPMITool

Create a Windows Scheduled Task to Execute the SMCIPMITool commands

Below, I have an example of how to configure your Windows scheduled task to run the commands needed to both startup and shutdown your Supermicro VMware home lab.

  • Program Script – Enter the path to the SMCIPMITool.exe
  • Add arguments – Enter your IPMI IP address, ADMIN user and password as well as the power up or the power softshutdown command.
  • Start in – The parent folder for your SMCIPMITool

***Note*** I found that executing this in PowerShell required that I wrap my password in quotes for password as I have special characters on the front, however, in Windows Scheduled Task this didn’t work. It simply ran without wrapping the password at all.

Configuring-a-Windows-scheduled-task-to-run-the-SMCIPMITool-for-startup-and-shutdown Supermicro VMware Home Lab Automatic Power On and Power Off
Configuring a Windows scheduled task to run the SMCIPMITool for startup and shutdown

Set the task to run whether user is logged on or not. I have it set to highest privileges as well as Configure for Windows 10.

Configure-the-program-to-run-whether-user-is-logged-on-or-not Supermicro VMware Home Lab Automatic Power On and Power Off
Configure the program to run whether user is logged on or not

Under the Trigger tab, this is where you configure the schedule for running the Windows scheduled task. Here I have my lab starting up at 6 a.m. in the morning. This will give it enough time to power on, boot the VMs, and settle down before I get started in the morning.

Configure-the-trigger-when-to-run-the-schedule-task Supermicro VMware Home Lab Automatic Power On and Power Off
Configure the trigger when to run the schedule task

Do the same for configuring your shutdown command. Below, you see I have both the Startup and Shutdown tasks configured and ready to go. The lab will basically run from 6 a.m. to 6 p.m.

Scheduled-tasks-are-configured-and-ready-to-power-up-and-power-down-your-VMware-home-lab Supermicro VMware Home Lab Automatic Power On and Power Off
Scheduled tasks are configured and ready to power up and power down your VMware home lab

Wrapping Up

With the Supermicro IPMI capabilities, the SMCIPMITool.exe command line utility, VM startup/shutdown configured, and a simple Windows Scheduled Task configured, you can have a Supermicro VMware home lab that powers itself on and off to conserve energy, save on cooling, and be much more efficient.

Even if you don’t want to do this for all your Supermicro hosts if like me you have “production” home lab VMs that run 24×7, you may still have some outlier hosts that can be powered down on a schedule that may simply run a few test VMs that you work with from time to time.

StarWind VSAN