![]() |
HowTo.EnableRAIDSupport HistoryHide minor edits - Show changes to markup February 16, 2005, at 10:46 AM
by --
Added lines 7-8:
If you don't understand the commands listed below DO NOT ATTEMPT THIS. February 16, 2005, at 10:43 AM
by --
Added lines 5-6:
In fact, DO NOT ATTEMPT THIS unless you are *ABSOLUTELY* sure you know what youre doing. You can LOSE DATA if you are not careful when constructing the RAID. February 11, 2005, at 02:33 AM
by --
Changed lines 94-96 from:
=] to:
February 09, 2005, at 12:05 PM
by --
Added lines 3-4:
Before attempting this, be sure you know how RAID works under Linux. Changed line 9 from:
to:
Changed line 38 from:
# ./busybox.dy hdparm -t /dev/md0 to:
# ./busybox hdparm -t /dev/md0 Changed line 73 from:
# ./busybox.dy hdparm -t /dev/md0 to:
# ./busybox hdparm -t /dev/md0 Changed line 94 from:
=] to:
=] January 01, 2005, at 11:01 PM
by --
Deleted line 5:
Changed line 8 from:
to:
January 01, 2005, at 09:39 PM
by --
Changed line 3 from:
to:
December 26, 2004, at 09:39 PM
by --
Changed line 1 from:
RAID can be enabled in the -able family of Unslung-2.x firmware. to:
RAID can be enabled in the -able family of Unslung-2.x firmware or in the -standard family of Unslung 3.x firmware. December 07, 2004, at 01:36 AM
by --
Changed line 4 from:
to:
December 06, 2004, at 09:42 PM
by --
Added line 12:
November 08, 2004, at 05:19 AM
by --
Changed line 10 from:
to:
November 08, 2004, at 05:12 AM
by --
Changed line 10 from:
to:
Added lines 77-92:
Add a /etc/mdadm.conf file such as:
DEVICE /dev/sd[ab]1
ARRAY /dev/md0 devices=/dev/sda1,/dev/sdb1
level=1
num-devices=2
You will need to add lines to your diversion scripts. The following may be added to rc.local: /opt/sbin/insmod md /opt/sbin/insmod raid1 /opt/sbin/mdadm -As November 04, 2004, at 09:47 PM
by --
Changed line 1 from:
RAID can be enabled in the -able family of UNSLUNG-2.x firmware. to:
RAID can be enabled in the -able family of Unslung-2.x firmware. Changed lines 3-13 from:
1) Build the -able firmware using OE.
2) Build mdadm from Unslung CVS.
3) format 2 identical disks using the NSLU2 web interface
4) Build a special busybox that includes fdisk from Unslung CVS
5) Unsling
6) Disable USB_Detect
7) Using the busybox built in (4), change the partition type to fd (raid autodetect)
8) ipkg install kernel-module-md kernel-module-raid1 (or raid0 if you prefer)
9) mknod /dev/md0 b 9 0
10) Create the raid with mdadm.
11) done.
to:
November 04, 2004, at 10:15 AM
by --
Changed lines 11-12 from:
9) Create the raid with mdadm. 10) done. to:
9) mknod /dev/md0 b 9 0 10) Create the raid with mdadm. 11) done. Added lines 24-25:
# mke2fs -j /dev/md0 (messages) Changed lines 59-79 from:
mke2fs 1.34 (25-Jul-2003)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
10010624 inodes, 20008384 blocks
1000419 blocks (5.00%) reserved for the super user
First data block=0
611 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424
Writing inode tables: done
Creating journal (8192 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 22 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
to:
(messages) Changed line 61 from:
# df to:
# df /mnt/tmpmnt Deleted lines 62-64:
rootfs 123955 15465 107210 13% / /dev/sdb2 123955 15465 107210 13% / /dev/sdb2 123955 15465 107210 13% /share/flash/conf November 04, 2004, at 10:12 AM
by --
Added lines 33-38:
# ./busybox.dy hdparm -t /dev/md0 /dev/md0: Timing buffered disk reads: 64 MB in 7.42 seconds = 8.63 MB/sec # Changed lines 91-94 from:
# to:
# ./busybox.dy hdparm -t /dev/md0 /dev/md0: Timing buffered disk reads: 64 MB in 5.78 seconds = 11.07 MB/sec Added line 96:
# November 04, 2004, at 10:09 AM
by --
Changed line 14 from:
sample: to:
sample raid1: Changed lines 34-86 from:
Enjoy! to:
sample raid0: # insmod raid0
Using /lib/modules/2.4.22-xfs/kernel/drivers/md/raid0.o
# ./mdadm --create --level=0 --raid-devices=2 /dev/md0 /dev/sda1 /dev/sdb1
mdadm: /dev/sda1 appears to contain an ext2fs file system
size=40016880K mtime=Wed Nov 3 23:17:26 2004
mdadm: /dev/sda1 appears to be part of a raid array:
level=1 devices=2 ctime=Wed Nov 3 23:16:38 2004
mdadm: /dev/sdb1 appears to contain an ext2fs file system
size=40016880K mtime=Wed Nov 3 23:17:26 2004
mdadm: /dev/sdb1 appears to be part of a raid array:
level=1 devices=2 ctime=Wed Nov 3 23:16:38 2004
Continue creating array? y
mdadm: array /dev/md0 started.
# mke2fs -j /dev/md0
mke2fs 1.34 (25-Jul-2003)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
10010624 inodes, 20008384 blocks
1000419 blocks (5.00%) reserved for the super user
First data block=0
611 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424
Writing inode tables: done
Creating journal (8192 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 22 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
# mount /dev/md0 /mnt/tmpmnt
# df
Filesystem 1k-blocks Used Available Use% Mounted on
rootfs 123955 15465 107210 13% /
/dev/sdb2 123955 15465 107210 13% /
/dev/sdb2 123955 15465 107210 13% /share/flash/conf
/dev/md0 78777008 32828 74742504 0% /mnt/tmpmnt
# cat /proc/mdstat
Personalities : [raid0] [raid1]
read_ahead 1024 sectors
md0 : active raid0 sdb1[1] sda1[0]
80033536 blocks 64k chunks
unused devices: <none>
#
November 04, 2004, at 09:49 AM
by --
Changed lines 3-12 from:
1) Build the -able firmware using OE. 2) Build mdadm from Unslung CVS. 3) format 2 identical disks using the NSLU2 web interface 4) Build a special busybox that includes fdisk from Unslung CVS 5) Unsling 6) Disable USB_Detect 7) Using the busybox built in (4), change the partition type to fd (raid autodetect) 8) ipkg install kernel-module-md kernel-module-raid1 (or raid0 if you prefer) 9) Create the raid with mdadm. 10) done. to:
1) Build the -able firmware using OE.
2) Build mdadm from Unslung CVS.
3) format 2 identical disks using the NSLU2 web interface
4) Build a special busybox that includes fdisk from Unslung CVS
5) Unsling
6) Disable USB_Detect
7) Using the busybox built in (4), change the partition type to fd (raid autodetect)
8) ipkg install kernel-module-md kernel-module-raid1 (or raid0 if you prefer)
9) Create the raid with mdadm.
10) done.
November 04, 2004, at 09:45 AM
by --
Changed lines 1-34 from:
Describe EnableRAIDSupport here. to:
RAID can be enabled in the -able family of UNSLUNG-2.x firmware. 1) Build the -able firmware using OE. 2) Build mdadm from Unslung CVS. 3) format 2 identical disks using the NSLU2 web interface 4) Build a special busybox that includes fdisk from Unslung CVS 5) Unsling 6) Disable USB_Detect 7) Using the busybox built in (4), change the partition type to fd (raid autodetect) 8) ipkg install kernel-module-md kernel-module-raid1 (or raid0 if you prefer) 9) Create the raid with mdadm. 10) done. sample: # ./mdadm --create --level=1 --raid-devices=2 /dev/md0 /dev/sda1 /dev/sdb1
mdadm: /dev/sda1 appears to contain an ext2fs file system
size=40016880K mtime=Wed Nov 3 23:08:47 2004
mdadm: /dev/sdb1 appears to contain an ext2fs file system
size=40016880K mtime=Wed Nov 3 23:08:45 2004
Continue creating array? y
mdadm: array /dev/md0 started.
# cat /proc/mdstat
Personalities : [raid1]
read_ahead 1024 sectors
md0 : active raid1 sdb1[1] sda1[0]
40016768 blocks [2/2] [UU]
[>....................] resync = 0.2% (103040/40016768) finish=77.4min speed=8586K/sec
unused devices: <none>
# mount /dev/md0 /mnt/tmpmnt
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/md0 39388776 32832 38955776 0% /mnt/tmpmnt
Enjoy! |