Adding new disk to volume group

Stephen Carville scarville at landam.com
Wed Sep 26 23:36:30 UTC 2007


Geofrey Rainey wrote:
> Hi,
> 
> Here are the steps you need to do (they should be fine, but
> Let me know if you have any issues, and the associated error
> Because I might have missed something):
> 
> Step 1. create a partition on your new disk:
> 
> # fdisk /dev/cciss/c0d1
> 
> Once within fdisk, type the following (what you enter is between <> )
> 
> Command (m for help): <n>
> 
> Command action
>    e   extended
>    p   primary partition (1-4)
> 
> <p>
> 
> Partition number (1-4):
> <1>
> 
> First cylinder (1- ...): <press enter to select default>
> Last cylinder ... : <press enter to select default>
> 
> Now, you will find yourself back at the main prompt. You will want to
> now
> Change the partition's ID to Linux LVM
> 
> Command (m for help): <t>
> 
> Hex code (type L to list codes): <8e>
> 
> <w> - to write the partition table.
> 
> Now you should be back in the shell.
> 
> 
> 
> Step 2. create a new physical volume:
> 
> # pvcreate /dev/cciss/c0d1p1 (I think this is what it should be if you
> have only made one single partition on the new disk).
> 
> 
> Step 3. Add your new physical volume to your existing volume group
> 
> # pvextend VolGroup00 /dev/cciss/c0d1p1

I think that should be vgextend

# vgextend -A VolGroup00 /dev/cciss/c0d1p1


> Assuming the above worked, if you now type "vgdisplay -v", you should
> see two 
> physical volumes at the bottom of the output, and an increase in
> capacity of 
> In the following line:  "Free  PE / Size       98 / 3.06 GB"
> 
> 
> Regards,
> Geofrey Rainey.
> 
> 
> -----Original Message-----
> From: Kory Wheatley [mailto:wheakory at isu.edu] 
> Sent: Thursday, 27 September 2007 9:48 a.m.
> To: Geofrey Rainey
> Cc: General Red Hat Linux discussion list
> Subject: Re: Adding new disk to volume group
> 
> fdisk -l
> 
> Disk /dev/cciss/c0d0: 36.4 GB, 36414750720 bytes
> 255 heads, 32 sectors/track, 8716 cylinders Units = cylinders of 8160 *
> 512 = 4177920 bytes
> 
>            Device Boot      Start         End      Blocks   Id  System
> /dev/cciss/c0d0p1               1           2        8144    4  FAT16
> <32M
> /dev/cciss/c0d0p2   *           3          52      204000   83  Linux
> /dev/cciss/c0d0p4             285        8716    34402560    f  W95 
> Ext'd (LBA)
> /dev/cciss/c0d0p5             285        8064    31742384   8e  Linux
> LVM
> /dev/cciss/c0d0p6            8065        8578     2097104   82  Linux
> swap
> 
> Disk /dev/cciss/c0d1: 36.4 GB, 36414750720 bytes
> 255 heads, 32 sectors/track, 8716 cylinders Units = cylinders of 8160 *
> 512 = 4177920 bytes
> 
> Disk /dev/cciss/c0d1 doesn't contain a valid partition table
> 
> [root at lx6 cciss]# vgdisplay -v
>     Finding all volume groups
>     Finding volume group "VolGroup00"
>     Fixing up missing format1 size (30.27 GB) for PV /dev/cciss/c0d0p5
>   --- Volume group ---
>   VG Name               VolGroup00
>   System ID
>   Format                lvm2
>   Metadata Areas        1
>   Metadata Sequence No  7
>   VG Access             read/write
>   VG Status             resizable
>   MAX LV                0
>   Cur LV                5
>   Open LV               5
>   Max PV                0
>   Cur PV                1
>   Act PV                1
>   VG Size               30.25 GB
>   PE Size               32.00 MB
>   Total PE              968
>   Alloc PE / Size       870 / 27.19 GB
>   Free  PE / Size       98 / 3.06 GB
>   VG UUID               psKZl5-5omn-3pqG-S6Ip-i4wR-9OGc-7LSmbP
> 
>   --- Logical volume ---
>   LV Name                /dev/VolGroup00/LogVol00
>   VG Name                VolGroup00
>   LV UUID                Sng7Z5-PTPx-snkr-nAzW-PkKz-LkUt-7TZTaS
>   LV Write Access        read/write
>   LV Status              available
>   # open                 1
>   LV Size                4.00 GB
>   Current LE             128
>   Segments               1
>   Allocation             inherit
>   Read ahead sectors     0
>   Block device           253:0
> 
>   --- Logical volume ---
>   LV Name                /dev/VolGroup00/LogVol01
>   VG Name                VolGroup00
>   LV UUID                nDG0HT-xL9G-xD9D-emyJ-g4mf-huCj-SOvgnz
>   LV Write Access        read/write
>   LV Status              available
>   # open                 1
>   LV Size                5.00 GB
>   Current LE             160
>   Segments               2
>   Allocation             inherit
>   Read ahead sectors     0
>   Block device           253:1
> 
>   --- Logical volume ---
>   LV Name                /dev/VolGroup00/LogVol02
>   VG Name                VolGroup00
>   LV UUID                P9cXHo-BttJ-IHgo-b8Vw-xPjM-ncxA-Vjcv08
>   LV Write Access        read/write
>   LV Status              available
>   # open                 1
>   LV Size                1.00 GB
>   Current LE             32
>   Segments               1
>   Allocation             inherit
>   Read ahead sectors     0
>   Block device           253:2
> 
>   --- Logical volume ---
>   LV Name                /dev/VolGroup00/LogVol03
>   VG Name                VolGroup00
>   LV UUID                lDHKwJ-Y0Lf-3SR4-NoNr-ZjN2-cH4O-B8718x
>   LV Write Access        read/write
>   LV Status              available
>   # open                 1
>   LV Size                4.00 GB
>   Current LE             128
>   Segments               1
>   Allocation             inherit
>   Read ahead sectors     0
>   Block device           253:3
> 
>   --- Logical volume ---
>   LV Name                /dev/VolGroup00/LogVol04
>   VG Name                VolGroup00
>   LV UUID                jS7ech-ru2u-08JG-ulZp-sPbr-lfSV-2FsCCO
>   LV Write Access        read/write
>   LV Status              available
>   # open                 1
>   LV Size                13.19 GB
>   Current LE             422
>   Segments               1
>   Allocation             inherit
>   Read ahead sectors     0
>   Block device           253:4
> 
>   --- Physical volumes ---
>   PV Name               /dev/cciss/c0d0p5
>   PV UUID               NTkXuW-R4CJ-HqxT-WYAp-hOjb-8YTB-1Fj0vL
>   PV Status             allocatable
>   Total PE / Free PE    968 / 98
> 
> One volume group was only setup  "VolGroup00"
> 
> Geofrey Rainey wrote:
>> Hello,
>>
>> Firstly, please answer these two questions:
>>
>> 1. what do you see with this command:
>>
>> # fdisk -l
>>
>> 2. How many volume groups do you have? (you can find this information 
>> With the following command. The -v flag will give more verbose output 
>> including the logical volumes associated with each volume group):
>>
>> # vgdisplay -v
>> 		
>> Regards,
>> Geofrey Rainey
>>
>> -----Original Message-----
>> From: redhat-list-bounces at redhat.com
>> [mailto:redhat-list-bounces at redhat.com] On Behalf Of Kory Wheatley
>> Sent: Thursday, 27 September 2007 8:51 a.m.
>> To: General Red Hat Linux discussion list
>> Subject: Adding new disk to volume group
>>
>> Currently I'm using Red Hat Enterprise 4 that has two disk on a 
>> Hardware Raid 1 (Smart Array 5i controller) that is setup in  a Volume
> 
>> Group
>> (VolGroup00) with the following logical volumes LogVol00, LogVol01, 
>> LogVol02, LogVol03, LogVol04, and LogVol05.    I recently added two
> more
>> disks in our system/server  (these are internal disks on a HP Proliant
> 
>> DL380 g2) and set these disk as a Hardware Raid 1.  Now I haven't used
> 
>> Fdisk or nothing on these new disks.
>>
>> Here's my question:  How do I add the new disks to the already 
>> existing Volume Group so that I can have more space on the Volume 
>> Group.  Being a
>> Raid1 I know your only adding one disk.  Could someone send me the 
>> exact commands to use?
>> ==========================================================
>> For more information on the Television New Zealand Group, visit us 
>> online at tvnz.co.nz 
>> ==========================================================
>> CAUTION:  This e-mail and any attachment(s) contain information that 
>> is intended to be read only by the named recipient(s).  This 
>> information is not to be used or stored by any other person and/or
> organisation.
>>   
> ==========================================================
> For more information on the Television New Zealand Group, visit us
> online at tvnz.co.nz 
> ==========================================================
> CAUTION:  This e-mail and any attachment(s) contain information that
> is intended to be read only by the named recipient(s).  This information
> is not to be used or stored by any other person and/or organisation.
> 


-- 
Stephen Carville <stephen at totalflood.com>
Systems Engineer
Land America
1.626.667.1450 X1326
########################################################################
Semper in merda, sole profundum qui variat




More information about the redhat-list mailing list