LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 08-23-2007, 09:33 AM   #1
cferron
Member
 
Registered: Jan 2006
Location: Trois-Rivières, Québec, Canada
Distribution: Slackware, Ubuntu
Posts: 74

Rep: Reputation: 15
Question USB software RAID questions


Hello,

I use slack 12.0 and kernel 2.6.21.5-smp

I have setup a software RAID array setup in one USB external drive (link that follow is not an ad, I want to show the unit.(http://www.startech.com/Product/Item...ESATCASE2&c=CA). Each drive inside are 500Gb. I have successfully created the Raid1 array (md0) with mdadm
command issued:
Code:
mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sdb1 /dev/sdc1
cat /proc/mdstat
Code:
Personalities : [linear] [raid1]
md0 : active raid1 sdc1[1] sdb1[0]
      488383936 blocks [2/2] [UU]

unused devices: <none>
The things I would like to know, understand:
1) md0 was created, now do I have to partion it, format it? Any suggestion?

2) Next time I boot will the system recognize the RAID? If so how? there is no config file....

3) What if the USB drives are connected in a different order and they get assigned a different sd"x" name as a device name!

4) Can I create a udev rule that will mount the RAID on the KDE desktop or a least in a directory I specify. What would be the unique thing I could recognize with udev? the md0 UUID?

5) I don't know if my drives (that compose the array) are DMA enabled... Can I check this (hdparm does not seem to work for the array, neither for it's devices) should I have done this before? Do I have to kill/stop my array md0 and start again.


Thanks for your help!

Claude

mdadm -D /dev/md0
Code:
/dev/md0:
        Version : 00.90.03
  Creation Time : Thu Aug 23 20:07:24 2007
     Raid Level : raid1
     Array Size : 488383936 (465.76 GiB 500.11 GB)
  Used Dev Size : 488383936 (465.76 GiB 500.11 GB)
   Raid Devices : 2
  Total Devices : 2
Preferred Minor : 0
    Persistence : Superblock is persistent

    Update Time : Fri Aug 24 10:06:18 2007
          State : active
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

           UUID : 44d19ca8:f36399f6:69aaf21d:159647a1
         Events : 0.7

    Number   Major   Minor   RaidDevice State
       0       8       17        0      active sync   /dev/sdb1
       1       8       33        1      active sync   /dev/sdc1
 
Old 08-24-2007, 04:35 AM   #2
mRgOBLIN
Slackware Contributor
 
Registered: Jun 2002
Location: New Zealand
Distribution: Slackware
Posts: 999

Rep: Reputation: 231Reputation: 231Reputation: 231
Quote:
Originally Posted by cferron View Post
Hello,

The things I would like to know, understand:
1) md0 was created, now do I have to partion it, format it? Any suggestion?

2) Next time I boot will the system recognize the RAID? If so how? there is no config file....

3) What if the USB drives are connected in a different order and they get assigned a different sd"x" name as a device name!

4) Can I create a udev rule that will mount the RAID on the KDE desktop or a least in a directory I specify. What would be the unique thing I could recognize with udev? the md0 UUID?

5) I don't know if my drives (that compose the array) are DMA enabled... Can I check this (hdparm does not seem to work for the array, neither for it's devices) should I have done this before? Do I have to kill/stop my array md0 and start again.
Really you should have a good read of this first.

http://www.userlocal.com/articles/ra...ackware-12.php

1) You need to format it.

2) Yes there is an /etc/mdadm.conf file

3) You should have set the drive partitions as type FD so they get auto-detected, the UUIDs will be in /etc/mdadm.conf after you add them.

4) Use /etc/fstab to mount the device /dev/md0 /where/ever/you/want

5) Well you are using the "Mass Storage" so I'm not sure if DMA has any effect there... maybe someone else has an answer for that.

Gobby
 
Old 08-25-2007, 11:50 AM   #3
cferron
Member
 
Registered: Jan 2006
Location: Trois-Rivières, Québec, Canada
Distribution: Slackware, Ubuntu
Posts: 74

Original Poster
Rep: Reputation: 15
Talking

Quote:
Originally Posted by mRgOBLIN View Post
1) You need to format it.
Well, here is what I did:
/dev/sdb1 (FD Linux RAID)
/dev/sdc1 (FD Linux RAID)
/dev/md0 Formatted as EXT3

Quote:
Originally Posted by mRgOBLIN View Post
2) Yes there is an /etc/mdadm.conf file
I was aware of that, but this config file says it was supposed to generate by itself and it did not.
DEVICE /dev/sdb1 /dev/sdc1
ARRAY /dev/md0 UUID=d83f99fa:c5eadb32:ca5f9faa:98d12bf
MAILADDR an_mail@gmail.com
PROGRAM /usr/sbin/handle-mdadm-events

As for the PROGRAM line, I'm not sure what to put there?
Quote:
Originally Posted by mRgOBLIN View Post
3) You should have set the drive partitions as type FD so they get auto-detected, the UUIDs will be in /etc/mdadm.conf after you add them.
Ok, but still I have USB drive that might not alwasy get mounted as sdb and sdc depending of the order I connect the drives... Sould I do a udev rules that will create /dev/raid_devices_1 & /dev/raid_devices_2 ??? Not sure where to start with this... Any suggestions?
Quote:
Originally Posted by mRgOBLIN View Post
4) Use /etc/fstab to mount the device /dev/md0 /where/ever/you/want
This is the line I added
/dev/md0 /mnt/raid ext3 auto,nouser,exec,rw 2 0


I this point I still wonder how md0 gets active espacially if the sdb1 and sdc1 are not present for a reason...???
 
Old 08-26-2007, 03:07 PM   #4
yoron
Member
 
Registered: Nov 2005
Posts: 120

Rep: Reputation: 15
If you want to use them as raid you will have to leave them as they are mounted, once and for all. Otherwise i belive in the idea. Try it :) And tell us if it worked ::))
They won't die, (i think :)

Last edited by yoron; 08-26-2007 at 03:08 PM.
 
  


Reply



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
software raid 5 + LVM and other raid questions slackman Slackware 5 05-09-2007 02:58 PM
Will a ex - Software Raid 1 disk boot without Raid software? carlosruiz Linux - Software 0 05-27-2006 01:12 PM
Questions about software RAID 3.14159 Linux - General 0 04-18-2005 02:37 PM
Software Raid 5 questions musicman_ace Linux - General 1 07-25-2004 07:32 AM
moving system from ide software raid to new box with scsi raid ftumsh Linux - General 0 10-28-2003 09:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 06:23 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