LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 10-10-2023, 04:43 PM   #1
etcetera
Member
 
Registered: Aug 2004
Posts: 436

Rep: Reputation: 17
LVM 2 question - adding space to the Volume Group


Assuming I have a 900GB partition for the OS installed on a 2TB SSD.

How will I be able to add the extra space that will now become available to the Volume Group.

Since the source install is much less in size than the 2TB drive.

Or do I have to extend the partition first before expanding the volume group? With vgextend? Then lvextend. Because VG won't be aware of the extra disk space.
 
Old 10-10-2023, 10:07 PM   #2
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,786

Rep: Reputation: 2215Reputation: 2215Reputation: 2215Reputation: 2215Reputation: 2215Reputation: 2215Reputation: 2215Reputation: 2215Reputation: 2215Reputation: 2215Reputation: 2215
Quote:
Originally Posted by etcetera View Post
Or do I have to extend the partition first before expanding the volume group? With vgextend? Then lvextend. Because VG won't be aware of the extra disk space.
Close. After extending the partition, you want pvresize (with just the device name -- no other options needed), then lvextend.

The vgextend command is for adding more PVs (separate devices/partitions) to the VG. If you were adding a separate partition, then vgextend is what you would want. If you just enlarge the existing partition (adding space at the end, NOT at the beginning), then pvresize will detect the new size and adjust the PV parameters accordingly.
 
Old 10-11-2023, 08:15 AM   #3
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,805

Rep: Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002
Quote:
Originally Posted by etcetera View Post
Assuming I have a 900GB partition for the OS installed on a 2TB SSD. How will I be able to add the extra space that will now become available to the Volume Group. Since the source install is much less in size than the 2TB drive. Or do I have to extend the partition first before expanding the volume group? With vgextend? Then lvextend. Because VG won't be aware of the extra disk space.
Did you think about your other (almost identical) question regarding LVM shrinking, and how it would apply here?
https://www.linuxquestions.org/quest...m2-4175729496/

You got handed instructions and documentation, along with the exact command to use to resize an LVM. Try to apply that.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LVM Mount Physical Volume/Logical Volume without a working Volume Group mpivintis Linux - Newbie 10 01-11-2014 07:02 AM
[SOLVED] LVM, Expanded the size of my physical volume, how do I expand the volume group? pyr Linux - General 2 09-15-2013 05:28 AM
Extended LVM Volume group and Logical Volume. But space not usable linuxlover.chaitanya Linux - Server 1 11-19-2012 09:37 AM
can't recover LVM volume: Please specify a *single* volume group to restore SoftDux Linux - General 1 08-04-2011 03:31 PM
Fedora LVM volume group & Physical Volume resize problem gabeyg Fedora 1 05-14-2008 11:26 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 05:24 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration