Thank you for supporting the Cloud Customer Connect Community in 2024. It's a gift to work with you!

Look back
You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

OCI: How To Relocate Logical Volumes To A New Block Volume And Increase The Size

edited Jul 5, 2024 4:24PM in Linux

Applies to:

Oracle Cloud Infrastructure

Linux x86-64

Goal:

Move a Logical Volume to a new block volume and grow the same filesystem

Solution:

Execute below steps as root user (sudo su -)

$ df -hP /reports /docs 
Filesystem                     Size  Used Avail Use% Mounted on 
/dev/mapper/dataVG-reports_lv   10G  5.2G  4.9G  52% /reports 
/dev/mapper/dataVG-docs_lv      50G   46G  4.6G  91% /docs          <--- 
$ pvs 
  PV         VG        Fmt  Attr PSize   PFree 
  /dev/sda   dataVG    lvm2 a--  <60.00g    0           <--- PFree 0 
  /dev/sdb3  ocivolume lvm2 a--   45.47g    0 
$ lsblk 
NAME                MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT 
sda                   8:0    0   60G  0 disk 
├─dataVG-reports_lv 252:2    0   10G  0 lvm  /reports 
└─dataVG-docs_lv    252:3    0   50G  0 lvm  /docs 
sdb             

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!