-->

Thursday, September 9, 2021

Things learned about VirtualBox Space Management

 Back around May of 2019 I decided to by a 1 TB SSD just for my virtual machines. Within a year it was already full. Why?






Lessons Learned:


1. Just because you can allocate a lot of HDD space doesn't mean you should.   

    One of my mistakes was dedicating 250 GB of memory just to one instance of Ubuntu!






2. Snapshots add up

    I thought snapshots were little things. Little did I realize that when you take several, they really start to add up. Learn proper best practices for deleting old snapshots. They should be the first place you go to free up Disk Space.





3. Make your snapshots descriptive 

Speaking of, try adding a description to your snapshots.  So many decisions on whether or not to delete a snapshot can be alleviated if you simply labeling WHY this snapshot exists.

4. Have a plan for how much space an Virtual Machine will need


Back then, I was going with the "better to have too much than too little" philosophy, especially as I'd experienced how much of a pain in the neck incrementing a VHD can be

5. Have a purpose for each virtual machine, and don't be afraid to delete once it's served

Generally, having isolated machines to practice online tutorials was the purpose behind my virtual machines. I was experimental, but with experience it's clear that one should get rid of machines that just plain aren't in use. Not only does it save space, but it saves you from later confusion.


VirtualBox: Resizing Disks

 I once found myself needing to increase the size of a virtualbox disk. To that end, I found this guide helpful. Hence, making a note here:




Quick Tips:

1. This will only work on Dynamically Allocated Disks. It will NOT work on fixed disks.
2. Put .\ in front of the command vboxmanage.exe

Sample Command:

.\vboxmanage.exe modifymedium "C:\Users\David\VirtualBox VMs\Ubuntu2019\VirtSSD.vhd" --resize 30999