I have a Ubuntu 12.04 VM running on VMWares ESXi 5.1.
The server (VM) itself has run out of space, the results of df -h
are as follows:
Filesystem Size Used Avail Use% Mounted on
/dev/sda1 19G 17G 1.2G 94% /
udev 490M 4.0K 490M 1% /dev
tmpfs 200M 232K 199M 1% /run
none 5.0M 0 5.0M 0% /run/lock
none 498M 0 498M 0% /run/shm
The original VM HDD size was just under 19GB which is I have now increased to 100GB within the vCenter GUI:
Is there a simple way of doing this? The VM doesn't seem to acknowledge the increase at all.
Best Answer
I guess you have one big partition and all your data are on this partition this is sda1.
If this assumption is false do not proceed! (Tell me your setup:
fdisk -l
and I will update this answer accordingly.)So you boot some live CD. Ubuntu LiveCD would be fine.
sudo bash
will get you a root shell.fdisk /dev/sda
d
then1
this will delete you partition from the partition table, but it won't touch your data.n
then choosing the defaults is fine.p
to see how it looks. We recreated your partition with a bigger size.w
to write changes to disk.q
exits you back to shell.resize2fs /dev/sda1
will increase the size of the filesystem.