FreeNAS on ESXi - suspend

Octopuss

Patron
Joined
Jan 4, 2019
Messages
461
Has anyone ever run into a problem where FreeNAS's VM would refuse to suspend?

"Failed to suspend virtual machine FreeNAS. The operation is not allowed in the current state."
and
index.php
 

Attachments

  • 1549653141516.png
    1549653141516.png
    5.9 KB · Views: 1,039

toadman

Guru
Joined
Jun 4, 2013
Messages
619
You didn't give any info about your system, so I'm guessing. But you cannot use any of these features if you are passing through (DirectPath I/O) an HBA...

Hot adding and removing of virtual devices
Suspend and resume
Record and replay
Fault tolerance
High availability
DRS (limited availability. The virtual machine can be part of a cluster, but cannot migrate across hosts)
Snapshots
 

Octopuss

Patron
Joined
Jan 4, 2019
Messages
461
Oh, ok! I wasn't aware of that!
So does this mean I have to manually shot down FreeNAS VM through its web interface anytime I need to reboot ESXi?
 

toadman

Guru
Joined
Jun 4, 2013
Messages
619
Yes. You would need to shutdown the Freenas VM via one of several methods before a reboot of ESXi.

I would brush up on the DirectPath I/O limitations in the ESXi documentation for your version.
 

Octopuss

Patron
Joined
Jan 4, 2019
Messages
461
Now that I know what's going on, this is just a small annoyance.
 

Spearfoot

He of the long foot
Moderator
Joined
May 13, 2015
Messages
2,478
Oh, ok! I wasn't aware of that!
So does this mean I have to manually shot down FreeNAS VM through its web interface anytime I need to reboot ESXi?
You can configure ESXi so that it will gracefully shut down any or all VMs you choose, including your FreeNAS VM, provided the VMware tools are installed on the VMs, and FreeNAS includes these tools.

Note that you will have to configure this behavior in ESXi because, at least for version 6.0, the default behavior is to simply power down VMs whenever you reboot or shutdown ESXi.

You probably want to configure ESXi to boot the FreeNAS VM at bootup as well.

Here are the ESXi settings on my main system:
vmstartupshutdown.jpg
 

Octopuss

Patron
Joined
Jan 4, 2019
Messages
461
What does gracefully mean?

This is all I could find in v6.7:
1549665200518.png


No idea if it's possible to actually shut down the VMs like if I was doing it from inside them.
 

Spearfoot

He of the long foot
Moderator
Joined
May 13, 2015
Messages
2,478
What does gracefully mean?

This is all I could find in v6.7:
View attachment 28287

No idea if it's possible to actually shut down the VMs like if I was doing it from inside them.
In this context, "gracefully" means exactly what you just said, i.e., ESXi shutting down the VMs as if they were being shut down from 'inside'.

I'm certain the later versions of ESXi support control of VM startup and shutdown as I described for version 6.0 -- this functionality is critical to enterprise IT operations. It's just that I don't use these later versions, so I can't direct you on where to go. Perhaps another forum member familiar with them will stop by and help out.
 

Spearfoot

He of the long foot
Moderator
Joined
May 13, 2015
Messages
2,478

Octopuss

Patron
Joined
Jan 4, 2019
Messages
461

Spearfoot

He of the long foot
Moderator
Joined
May 13, 2015
Messages
2,478
I got there before as well.
It doesn't explain what is the correct shutdown mode at all. And nowhere on the page is "gracefully" mentioned.
I see that English may not be your native language, so forget that I used the word 'graceful'.

With regards to your FreeNAS VM running on ESXi...

You want ESXi to use "Guest Shutdown" mode with the FreeNAS VM when ESXi itself is rebooted or shut down. ESXi will send a shutdown signal to the VM, which will then go through its standard shutdown processes. As you put it earlier, this is the same as someone shutting down the VM from the 'inside'.

The alternative is for ESXi to simply remove power from the VM, which is equivalent to unplugging the power to a physical server. In general, this is a bad idea for any file server as it can lead to corrupted data and worse, but -- at least in version 6.0 -- this is exactly what ESXi will do unless you change it.

So, referring to the VMware 6.7 document I linked, you want to :
  • Select "Automatically start and stop the virtual machines with the system"
  • Set the "Shutdown action" to "Guest Shutdown"
  • Configure the FreeNAS VM to automatically start & stop with ESXi.
You can make other changes as you see fit, and as required by your needs and setup. ESXi allows you to specify the order in which your VMs start up (and are shut down), how long to wait before starting the next VM in the list, etc., as described in the documentation.

Good luck!
 

Octopuss

Patron
Joined
Jan 4, 2019
Messages
461
I presume "shutdown" is the same as "guest shutdown" in 6.7.
1549731338490.png
 
Top