LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   RHEL 6 - join 2 hard drives as 1 volume? (https://www.linuxquestions.org/questions/linux-newbie-8/rhel-6-join-2-hard-drives-as-1-volume-4175466507/)

bluforce 06-18-2013 11:32 AM

RHEL 6 - join 2 hard drives as 1 volume?
 
Guys,
About to install RHEL 6 on a machine and use two 1TB drives in it for file storage purposes. I want my users to only be able to see one volume. I would need to use LVM to set this up, correct?

During the anaconda setup for RHEL 6, how would I need to create my custom layout? Setup SWAP, "/", and make the rest LVM? Not sure.

Thanks for the help.

cbtshare 06-18-2013 11:52 AM

While this can be done in Anaconda, I think its better to do it manually,unless its a bunch of machines and you wanna run kickstart on them.Here is some readup on kickstart to help.

szboardstretcher 06-18-2013 12:00 PM

In RHEL6, in GUI mode, this is done in the partition setup. Create physical volumes out of your hard drives. Then add them both to the logical volume. RHEL offers nice instructions if you have issues:

http://www.linuxtopia.org/online_boo...e_LVM-x86.html

bluforce 06-18-2013 01:29 PM

Thanks.

How would you recommend setting up my partitions under "custom layout"? I have a
sda - free - 953869MB and also
sdb - free - 953869MB.

I would to have these drives merged into one volume for the majority of space, which would be mounted at /data
Would I need to create /boot, /, and swap with the rest LVM on sda and sdb?

TIA

cbtshare 06-18-2013 01:40 PM

It all depends which way your going to do it....If you want to use the GUI then linux will create the ,/ and swap as LVM ..So just use the linux GUI tool and add create the LVM ...command line is easier to me :)

Madhu Desai 06-18-2013 02:29 PM

/boot connot be on LVM. Rest all could be on LVM.

In anaconda, set 200mb regular partition (ext4) on /dev/sda for /boot (/dev/sda1). Rest of the space add to volume group along with /dev/sdb.

Since you have 2 disks, you have three option to create logical volumes: Linear, Striped and Mirrored.

You can have more information of types of logical volumes and how to setup here: Logical Volume Administration

But i'm not sure these can be achieved on anaconda. :confused:

swamp-dog 06-18-2013 03:10 PM

Quote:

Originally Posted by bluforce (Post 4974308)
Thanks.

How would you recommend setting up my partitions under "custom layout"? I have a
sda - free - 953869MB and also
sdb - free - 953869MB.

I would to have these drives merged into one volume for the majority of space, which would be mounted at /data
Would I need to create /boot, /, and swap with the rest LVM on sda and sdb?

TIA

Choice is yours. I think you're considering raid0 or raid1 here. You can have raid0, 2Tb-(os space) or raid1, 1Tb-(os space). The former will lose everything if either disk fails. The latter will allow you to replace that failed disk and rebuild the new disk from the remaining good disk.

whizje 06-18-2013 03:25 PM

This is also an option:
Quote:

Linear mode

Ok, so you have two or more partitions which are not necessarily the same size (but of course can be), which you want to append to each other.

Spare-disks are not supported here. If a disk dies, the array dies with it. There's no information to put on a spare disk.

Using mdadm, a single command like

mdadm --create --verbose /dev/md0 --level=linear --raid-devices=2 /dev/sdb6 /dev/sdc5

should create the array. The parameters talk for themselves. The out- put might look like this

mdadm: chunk size defaults to 64K
mdadm: array /dev/md0 started.

Have a look in /proc/mdstat. You should see that the array is running.

Now, you can create a filesystem, just like you would on any other device, mount it, include it in your /etc/fstab and so on.


All times are GMT -5. The time now is 02:28 PM.