VMware Cloud Community
craigmash
Contributor
Contributor

Virtual Machine Startup/Shutdown

If I have all VM's on a host set to auto startup/shutdown (suspend), am I correct that if I right-click on the host and tell it to Shut Down all VM's should suspend first, then the host shut down?

For some reason this is not working for me. All VM's begin to suspend, but the host shuts down before they complete and I get dirty shut downs.

Reply
0 Kudos
8 Replies
bykreddy
Enthusiast
Enthusiast

Hi Craig,

Procedure

1 In the vSphere Client inventory, select the host where the virtual machine is located and click the Configuration tab.

2 Under Software, click Virtual Machine Startup/Shutdown and click Properties.

3 Select Allow virtual machines to start and stop automatically with the system.

4 (Optional) Configure the startup and shutdown behavior.

Option

Action

Default Startup Delay

Select the amount of time to delay starting the operating system.

This delay allows time for VMware Tools or the booting system to run scripts.

Continue immediately if the VMware Tools starts

Select to start the operating system immediately after VMware Tools starts.

Default Shutdown Delay

Select the amount of time to delay shutdown for each virtual machine.

The shutdown delay applies only if the virtual machine does not shut down before the delay period elapses. If the virtual machine shuts down before the delay time is reached, the next virtual machine starts shutting down.

Shutdown Action

Select a shutdown option from the drop-down menu.

Power Off

Suspend

Guest Shutdown

Move Up and Move Down

Select a virtual machine in the Manual Startup category and use the Move Up button to move it up to Automatic Startup or Any Oder.

When virtual machines are in the Automatic Startup category, you can use Move Up and Move Down to order them so that they start in a preferred sequence. During shutdown, the virtual machines are stopped in the opposite order.

Edit

Click Edit to configure user-specified autostartup and shutdown behavior for virtual machines in the Automatic Startup or Any Order category.

5 Click OK to close the dialog box and save your settings.

Regards, Yash - If you found this or any other answer helpful, please consider the use of the Helpful or Correct buttons to award points.
Reply
0 Kudos
craigmash
Contributor
Contributor

Thanks for the reply. However, I already have the auto startup/shutdown setup. However when I shut down the host, the host shits down before the VM completes shut down.

Reply
0 Kudos
bykreddy
Enthusiast
Enthusiast

Ok, how many seconds did you set for default shutdown delay ? And also is HA enabled ? or it is just a standalone ESXi host ?

set to 10 seconds or so, then the VMs has to suspend before the host goes down.

issue.jpg

Regards, Yash - If you found this or any other answer helpful, please consider the use of the Helpful or Correct buttons to award points.
Sreejesh_D
Virtuoso
Virtuoso

Hi Craig,

I would suggest you to find the time required to suspend each VM manually. And mentioned the highest Time as the "Default shutdown delay". This way we can ensure that the Host shutdown will be delayed until all the VMs are suspended.

For example

VM1 - 120Secs

VM2 - 220 Secs

VM3 - 80Secs

then "Default shutdown delay" is 220Sec. Ensure that the Shutdown Action selected is Suspend.

craigmash
Contributor
Contributor

I will try adding more time. But it was my understanding this was just a delay in starting each shutdown. Not delaying the host from shutting down.

No HA involved. I use vCenter with two hosts, but no HA.

Reply
0 Kudos
craigmash
Contributor
Contributor

Okay, I changed it FROM 10 seconds TO 300 seconds and sure enough, all VM's suspended before the host shutdown.

So was I wrong in how I understood this setting? If I have three VM's at 300 seconds each, does that mean the host will wait 900 seconds before it shuts down? I THOUGHT it would start the suspend on the first one, then wait that amount of time before starting the next one so you could make sure the resources were not overwhelmed suspending all the machines at once.

Reply
0 Kudos
bykreddy
Enthusiast
Enthusiast

The shutdown delay applies only if the virtual machine does not shut down before the delay period elapses. If the virtual machine shuts down before the delay time is reached, the next virtual machine starts shutting down.

Regards, Yash - If you found this or any other answer helpful, please consider the use of the Helpful or Correct buttons to award points.
Reply
0 Kudos
craigmash
Contributor
Contributor

Yes, that part I understand.

What I do not understand is if the time only applies to the time between VM shutdowns, then why was the HOST not waiting for them all to shutdown before turning itself off?

Reply
0 Kudos