Expanding LUNs under Linux (LVM)
- Resize the LUN in the storage array using the tools provided by the storage vendor
- Make a note of all the devices making up the multipath device by running multipath -ll
- For each device listed, rescan: echo 1 > /sys/block/sdX/device/rescan
- Enter multipath interactive mode: multipathd -k
- At the prompt del path sdX and add path sdX for each device
- enter resize map MULTIPATH_MAP_NAME e.g. resize map mpath12
- either
- resize the partition (filesystem must be unmounted) pvresize –setphysical VOLNAME SIZE /dev/mapper/mpathXp1
- or
- create a new partition with fdisk (type 8e) in the free space
- rescan all devices (as per step 3)
- pvcreate new partition
- add the new PV to the volume group
- lvextent the logical volume
- Use resize2fs to resize the filesystem
Still stuck? Maybe we can help. Contact us at Upwork
Never miss a thing subscribe to our newsletter
or follow us on twitter
For more super cool techie stuff check out our blog!!
Recent Changes
Contribute to this wiki
Why not help others by sharing your knowledge? Contribute something to this wiki and
join out hall of fame!
Contact us for a user name and password