Hi All,
I am using eve-ng pro on google cloud and really enjoying everything. However, I did not add enough disk space when building out my instance, and now looking to increase it. Is there any guide specific to google cloud? I have tried to add a disk, but it seems the VM is not detecting the new space.
I really appreciate any help you can provide.
Google cloud - expand disk space
Moderator: mike
-
- Posts: 5084
- Joined: Wed Mar 15, 2017 4:44 pm
- Location: London
- Contact:
Re: Google cloud - expand disk space
you must plan your disk before my dear, and set it min 200-300gb
expand current hdd, Iam not sure if linux can do it, make expand partitons, maybe yes
expand current hdd, Iam not sure if linux can do it, make expand partitons, maybe yes
-
- Posts: 9
- Joined: Sun Apr 25, 2021 10:58 pm
Re: Google cloud - expand disk space
Hi Uldis,
Thank you for the response. I can get the disk to expand, I guess, but my issue is with the root file system not resizing with the new space. Worst case, the instance itself is pretty easy to recreate with a new disk, thankfully.
All the best.
Thank you for the response. I can get the disk to expand, I guess, but my issue is with the root file system not resizing with the new space. Worst case, the instance itself is pretty easy to recreate with a new disk, thankfully.
All the best.
-
- Posts: 9
- Joined: Sun Apr 25, 2021 10:58 pm
Re: Google cloud - expand disk space
Old bump just in case any others are in the same boat and need to resize the google disk. I finally reached my disk limit and did not want to rebuild it. Follow these steps, and you should be able to resize the disk.
1. Most important, I recommend taking a snapshot of your current disk.
2. Resize the disk in google cloud GUI or CLI to the desired size.
3. Log in via SSH.
4. fdisk --list
5. If you see an error similar to GPT PMBR size mismatch (62914559 != 83886079) will be corrected by w(rite) for the disk.
6. Next, run gdisk /dev/sda (assuming sda is the disk)
7. Next, hit w to write and say yes. to proceed.
8. Reboot the instance and log into ssh again.
9. Now when you run the fdisk --list, you should see the disk updated to the correct size, and all that is left is to resize the partition.
10. Follow this guide from google to resize the root partition, and you are good to go (https://cloud.google.com/compute/docs/d ... stent-disk)
11. Test it out and if all is well you can do another snap of the resized disk.
1. Most important, I recommend taking a snapshot of your current disk.
2. Resize the disk in google cloud GUI or CLI to the desired size.
3. Log in via SSH.
4. fdisk --list
5. If you see an error similar to GPT PMBR size mismatch (62914559 != 83886079) will be corrected by w(rite) for the disk.
6. Next, run gdisk /dev/sda (assuming sda is the disk)
7. Next, hit w to write and say yes. to proceed.
8. Reboot the instance and log into ssh again.
9. Now when you run the fdisk --list, you should see the disk updated to the correct size, and all that is left is to resize the partition.
10. Follow this guide from google to resize the root partition, and you are good to go (https://cloud.google.com/compute/docs/d ... stent-disk)
11. Test it out and if all is well you can do another snap of the resized disk.