Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Sat 25 Oct 2014, 21:14
All times are UTC - 4
 Forum index » House Training » HOWTO ( Solutions )
RAID arrays in (Puppy) Linux
Moderators: Flash, Ian, JohnMurga
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
Page 2 of 3 Posts_count   Goto page: Previous 1, 2, 3 Next
Author Message
disciple

Joined: 20 May 2006
Posts: 6449
Location: Auckland, New Zealand

PostPosted: Sun 03 Apr 2011, 04:07    Post_subject:  

I pulled a couple of raid cards and the hard drives out of an old windows server from work and plugged them into my Puppy machine and they work without me doing anything, so I'm assuming they're hardware-RAID adapters... as opposed to them being BIOS-RAID adapters that my Puppy has somehow handled automatically.
_________________
DEATH TO SPREADSHEETS
- - -
Classic Puppy quotes
- - -
Beware the demented serfers!
Back to top
View user's profile Send_private_message 
toronado

Joined: 04 Sep 2013
Posts: 94

PostPosted: Tue 22 Oct 2013, 04:13    Post_subject:  

tempestuous wrote:
3. LINUX SOFTWARE RAID...
disable the RAID function in bios

On my MSI 6830E motherboard there are 4 IDE ports... 2 regular IDE ports, and 2 more that are intended for use with the BIOS RAID. I've always thought that the only way to have the BIOS RAID IDE ports functioning was to enable the BIOS RAID function in the BIOS (OnBoard ATA133 RAID). Otherwise the hard drives connected to those ports don't even show up in GParted.

Are you saying that by disabling the on-board BIOS RAID and by loading "modprobe raid1" those IDE ports will function and the devices connected to them will be visible to the OS?
Back to top
View user's profile Send_private_message 
tempestuous

Joined: 10 Jun 2005
Posts: 5271
Location: Australia

PostPosted: Tue 22 Oct 2013, 09:39    Post_subject:  

toronado wrote:
Are you saying that by disabling the on-board BIOS RAID and by loading "modprobe raid1" those IDE ports will function ...

No. With the RAID function disabled in bios, those ports should act as a standard IDE port, no extra drivers required.


toronado wrote:
I've always thought that the only way to have the BIOS RAID IDE ports functioning was to enable the BIOS RAID function in the BIOS (OnBoard ATA133 RAID). Otherwise the hard drives connected to those ports don't even show up in GParted.

Well I'm not familiar with the MS-6830E, or MSI KT3 Ultra, or whatever it's called, but unless there's something special about that board then this sounds very wrong.

My first thought is that maybe the bios settings are confusing - maybe there's a setting which enables the RAID ports, and a second setting which enables the RAID function associated with those ports? So maybe there's a distinction between "Enable" and "Enable RAID".

My second though is that you should check your drives and cables -
if there's a single IDE drive connected to each RAID port, then these drives should have their rear jumpers set for "MASTER" or "CABLE SELECT". If CABLE SELECT, then it's important that you connect the black plug on the IDE cable to the drive, not the grey plug.
You should certainly not have the jumpers on your drives set for "SLAVE".
Back to top
View user's profile Send_private_message 
toronado

Joined: 04 Sep 2013
Posts: 94

PostPosted: Tue 22 Oct 2013, 17:13    Post_subject:  

tempestuous, thanks for your reply.

The full name of this antique is "MSI KT3 Ultra-ARU", the "ARU" part designating that it has the two extra IDE ports (IDE 3 & IDE 4) for BIOS RAID (via a Promise PDC20276 chip), and that it supports USB 2.0 Smile

The hard drives connected to the BIOS RAID (IDE 3 & IDE 4) ports are jumpered for "master" and are connected to the "master" connectors on the drive cables.

AMIBIOS is the "main" motherboard BIOS.

There is an "other" BIOS which deals with the IDE RAID ports which is the MBFastTrack133 "Lite" BIOS by Promise Technology.

Within the AMIBIOS, under "Integrated Perhipherals", there is a setting for "OnBoard ATA133 RAID" which has just two possible options: "Enable" or "Disable".

If set to "Enable" then the "MBFastTrack133 BIOS" will run immediately after POST and scan those RAID IDE ports to see if any devices are connected, and determine if a RAID array exists. At this time you also have the option to enter the "FastBuild" utility to set-up an array.

(If set to "Disable" then the "MBFastTrack133 BIOS" will NOT run and devices connected to the BIOS RAID (IDE 3 & IDE 4) ports do not show up in GParted.)

If you do not have any array defined, and you do not enter the utility to set one up, then the MBFastTrack133 auto-creates two separate single-drive "arrays":

Array 1: 1+0 Stripe
Array 2: 1+0 Stripe

(I have tried deleting the single drive "arrays" after they are created, but MBFastTrack133 just reboots the computer and auto-creates them again. So there appears to be no way around the single-drive "arrays".)

These single-drive "arrays" show up in GParted as:
/dev/sda
/dev/sdb

It appears that the single-drive "arrays" are for all intents and purposes functioning as though these were normal IDE ports with single drives connected to them.

(IIRC, I used it this way with OpenFiler a while back and was able to use the software RAID functions within OpenFiler to create a RAID array or even just a JBOD setup.)

Do you think I might be able to use it this way with the Linux Software RAID in Puppy?
Back to top
View user's profile Send_private_message 
tempestuous

Joined: 10 Jun 2005
Posts: 5271
Location: Australia

PostPosted: Tue 22 Oct 2013, 23:40    Post_subject:  

OK, I think I understand - there's a secondary (separate) bios dedicated to the Promise controller for IDE 3/4.
toronado wrote:
If you do not have any array defined, and you do not enter the utility to set one up, then the MBFastTrack133 auto-creates two separate single-drive "arrays":

Array 1: 1+0 Stripe
Array 2: 1+0 Stripe

As you say, this autoconfiguration appears to be two "single-drive arrays" ... which seems a little silly to me, since the word "array" implies multiple drives! Personally I consider this configuration a "null array".

Yes, I suggest you proceed to treat these drives within Puppy Linux as though they are single, normal, drives.
My only worry is that the Promise controller may still be acting as a host-RAID interface (even though there's no RAID striping/mirroring involved) and it might be necessary to translate this interface to the Linux OS via the dmraid application.
If so, there's no way to get around using host-RAID, so you might as well use it to configure your 2-drive array ...
but let's not assume this worst case.

With the Promise bios enabled in its default state, as you described, boot up to Puppy Linux.
Don't install dmraid - let's see if the drives act as normal IDE devices -
with GParted define each drive as a single partition, and format them as ext3 (ext3 is my preferred drive format).
Just to be safe, reboot.
Hopefully Puppy will now see the two new drives. See if you can copy some files to/from these drives.
If successful, this means that the Promise host-RAID function is inactive or benign, and you can proceed to use Linux software RAID as I described in the third post.

Be aware that once you have configured your RAID array (using mdadm) that the formatting you previously did is now gone.
You must now treat the two drives as a single unit, and format them again. I prefer to do this from the commandline rather than use GParted.
Back to top
View user's profile Send_private_message 
tempestuous

Joined: 10 Jun 2005
Posts: 5271
Location: Australia

PostPosted: Tue 22 Oct 2013, 23:41    Post_subject:  

And here's an alternative approach - since you don't want the host-RAID functionality of the Promise controller, you can avoid using IDE3/4 altogether and just use IDE2 instead -
connect your two storage drives to IDE2, using a single IDE cable, with one drive set as MASTER, the other as SLAVE.
Software RAID will work just as well this way.
Back to top
View user's profile Send_private_message 
toronado

Joined: 04 Sep 2013
Posts: 94

PostPosted: Thu 24 Oct 2013, 00:55    Post_subject:  

Thanks tempestuous.

I formatted the drives as regular drives in GParted and I'm just going to use them as-is without any RAIDing for the time being. (configuring the software raid at the command line is a bit beyond my current comfort level anyway - maybe I'll give it a try in the future)

Can't use IDE 1 & 2 because they are already in use! Smile Got this box filled with old IDE drives. Hey, gotta do something with them.

BTW, I'm using ext4. Why do you prefer ext3?
Back to top
View user's profile Send_private_message 
tempestuous

Joined: 10 Jun 2005
Posts: 5271
Location: Australia

PostPosted: Thu 24 Oct 2013, 03:02    Post_subject:  

I was wary of ext4 when it was first introduced, because there seemed to be quite a few bugs with it, but it should be fine these days.

toronado wrote:
configuring the software raid at the command line is a bit beyond my current comfort level

Well I just updated my instructions in the third post with more detail, but here's exactly what I think you need -
first install the mdadm-3.1.4 dotpet.
Assuming you want RAID0 - the two drives striped for maximum capacity and speed, run these commands -
Code:
mdadm --create --verbose /dev/md0 --level=raid0 --raid-devices=2 /dev/sda1 /dev/sdb1

Wait until this initialization is completed, then save the RAID configuration with -
Code:
mdadm --detail --scan >> /etc/mdadm.conf

Format the new RAID array (md0) with ext4, using some special formatting options suited to RAID operation -
Code:
mkfs.ext4 -v -m .1 -b 4096 -E stride=32,stripe-width=64 /dev/md0

Finally, mount the RAID array -
Code:
mkdir /mnt/md0
mount /dev/md0 /mnt/md0

See if you can transfer some files to/from /mnt/md0
That's it.
Back to top
View user's profile Send_private_message 
toronado

Joined: 04 Sep 2013
Posts: 94

PostPosted: Thu 24 Oct 2013, 04:55    Post_subject:  

OK, I'll give it a try. But one question about this first line...
Code:
mdadm --create --verbose /dev/md0 --level=raid0 --raid-devices=2 /dev/sda1 /dev/sdb1

Before running this command, should the drives have only unallocated space, or should I have already created the partitions and formatted them?
Back to top
View user's profile Send_private_message 
tempestuous

Joined: 10 Jun 2005
Posts: 5271
Location: Australia

PostPosted: Thu 24 Oct 2013, 10:49    Post_subject:  

i) yes, the drives need to be partitioned first - each as a primary partition. I understand that you have done this already.
ii) it's no matter whether you format or not prior to the array creation. As the array is created, any existing formatting is destroyed anyway.
Back to top
View user's profile Send_private_message 
toronado

Joined: 04 Sep 2013
Posts: 94

PostPosted: Thu 24 Oct 2013, 17:12    Post_subject:  

tempestuous wrote:
i) yes, the drives need to be partitioned first - each as a primary partition. I understand that you have done this already.
ii) it's no matter whether you format or not prior to the array creation. As the array is created, any existing formatting is destroyed anyway.
OK, thanks for explaining. For the purpose of this exercise, I used GParted to create primary partitions (unformatted) on both drives, then proceeded with the commands you gave me.

Here is a copy/paste of the terminal session:
Code:
sh-4.1# mdadm --create --verbose /dev/md0 --level=raid0 --raid-devices=2 /dev/sda1 /dev/sdb1
mdadm: chunk size defaults to 512K
mdadm: Defaulting to version 1.2 metadata
mdadm: array /dev/md0 started.
sh-4.1# mdadm --detail --scan >> /etc/mdadm.conf
sh-4.1# mkfs.ext4 -v -m .1 -b 4096 -E stride=32,stripe-width=64 /dev/md0
mke2fs 1.41.14 (22-Dec-2010)
fs_types for mke2fs.conf resolution: 'ext4'
Calling BLKDISCARD from 0 to 160048349184 failed.
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=32 blocks, Stripe width=64 blocks
9773056 inodes, 39074304 blocks
39074 blocks (0.10%) reserved for the super user
First data block=0
Maximum filesystem blocks=0
1193 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks:
   32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
   4096000, 7962624, 11239424, 20480000, 23887872

Writing inode tables: done                           
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 33 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.
sh-4.1# mkdir /mnt/md0
sh-4.1# mount /dev/md0 /mnt/md0
sh-4.1#


At this point /mnt/md0 does not show up on the desktop, and Pmount doesn't see it at all. It does not appear to be mounted.

EDIT: I tried:
Code:
sh-4.1# mdadm --assemble /dev/md0
mdadm: /dev/md0 has been started with 2 drives.
sh-4.1# mount /dev/md0 /mnt/md0
And the md0 appeared on the desktop with the green dot. However when I clicked on it, it didn't open and instead Pmount launched and didn't see it.
Back to top
View user's profile Send_private_message 
tempestuous

Joined: 10 Jun 2005
Posts: 5271
Location: Australia

PostPosted: Thu 24 Oct 2013, 22:58    Post_subject:  

Don't be concerned that /mnt/md0 doesn't show up on the desktop, neither that Pmount doesn't see the array.
Both of these probably require extra code written into them to understand software arrays.

toronado wrote:
Code:
sh-4.1# mdadm --assemble /dev/md0
mdadm: /dev/md0 has been started with 2 drives.

This should only be necessary if the udev rule that I included in the mdadm dotpet fails to automatically restore the array at each bootup. This needs investigation.

toronado wrote:
Code:
sh-4.1# mount /dev/md0 /mnt/md0

This command appears to run without error - which means that Puppy can see the array, and mount it.
You should browse to /mnt/md0 with ROX, and see if you can transfer files to/from. If this fails, I suspect that the ext4 filesystem has failed to properly create within the array. In this case I suggest you reformat with ext3. To format, the array must first be unmounted -
Code:
umount /mnt/md0

now go ahead with the reformatting -
Code:
mkfs.ext3 -v -m .1 -b 4096 -E stride=32,stripe-width=64 /dev/md0
Back to top
View user's profile Send_private_message 
tempestuous

Joined: 10 Jun 2005
Posts: 5271
Location: Australia

PostPosted: Thu 24 Oct 2013, 22:59    Post_subject:  

Also, what version of Puppy are you running?
Back to top
View user's profile Send_private_message 
toronado

Joined: 04 Sep 2013
Posts: 94

PostPosted: Fri 25 Oct 2013, 01:01    Post_subject:  

tempestuous wrote:
Don't be concerned that /mnt/md0 doesn't show up on the desktop, neither that Pmount doesn't see the array.
Both of these probably require extra code written into them to understand software arrays.
OK.
tempestuous wrote:

toronado wrote:
Code:
sh-4.1# mdadm --assemble /dev/md0
mdadm: /dev/md0 has been started with 2 drives.

This should only be necessary if the udev rule that I included in the mdadm dotpet fails to automatically restore the array at each bootup. This needs investigation.
It is necessary on my system. Not sure why.
tempestuous wrote:

toronado wrote:
Code:
sh-4.1# mount /dev/md0 /mnt/md0

This command appears to run without error - which means that Puppy can see the array, and mount it.
You should browse to /mnt/md0 with ROX, and see if you can transfer files to/from.
It works. I just added the commands to assemble and mount the RAID array to my Samba Auto-Start script and it works great. I added a Samba share on md0 and it works great.

So basically, everything seems to be working. md0 isn't showing up on the desktop with this method, but as you said, that isn't really needed.

One thing is puzzling to me though... ROX seems to show empty directories in /mnt/ for partitions that don't exist. So, if I don't mount md0, there is a (empty) directory there anyway. (Once I mount md0 the directory shows the actual contents of the partition.) I found many other "dummy" directories there for previously created partitions and what not that no longer exist. I deleted these and they haven't reappeared so I think it's ok.
Back to top
View user's profile Send_private_message 
toronado

Joined: 04 Sep 2013
Posts: 94

PostPosted: Fri 25 Oct 2013, 01:01    Post_subject:  

tempestuous wrote:
Also, what version of Puppy are you running?
lupu528
Back to top
View user's profile Send_private_message 
Display_posts:   Sort by:   
Page 2 of 3 Posts_count   Goto page: Previous 1, 2, 3 Next
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
 Forum index » House Training » HOWTO ( Solutions )
Jump to:  

Rules_post_cannot
Rules_reply_cannot
Rules_edit_cannot
Rules_delete_cannot
Rules_vote_cannot
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1147s ][ Queries: 12 (0.0066s) ][ GZIP on ]