PDA

View Full Version : [ubuntu] 12.04 - How to refresh disk info after RAID expansion?



iissmart
August 28th, 2012, 07:10 PM
I just expanded an Areca hardware RAID with another disk in my server. Everything went fine, but parted and fdisk still see the old size of the disk, so I can't expand my XFS partition. This is an active server and I can't unmount or reboot the machine (which is fine for XFS, since the partition has to be mounted to be expanded anyway). How can I refresh the device information so it sees the new disk size without unmounting or rebooting the machine?

darkod
August 28th, 2012, 08:34 PM
Are you talking about disk size or filesystem size? There is a difference.

After expanding the array the disk size should already be updated. But the filesystem doesn't expand automatically.

I don't know about XFS, but for ext2/3/4 to resize the filesystem using the whole partition (device) you run:
sudo resize2fs /dev/mapper/......

iissmart
August 29th, 2012, 03:19 AM
Disk size. The Areca OOB interface reports the RAID at the new larger size, but the kernel still reports the old size. I can't expand my partition if it thinks there isn't any unpartitioned space on the RAID (I've tried).