Adding new SSD and merging into existing logical volume in LVM without restarting Ubuntu 18.04/19.04

Untitled

So, getting newly added SSD simply merge into system and increase logical system storage space can be done configuring LVM on Ubuntu:

Following installing new SSD into laptop, run following command to list:

Should give:



Disk /dev/sda: 119.2 GiB, 128035676160 bytes, 250069680 sectors
Disk model: MTFDDAK128MAM-1J
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xf272f09b

Disk /dev/mapper/ubuntu--vg-root: 119.2 GiB, 628344487936 bytes, 1227235328 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/sdc: 477 GiB, 512110190592 bytes, 1000215216 sectors
Disk model: SanDisk SD6SB2M-
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xcbfa1baf

So, I have one 128GB SSD (/dev/sda) and a newly added 512GB SSD(/dev/sdc) in my system.

Lets merge new SSD drive /dev/sdc into logical volume group ubuntu–vg-root which should merge new SSD and increase combined storage size in LVM by 512MB and should display one single logical drive increased volume size by new solid state drives size:

Following executing above should give one single increased merged logical volume. Verify by running:

which should now give:


...
Disk /dev/mapper/ubuntu--vg-root: 585.2 GiB, 628344487936 bytes, 1227235328 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
...

which indicates our overall system storage size of root volume group ubuntu–vg-root size has been increased by newly added SSDs size (512MB).

No comments:

Post a Comment