Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   CentOS (http://www.linux-archive.org/centos/)
-   -   How to add a HD to a LVM (http://www.linux-archive.org/centos/523504-how-add-hd-lvm.html)

Todd Cary 05-07-2011 07:10 PM

How to add a HD to a LVM
 
I have connected a HD that was a prior system drive (Centos 4.8)
and I am not sure of the command line procedures to find out if
it is recognized (I believe it is since it present in the GUI),
delete all data on it and finally add it to the LVM.

I would like to use it as a backup data drive.

Todd

--
Ariste Software
Petaluma, CA 94952

http://www.aristesoftware.com

_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

Ljubomir Ljubojevic 05-07-2011 07:21 PM

How to add a HD to a LVM
 
Todd Cary wrote:
> I have connected a HD that was a prior system drive (Centos 4.8)
> and I am not sure of the command line procedures to find out if
> it is recognized (I believe it is since it present in the GUI),
> delete all data on it and finally add it to the LVM.
>
> I would like to use it as a backup data drive.
>
> Todd
>
either use "lvm ...." command to check, add, etc.. (google or use man
page) or use webmin to see and manage all of your drives (amongst other
things) on that system from nice and intuitive web config interface.

Ljubomir
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

Scott Robbins 05-07-2011 07:29 PM

How to add a HD to a LVM
 
On Sat, May 07, 2011 at 12:10:41PM -0700, Todd Cary wrote:
> I have connected a HD that was a prior system drive (Centos 4.8)
> and I am not sure of the command line procedures to find out if
> it is recognized (I believe it is since it present in the GUI),
> delete all data on it and finally add it to the LVM.
>
> I would like to use it as a backup data drive.

I have a page that might help. (It's not the best page in the world,
mostly done as a reference for myself, but....)

http://home.roadrunner.com/~computertaijutsu/lvm.html


--
Scott Robbins
PGP keyID EB3467D6
( 1B48 077D 66F6 9DB0 FDC2 A409 FA54 EB34 67D6 )
gpg --keyserver pgp.mit.edu --recv-keys EB3467D6

Cordelia: Everything has been taken away because Daddy made a
little mistake on his taxes... for the last twelve years.
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

David Lemcoe 05-07-2011 07:36 PM

How to add a HD to a LVM
 
On Sat, May 7, 2011 at 3:10 PM, Todd Cary <todd@aristesoftware.com> wrote:

I have connected a HD that was a prior system drive (Centos 4.8)
and I am not sure of the command line procedures to find out if

it is recognized (I believe it is since it present in the GUI),
delete all data on it and finally add it to the LVM.

I would like to use it as a backup data drive.

Todd

--
Ariste Software
Petaluma, CA 94952


http://www.aristesoftware.com

_______________________________________________
CentOS mailing list
CentOS@centos.org

http://lists.centos.org/mailman/listinfo/centos


_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

Digimer 05-07-2011 07:59 PM

How to add a HD to a LVM
 
On 05/07/2011 03:10 PM, Todd Cary wrote:
> I have connected a HD that was a prior system drive (Centos 4.8)
> and I am not sure of the command line procedures to find out if
> it is recognized (I believe it is since it present in the GUI),
> delete all data on it and finally add it to the LVM.
>
> I would like to use it as a backup data drive.
>
> Todd

Does pvscan or vgscan show it? If not, what is the device path and does
that fall within the 'filter = []' set in lvm.conf?

--
Digimer
E-Mail: digimer@alteeve.com
AN!Whitepapers: http://alteeve.com
Node Assassin: http://nodeassassin.org
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

Ken Smith 05-08-2011 07:03 AM

How to add a HD to a LVM
 
Todd Cary wrote:
> I have connected a HD that was a prior system drive (Centos 4.8)
> and I am not sure of the command line procedures to find out if
> it is recognized (I believe it is since it present in the GUI),
> delete all data on it and finally add it to the LVM.
>
> I would like to use it as a backup data drive.
>
> Todd
>
>
This is an excellent tutorial on LVM.

http://tldp.org/HOWTO/LVM-HOWTO/

Are you planning to join it to an existing Volume Group and then create
a LV on it for backup? My preference would be to keep things simple and
to aid recovery in the future, maybe just format the disk ext3 for
backup. Then it is easy to plug into another box for recovery. But, I'm
just guessing how you plan to use it.

Ken

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

Todd Cary 05-08-2011 02:37 PM

How to add a HD to a LVM
 
On 5/8/2011 12:03 AM, Ken Smith wrote:
>
> Todd Cary wrote:
>> I have connected a HD that was a prior system drive (Centos 4.8)
>> and I am not sure of the command line procedures to find out if
>> it is recognized (I believe it is since it present in the GUI),
>> delete all data on it and finally add it to the LVM.
>>
>> I would like to use it as a backup data drive.
>>
>> Todd
>>
>>
> This is an excellent tutorial on LVM.
>
> http://tldp.org/HOWTO/LVM-HOWTO/
>
> Are you planning to join it to an existing Volume Group and then create
> a LV on it for backup? My preference would be to keep things simple and
> to aid recovery in the future, maybe just format the disk ext3 for
> backup. Then it is easy to plug into another box for recovery. But, I'm
> just guessing how you plan to use it.
>
> Ken
>
Ken -

Thank you for your response. What you suggested is exactly what
I would like to do: have an extra, stand alone, drive for
backup. However, when I do

fdisk -l

I get the output below which has me concerned. As a "Sunday
afternoon" user of Centos, I am not 100% sure of my
interpretation - that is - the drive is already been joined as
part of the LVM even though all I did was to plug it in as a slave.

My installation of Centos 5.5 is new and I do not remember
specifying LVM (though that is what I had with my 4.8 system).
The /dev/hdc (250 GB) is the new system drive. The /dev/hdd is
the old Centos 4.8 drive that I would like to have as an
independent drive e.g. /dev/hda or whatever it needs to be.

What I DO NOT want to happen is for me to accidentally mess up my
new Centos 5.5 system :-)!!

Questions:

* Is it possible to "remove" /dev/hdd from the LVM - at least it
appears to be part of it
* Once removed, format it as EXT3 and mount it as /dev/hda (or
/dev/hdd)

For this I am swimming in unknown waters.

Todd

Disk /dev/hdc: 251.0 GB, 251000193024 bytes
255 heads, 63 sectors/track, 30515 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hdc1 * 1 13 104391 83 Linux
/dev/hdc2 14 30515 245007315 8e Linux LVM

Disk /dev/hdd: 163.9 GB, 163928604672 bytes
255 heads, 63 sectors/track, 19929 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hdd1 * 1 13 104391 83 Linux
/dev/hdd2 14 19929 159975270 8e Linux LVM

Disk /dev/sda: 81.9 GB, 81964302336 bytes
255 heads, 63 sectors/track, 9964 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 1 9964 80035798+ 7 HPFS/NTFS


--
Ariste Software
Petaluma, CA 94952

http://www.aristesoftware.com

_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

Charlie Brune 05-08-2011 03:05 PM

How to add a HD to a LVM
 
On 05/08/2011 09:37 AM, Todd Cary wrote:
> On 5/8/2011 12:03 AM, Ken Smith wrote:
>> Todd Cary wrote:
>>> I have connected a HD that was a prior system drive (Centos 4.8)
>>> and I am not sure of the command line procedures to find out if
>>> it is recognized (I believe it is since it present in the GUI),
>>> delete all data on it and finally add it to the LVM.
>>>
>>> I would like to use it as a backup data drive.
>>>
>>> Todd
>>>
>>>
>> This is an excellent tutorial on LVM.
>>
>> http://tldp.org/HOWTO/LVM-HOWTO/
>>
>> Are you planning to join it to an existing Volume Group and then create
>> a LV on it for backup? My preference would be to keep things simple and
>> to aid recovery in the future, maybe just format the disk ext3 for
>> backup. Then it is easy to plug into another box for recovery. But, I'm
>> just guessing how you plan to use it.
>>
>> Ken
>>
> Ken -
>
> Thank you for your response. What you suggested is exactly what
> I would like to do: have an extra, stand alone, drive for
> backup. However, when I do
>
> fdisk -l
>
> I get the output below which has me concerned. As a "Sunday
> afternoon" user of Centos, I am not 100% sure of my
> interpretation - that is - the drive is already been joined as
> part of the LVM even though all I did was to plug it in as a slave.
>
> My installation of Centos 5.5 is new and I do not remember
> specifying LVM (though that is what I had with my 4.8 system).
> The /dev/hdc (250 GB) is the new system drive. The /dev/hdd is
> the old Centos 4.8 drive that I would like to have as an
> independent drive e.g. /dev/hda or whatever it needs to be.
>
> What I DO NOT want to happen is for me to accidentally mess up my
> new Centos 5.5 system :-)!!
>
> Questions:
>
> * Is it possible to "remove" /dev/hdd from the LVM - at least it
> appears to be part of it
> * Once removed, format it as EXT3 and mount it as /dev/hda (or
> /dev/hdd)
>
> For this I am swimming in unknown waters.
>
> Todd
>
> Disk /dev/hdc: 251.0 GB, 251000193024 bytes
> 255 heads, 63 sectors/track, 30515 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes
>
> Device Boot Start End Blocks Id System
> /dev/hdc1 * 1 13 104391 83 Linux
> /dev/hdc2 14 30515 245007315 8e Linux LVM
>
> Disk /dev/hdd: 163.9 GB, 163928604672 bytes
> 255 heads, 63 sectors/track, 19929 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes
>
> Device Boot Start End Blocks Id System
> /dev/hdd1 * 1 13 104391 83 Linux
> /dev/hdd2 14 19929 159975270 8e Linux LVM
>
> Disk /dev/sda: 81.9 GB, 81964302336 bytes
> 255 heads, 63 sectors/track, 9964 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes
>
> Device Boot Start End Blocks Id System
> /dev/sda1 1 9964 80035798+ 7 HPFS/NTFS
>
>
For working with LVM's, I've found that the "system-config-lvm" GUI tool
is excellent. It's really great for when I want to reduce a logical
volume, since it handles resizing both the file system and the volume
group for you).

It will display all of your drives/partitions and let you adjust them
for what you describe.

Please take a look at it and feel free to post any questions.

Charlie

P.S. I'm a Unix Admin, so I love the command line ... this is one of the
few times where I recommend a GUI tool over typing the commands.
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

Todd Cary 05-08-2011 03:50 PM

How to add a HD to a LVM
 
On 5/8/2011 8:05 AM, Charlie Brune wrote:
> On 05/08/2011 09:37 AM, Todd Cary wrote:
>> On 5/8/2011 12:03 AM, Ken Smith wrote:
>>> Todd Cary wrote:
>>>> I have connected a HD that was a prior system drive (Centos 4.8)
>>>> and I am not sure of the command line procedures to find out if
>>>> it is recognized (I believe it is since it present in the GUI),
>>>> delete all data on it and finally add it to the LVM.
>>>>
>>>> I would like to use it as a backup data drive.
>>>>
>>>> Todd
>>>>
>>>>
>>> This is an excellent tutorial on LVM.
>>>
>>> http://tldp.org/HOWTO/LVM-HOWTO/
>>>
>>> Are you planning to join it to an existing Volume Group and then create
>>> a LV on it for backup? My preference would be to keep things simple and
>>> to aid recovery in the future, maybe just format the disk ext3 for
>>> backup. Then it is easy to plug into another box for recovery. But, I'm
>>> just guessing how you plan to use it.
>>>
>>> Ken
>>>
>> Ken -
>>
>> Thank you for your response. What you suggested is exactly what
>> I would like to do: have an extra, stand alone, drive for
>> backup. However, when I do
>>
>> fdisk -l
>>
>> I get the output below which has me concerned. As a "Sunday
>> afternoon" user of Centos, I am not 100% sure of my
>> interpretation - that is - the drive is already been joined as
>> part of the LVM even though all I did was to plug it in as a slave.
>>
>> My installation of Centos 5.5 is new and I do not remember
>> specifying LVM (though that is what I had with my 4.8 system).
>> The /dev/hdc (250 GB) is the new system drive. The /dev/hdd is
>> the old Centos 4.8 drive that I would like to have as an
>> independent drive e.g. /dev/hda or whatever it needs to be.
>>
>> What I DO NOT want to happen is for me to accidentally mess up my
>> new Centos 5.5 system :-)!!
>>
>> Questions:
>>
>> * Is it possible to "remove" /dev/hdd from the LVM - at least it
>> appears to be part of it
>> * Once removed, format it as EXT3 and mount it as /dev/hda (or
>> /dev/hdd)
>>
>> For this I am swimming in unknown waters.
>>
>> Todd
>>
>> Disk /dev/hdc: 251.0 GB, 251000193024 bytes
>> 255 heads, 63 sectors/track, 30515 cylinders
>> Units = cylinders of 16065 * 512 = 8225280 bytes
>>
>> Device Boot Start End Blocks Id System
>> /dev/hdc1 * 1 13 104391 83 Linux
>> /dev/hdc2 14 30515 245007315 8e Linux LVM
>>
>> Disk /dev/hdd: 163.9 GB, 163928604672 bytes
>> 255 heads, 63 sectors/track, 19929 cylinders
>> Units = cylinders of 16065 * 512 = 8225280 bytes
>>
>> Device Boot Start End Blocks Id System
>> /dev/hdd1 * 1 13 104391 83 Linux
>> /dev/hdd2 14 19929 159975270 8e Linux LVM
>>
>> Disk /dev/sda: 81.9 GB, 81964302336 bytes
>> 255 heads, 63 sectors/track, 9964 cylinders
>> Units = cylinders of 16065 * 512 = 8225280 bytes
>>
>> Device Boot Start End Blocks Id System
>> /dev/sda1 1 9964 80035798+ 7 HPFS/NTFS
>>
>>
> For working with LVM's, I've found that the "system-config-lvm" GUI tool
> is excellent. It's really great for when I want to reduce a logical
> volume, since it handles resizing both the file system and the volume
> group for you).
>
> It will display all of your drives/partitions and let you adjust them
> for what you describe.
>
> Please take a look at it and feel free to post any questions.
>
> Charlie
>
> P.S. I'm a Unix Admin, so I love the command line ... this is one of the
> few times where I recommend a GUI tool over typing the commands.
> _______________________________________________
> CentOS mailing list
> CentOS@centos.org
> http://lists.centos.org/mailman/listinfo/centos
>
>
I am off for a ten day trip, but when I return I'll take a look
at it.

Todd

--
Ariste Software
Petaluma, CA 94952

http://www.aristesoftware.com

_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos

Todd Cary 05-08-2011 04:21 PM

How to add a HD to a LVM
 
On 5/8/2011 7:37 AM, Todd Cary wrote:
> On 5/8/2011 12:03 AM, Ken Smith wrote:
>> Todd Cary wrote:
>>> I have connected a HD that was a prior system drive (Centos 4.8)
>>> and I am not sure of the command line procedures to find out if
>>> it is recognized (I believe it is since it present in the GUI),
>>> delete all data on it and finally add it to the LVM.
>>>
>>> I would like to use it as a backup data drive.
>>>
>>> Todd
>>>
>>>
>> This is an excellent tutorial on LVM.
>>
>> http://tldp.org/HOWTO/LVM-HOWTO/
>>
>> Are you planning to join it to an existing Volume Group and then create
>> a LV on it for backup? My preference would be to keep things simple and
>> to aid recovery in the future, maybe just format the disk ext3 for
>> backup. Then it is easy to plug into another box for recovery. But, I'm
>> just guessing how you plan to use it.
>>
>> Ken
>>
> Ken -
>
> Thank you for your response. What you suggested is exactly what
> I would like to do: have an extra, stand alone, drive for
> backup. However, when I do
>
> fdisk -l
>
> I get the output below which has me concerned. As a "Sunday
> afternoon" user of Centos, I am not 100% sure of my
> interpretation - that is - the drive is already been joined as
> part of the LVM even though all I did was to plug it in as a slave.
>
> My installation of Centos 5.5 is new and I do not remember
> specifying LVM (though that is what I had with my 4.8 system).
> The /dev/hdc (250 GB) is the new system drive. The /dev/hdd is
> the old Centos 4.8 drive that I would like to have as an
> independent drive e.g. /dev/hda or whatever it needs to be.
>
> What I DO NOT want to happen is for me to accidentally mess up my
> new Centos 5.5 system :-)!!
>
> Questions:
>
> * Is it possible to "remove" /dev/hdd from the LVM - at least it
> appears to be part of it
> * Once removed, format it as EXT3 and mount it as /dev/hda (or
> /dev/hdd)
>
> For this I am swimming in unknown waters.
>
> Todd
>
> Disk /dev/hdc: 251.0 GB, 251000193024 bytes
> 255 heads, 63 sectors/track, 30515 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes
>
> Device Boot Start End Blocks Id System
> /dev/hdc1 * 1 13 104391 83 Linux
> /dev/hdc2 14 30515 245007315 8e Linux LVM
>
> Disk /dev/hdd: 163.9 GB, 163928604672 bytes
> 255 heads, 63 sectors/track, 19929 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes
>
> Device Boot Start End Blocks Id System
> /dev/hdd1 * 1 13 104391 83 Linux
> /dev/hdd2 14 19929 159975270 8e Linux LVM
>
> Disk /dev/sda: 81.9 GB, 81964302336 bytes
> 255 heads, 63 sectors/track, 9964 cylinders
> Units = cylinders of 16065 * 512 = 8225280 bytes
>
> Device Boot Start End Blocks Id System
> /dev/sda1 1 9964 80035798+ 7 HPFS/NTFS
>
>
Whether I use the lvm command line or the GUI, I am not sure if I
am suppose to remove the logical first as in

lvm lvremove LogVol01

Using the GUI, I get

Logical volume LogVol01 contains swap filesystem. All data on it
will be lost! Are you quite certain that you wish to remove
logical volume LogVol01?

--
Ariste Software
Petaluma, CA 94952

http://www.aristesoftware.com

_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


All times are GMT. The time now is 06:31 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.