Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Create/Delete Vdisk as I startup/shutdown a VM

Featured Replies

Hi Guys,

 

I have a rather unique situation. I have a windows VM that runs an app that creates huge amount of temporary data. This data is not useless when the VM is shutdown and data is not reusable.

 

So instead of creating this vdisk and allocating a big space in my SSD, I would like to create this vdisk on the fly as I start my VM. When I shutdown, the vdisk can be automatically remove to space my SSD space for other purpose. Is this possible to do?

 

Apology is this has been asked before. I couldn't find anything related.

 

TIA,

Dex

  • Community Expert
36 minutes ago, Dexmorgan said:

Hi Guys,

 

I have a rather unique situation. I have a windows VM that runs an app that creates huge amount of temporary data. This data is not useless when the VM is shutdown and data is not reusable.

 

So instead of creating this vdisk and allocating a big space in my SSD, I would like to create this vdisk on the fly as I start my VM. When I shutdown, the vdisk can be automatically remove to space my SSD space for other purpose. Is this possible to do?

 

Apology is this has been asked before. I couldn't find anything related.

 

TIA,

Dex

I don't think there is a way to do via the GUI, QEMU does have a hooks system so you could build a script to add and remove the disk during start up and shutdown.

 

On 6.9.2 and below there is a single file called QEMU and in 6.10 it is possible to have multiple scripts in a qemu.d directory, but you may need to create the directory.

 

Here is the script I use for my USB_Manager plugin.

 

image.thumb.png.3660969b0c1939abfa952d5ccd727bc4.png

 

The files are persistant so no special processing is needed to restore on boot.

 

Here is more info on hooks.

https://libvirt.org/hooks.html

 

 

  • Author

Thanks for your prompt reply.

 

Looks promising, will have a close look

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...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.