Jump to content

Cache drive for VM only keeps growing in size


Go to solution Solved by Squid,

Recommended Posts

I finally got a small 120GB SATA SSD and have placed it into it's on cache pool formatted in BTRFS. I created a new share which I set to Cache: Prefer and chose the specific cache pool for the VM. In this share I placed my 100GB Vdisk, iso files and my Vbios for my GPU passthrough. There's nothing else with permission to use this cache pool or share. It started with the Vdisk at 107GB and the other files at just over 5GB and I watched it slowly increasing in size until it now says the entire disk is full. When I look at the Vdisk and other files, nothing has changed. In my Windows VM, I still have 20-30GB free on the Vdisk. Why is this happening?

 

Link to comment
1 hour ago, Squid said:

Appreciate the link, didn't know this... But it's not quite the same issue.

 

My VM is used at the moment for web browsing and other simple tasks. I was sitting on the desktop and watching the space on the SSD decrease from 5GB free to zero within like 6 hours. No reason for the vdisk to be increasing in size. It also still reports 107GB as it did when I moved it to the SSD...

 

Link to comment

vDisks without that change in the XML will always increase in size and never decrease.  

 

You download a file (say 2G) to the VM, and the vdisk will increase in size by ~2G.  Delete that file and the vDisk will not decrease.  Do that enough times (or just use the VM for normal purposes where tmp files are created and deleted all the time) and the vdisk will always eventually increase in space to the maximum you've specified.  You're probably seeing the total maximum size when you're looking at it, and not what it actually takes up on the drive.

Link to comment

{SOLVED}

 

Ok so basically the VM ran until there was no more physical space on the SSD at which point it froze. On the unRAID Web UI it showed the VM status as paused and would not start after that so I took the following steps:

 

All of the files used for this VM were saved in a share called "windowsvmsource" with cache set to "Prefer" and a separate SSD cache pool dedicated to it. 

 

  1. I had to force stop the VM.
  2. I set the "windowsvmsoure" to cache: yes and invoked the mover to transfer the files onto my array.
  3. I ran the VM once it was on the array and followed the steps outlined by JorgeB here: 
  4. Once all steps were followed, I set the "windowsvmsource" back to cache: prefer and invoked the mover.
  5. Initially boot was very slow but has improved since and now the used space is smaller than the vdisk allocation and not continually growing, unnecessarily filling up the SSD.

 

Thank you @Squid for helping me find this, it's been an interesting learning experience.

Link to comment

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.

×
×
  • Create New...