I have allocated too much memory on my virtual machine and there is not much left on my host one. I want to reduce my memory on my virtual machine and my host one to take it. My host machine is Windows and my virtual one is Ubuntu.
Here's what I have tried:
On my virtual machine I used gparted to make a new partition with the memory I want to free and allocate by my host one:
image that shows how I have seperated my partitions
I did this in order to zero out my new partition and use oracle's modifymedium --compact command to free this memory, but that didn't work among other things I have tried.
That's the specific command I have used to zero out the space:
sudo dd if=/dev/zero of="New Partition #1" bs=1Msomewhere I have read that I need a specific path of this partition in order to be sure that the command would work, but it seemed like something happened after that command and I didn't provide a path since it looks like it isn't assigned any. After lsblk I get:
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTloop0 7:0 0 55.4M 1 loop /snap/core18/2846loop1 7:1 0 63.3M 1 loop /snap/core20/1828loop2 7:2 0 91.9M 1 loop /snap/lxd/24061loop3 7:3 0 132M 1 loop /snap/docker/2932loop4 7:4 0 63.7M 1 loop /snap/core20/2434loop5 7:5 0 73.9M 1 loop /snap/core22/1663loop6 7:6 0 139.6M 1 loop /snap/docker/2963loop7 7:7 0 73.9M 1 loop /snap/core22/1722loop8 7:8 0 91.9M 1 loop /snap/lxd/29619loop9 7:9 0 1.1M 1 loop /snap/mosquitto/904loop10 7:10 0 44.3M 1 loop /snap/snapd/23258loop11 7:11 0 38.8M 1 loop /snap/snapd/21759loop12 7:12 0 11.1M 1 loop /snap/ngrok/226sda 8:0 0 976.6G 0 disk ├─sda1 8:1 0 1.1G 0 part /boot/efi├─sda2 8:2 0 2G 0 part /boot└─sda3 8:3 0 488.3G 0 part └─ubuntu--vg-ubuntu--lv 253:0 0 100G 0 lvm /sr0 11:0 1 1024M 0 rom and /dev/sda3 is my main partition that I do not want to modify and want to keep as it is in my virtual machine.
That's the output of my modifymedium --compact command:
./VBoxManage modifymedium --compact "..notImportantPathToShow\workspace1.vdi"0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%However, after all this nothing changes in my virtual machine.
What can I try next?