(SOLVED) Moving VM disks back to Cache


Recommended Posts

I am new to UnRAID and I think I misunderstood how the caching works. What I was thinking is the VMs stored on cache, but will eventually move to the raid disks and then if the cache fills up the raid disks would be used by default. However I discovered this wasn't the case as the domains path (where the VMs are stored) is set to prefer cache so it stays on the cache drives and not the raided drives. 

 

Because I was migrating a VM from an existing platform, it had a lot of data so it filled my 512GB SSD cache drive and then the VMs just stopped because they ran out of space. So I was thinking initially, and wrongly, set to use the cache to no and then trigger the move so it moved all of the VMs to the raid 4TB mechanical HDD disks. 

 

I've realised my mistake, so my plan now is I will have the OS disks stay in the domains share so its cache is set to prefer so it stays on the cache. 

 

Then I plan to create another share for big data disks for the VMs so would have the share cache value set to yes which if I understand correctly, it will initially write to cache, but then get moved to the raid 4TB HDD disks where as prefer means stay on cache. 

 

Therefore assuming this plan is correct, I need to move my current VM disks back to the cache. Is that possible to move the VMs from the RAID HDD back to the cache or it will be a case of deleting the VMs and recreating them again using this new setup?

 

Thanks

Edited by boardy
Link to comment
2 minutes ago, boardy said:

set to use the cache to no and then trigger the move so it moved all of the VMs to the raid 4TB mechanical HDD disks. 

Shares with cache=no aren't moved to the array, only cache=yes.

 

2 minutes ago, boardy said:

Is that possible to move the VMs from the RAID HDD back to the cache or it will be a case of deleting the VMs and recreating them again using this new setup?

Yes, set the share(s) to cache=prefer and run the mover, the VMs and VM service should be disable, mover won't move open files.

Link to comment

Cache-prefer shares "prefer" to keep files on cache if there is room, and overflows to the array if cache gets below its Minimum Free setting. Cache-prefer files will get moved back to cache from the array when there is room, but mover can't move open files, so usually you have to disable Docker and VM Manager in Settings to get files moved back to cache.

 

 

Link to comment
20 minutes ago, JorgeB said:

Shares with cache=no aren't moved to the array, only cache=yes.

 

Yes, set the share(s) to cache=prefer and run the mover, the VMs and VM service should be disable, mover won't move open files.

 

Thanks for the reply, I missed the little helper text next to the dropdown, thinking about it I think I turned off the VMs (they were suspended automatically after the cache got filled). I assumed it moved the VMs as I when I was triggering the mover manually it kept stating it was skipping and not actually doing anything, and then shutdown the VMs and set this to No then triggered manually again and it started the move. 

 

I'm a tad confused now though whether the VMs are actually on the cache or on the HDDs, is there a way to determine where they are, or do I not need to worry, just move my 2nd disk images (where the big data is) onto a new share that uses cache=yes and the domains share to cache=prefer and run the mover again and it will just sort itself out?

Link to comment
1 hour ago, boardy said:

is there a way to determine where they are

Click on the share then "compute" under size, it will show usage by disk/pool.

 

1 hour ago, boardy said:

just move my 2nd disk images (where the big data is) onto a new share that uses cache=yes and the domains share to cache=prefer and run the mover again and it will just sort itself out?

This works, with the VM off.

Link to comment
  • boardy changed the title to (SOLVED) Moving VM disks back to Cache

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.