Putting unraid to sleep while also running a gaming VM on it


Fenix

Recommended Posts

Hey Guys,

I've got a VM with GPU passthrough running, basically my unraid server is my main rig at the moment. I would like to refine my experience with a few tweaks.

First of all is it possible to use the power button of my case to send my unraid server to sleep? Or has someone an idea how you could write a script that sends the server to sleep a few seconds after the VM is shutdown?

 

Also any suggestions how you made your life easier while using an VM as your main rig are welcome.

Link to comment

Yes I've got the Dynamix S3 Sleep plugin, putting the server to sleep works like expected, but I have to shutdown my VM first and then use my laptop/smartphone to put the server to sleep. If I press the sleep button in the webinterface while the VM is running, it freezes and shuts down, resulting in windows complaining that the system was not correctly shutdown. 

 

I tried to put a command like "virsh stop Daedalus" in the custom commands before sleep, but when I press the Sleep button in the unraid webinterface, It does not care what I wrote down there. Strangely the commands after wakeup work.

 

I was thinking that my issue was that the "virsh stop Daedalus" command exits before the VM is shutdown so I tried a few scripts which wait until all VM's are shutdown, but none of them worked. Has anyone got a working VM stop script, that waits until the VM's are shutdown? Also are there any other services that should be stopped before a sleep?

Edited by Fenix
Link to comment
  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.