LinuxQuestions.org
Help answer threads with 0 replies.
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 02-20-2008, 09:42 AM   #1
tom.bokman@mcwa.com
LQ Newbie
 
Registered: Feb 2008
Posts: 2

Rep: Reputation: 0
Post LVM question


I'm new to linux so this might be a dumb question. I've installed RHEL5 on VMware ESX 3.0 server. According to LVM, I have one physical disk with one Volume group and 2 logical volumes. I added a second disk drive using VMware and it shows up fine in LVM. My question is how do I make this new drive part of the Volume group so when I open the filesystem it will show more free space available due to the additional hard drive. Yes, I know how the use VMware to expand the size of the first drive but I also want to know how to do it with LVM. Thanks in advance for your help.

Tom
 
Old 02-20-2008, 11:19 AM   #2
Deleriux
Member
 
Registered: Nov 2003
Posts: 89

Rep: Reputation: 16
Code:
pvcreate /dev/sdx0
vgextend Volume_Group_Name /dev/sdx0
lvextend --size +10G Volume_Group_Name/Logical_Volume_Name #provides extra 10 gigs out of new pool size. OR
lvextend --extents 90%FREE Volume_Group_Name/Logical_Volume_Name #makes the logical volume size 90% the size of the volume grolup

#(assuming filesystem is ext) and you did a fsck.
resize2fs /dev/mapper/Volume_Group_Name/Logical_Volume_Name
Note: sometimes you cannot assign all the extents as the logical volume has been set to using contiguous extents - you can turn this off although you lose file system performance from doing so. To turn it off.
Code:
lvchange -C n Volume_Group_Name/Logical_Volume_Name
#if you turn it off its unlikely you can set it back.
 
Old 02-20-2008, 01:29 PM   #3
tom.bokman@mcwa.com
LQ Newbie
 
Registered: Feb 2008
Posts: 2

Original Poster
Rep: Reputation: 0
That works really nice!! Thanks for your help!!!!!!!!!

Tom
 
Old 02-20-2008, 03:19 PM   #4
Micro420
Senior Member
 
Registered: Aug 2003
Location: Berkeley, CA
Distribution: Mac OS X Leopard 10.6.2, Windows 2003 Server/Vista/7/XP/2000/NT/98, Ubuntux64, CentOS4.8/5.4
Posts: 2,986

Rep: Reputation: 45
you can also use system-config-lvm. It's all graphical
 
  


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
partion vs LVM question mokku Linux - Newbie 3 10-04-2007 07:39 PM
EXT3 fs and LVM question Gortex Linux - Newbie 4 07-17-2007 01:33 AM
Question about LVM Torr Linux - General 1 05-28-2006 08:36 AM
question about LVM an2ny_18 Linux - Software 3 03-12-2006 05:35 AM
lvm question babag Mandriva 4 09-11-2005 03:13 AM


All times are GMT -5. The time now is 09:38 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration