LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-21-2020, 10:48 AM   #1
bino25
Member
 
Registered: Dec 2010
Posts: 49

Rep: Reputation: 11
Increase LVM from expanded disk


Hey all..

Our ESX admin increased the size of the disk presented to my server from 150Gb to 200Gb (I can see the increase in size with fdisk shown below). How do I get the LVM volume group to see the increased size so I can see free PE's to increase the size of the volume?

Output of fdisk (pre growth)

[root@xxxxxxx ~]# fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel with disk identifier 0x02d7c537.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.

Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
switch off the mode (command 'c') and change display units to
sectors (command 'u').

Command (m for help): p

Disk /dev/sdb: 161.1 GB, 161061273600 bytes
255 heads, 63 sectors/track, 19581 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x02d7c537

Device Boot Start End Blocks Id System

Command (m for help): q

Output of fdisk after growth

[root@xxxxxxxx ~]# fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel with disk identifier 0x3ddbba93.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.

Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
switch off the mode (command 'c') and change display units to
sectors (command 'u').

Command (m for help): p

Disk /dev/sdb: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x3ddbba93

Device Boot Start End Blocks Id System


vgdisplay output

[root@xxxxxxxxx ~]# vgdisplay -v data
Using volume group(s) on command line.
--- Volume group ---
VG Name data
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 2
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 1
Open LV 1
Max PV 0
Cur PV 1
Act PV 1
VG Size 149.97 GiB
PE Size 32.00 MiB
Total PE 4799
Alloc PE / Size 4799 / 149.97 GiB
Free PE / Size 0 / 0
VG UUID 01Z1M2-SLeR-4Vvh-t0QT-HuNd-hTaI-YFLsUE
 
Old 07-21-2020, 10:55 AM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: A few
Posts: 6,073

Rep: Reputation: 1890Reputation: 1890Reputation: 1890Reputation: 1890Reputation: 1890Reputation: 1890Reputation: 1890Reputation: 1890Reputation: 1890Reputation: 1890Reputation: 1890
Assuming /dev/sdb is a physical volume in volume group data, pvresize /dev/sdb should do the trick.

Last edited by berndbausch; 07-21-2020 at 10:56 AM.
 
Old 07-21-2020, 11:39 AM   #3
bino25
Member
 
Registered: Dec 2010
Posts: 49

Original Poster
Rep: Reputation: 11
Thanks berndbausch. That did it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Increase LVM disk space but cannot find the dev on host nicolaas Linux - Newbie 2 12-04-2014 01:09 PM
[SOLVED] LVM, Expanded the size of my physical volume, how do I expand the volume group? pyr Linux - General 2 09-15-2013 06:28 AM
cannot detect the additional 5GB on my expanded virtual disk pedenski Linux - Newbie 4 05-25-2013 11:17 AM
Expanded disk linuxgoose Linux - Software 14 03-24-2010 09:49 PM
Mounting LVM Disk to non-LVM disk gak_92 Linux - Hardware 1 08-07-2009 04:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:16 AM.

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