In this post I'll show you how to extend disk size in oracle linux on vmware.
First of all our vmware guest operating system must be in shutdown mode.we need to add hard disk to our box.
go to settings--->
click add, then choose hard disk.
check option use an existing virtual disk
then choose file which will expand.
add a new hard disk, go to settings and choose our disk, click utilities--expand and write new size.
power on virtual machine.
our guest system doesn't see a new size
but fdisk shows the new size
solution :
create new partition on /dev/sda
then,
[root@oel6 ~]# pvcreate /dev/sda3 Writing physical volume data to disk "/dev/sda3" Physical volume "/dev/sda3" successfully created [root@oel6 ~]# vgextend vg_oel6 /dev/sda3 Volume group "vg_oel6" successfully extended [root@oel6 ~]# lvextend -L +18G /dev/vg_oel6/lv_root /dev/sda3 Extending logical volume lv_root to 43.60 GiB Logical volume lv_root successfully resized [root@oel6 ~]# resize2fs /dev/mapper/vg_oel6-lv_root 43G resize2fs 1.41.12 (17-May-2010) Filesystem at /dev/mapper/vg_oel6-lv_root is mounted on /; on-line resizing required old desc_blocks = 2, new_desc_blocks = 3 Performing an on-line resize of /dev/mapper/vg_oel6-lv_root to 11272192 (4k) blocks. The filesystem on /dev/mapper/vg_oel6-lv_root is now 11272192 blocks long.
check size :
it's all, enjoy with new size :)