How to do RAID0 with USB thumb drives using lvm
Posted: Thu 11 Sep 2008, 19:57
I have a eee running Pupeee off an 8g SDHC. I also have a pair of 16G USB thumb drives. So we want to tie the USB drives together and make them go fast. I chose raid0. Reliability will not be an issue. I do not need raid1 or any other mirror. I chose to use the raid built in to Linux lvm, because you can mix raid0, raid1, and ordinary lvm partitions all on the same virtual drive. You can also resize them very easily. In other words, administration is easy with lvm.
first what did not work ::
dmsetup :: almost useless, --notable does not work
very difficult to master, forget it
ndadm :: not worth the effort
Here is a breakdown of what I did.
/ install gslapt ( great stuff )
/ install Slackware 12.0 lvm and devmapper
/ modprobe dm-mod
/ pvcreate /dev/sdb1
/ pvcreate /dev/sdc1
/ vgcreate Egrp00 /dev/sdb1 /dev/sdc1
/ lvcreate -L 4567m -i 2 -I 64 Egrp00 -n Eraid00
/ mkreiserfs /dev/Egrp00/Eraid00
And you are ready to rock.
Speed read test ::
dd if=/dev/sdb of=/dev/null bs=512 count=40960
gave 10.5 MBs
dd if=/dev/Egrp00/Eraid00 bs=512 count=40960
gave 19.6 MBs
93.333% of double the speed of one drive is what I count as success.
I use a journaled fs on flash !! ? yep. With normal heavy usage, this will last for years, and replacing any failing stick is easy, as is adding to the array. The BIG advantage of lvm raid is that you can add drives which have different sizes. So, for me lvm is a clear winner.
The various commands like vgs, vgscan, ... lvs, ... are at your fingertips.
Read the lvm howto, and make this turn on at boot. You get one very fat pupeee.
Thanks for the gslapt package and to the pupeee team
first what did not work ::
dmsetup :: almost useless, --notable does not work
very difficult to master, forget it
ndadm :: not worth the effort
Here is a breakdown of what I did.
/ install gslapt ( great stuff )
/ install Slackware 12.0 lvm and devmapper
/ modprobe dm-mod
/ pvcreate /dev/sdb1
/ pvcreate /dev/sdc1
/ vgcreate Egrp00 /dev/sdb1 /dev/sdc1
/ lvcreate -L 4567m -i 2 -I 64 Egrp00 -n Eraid00
/ mkreiserfs /dev/Egrp00/Eraid00
And you are ready to rock.
Speed read test ::
dd if=/dev/sdb of=/dev/null bs=512 count=40960
gave 10.5 MBs
dd if=/dev/Egrp00/Eraid00 bs=512 count=40960
gave 19.6 MBs
93.333% of double the speed of one drive is what I count as success.
I use a journaled fs on flash !! ? yep. With normal heavy usage, this will last for years, and replacing any failing stick is easy, as is adding to the array. The BIG advantage of lvm raid is that you can add drives which have different sizes. So, for me lvm is a clear winner.
The various commands like vgs, vgscan, ... lvs, ... are at your fingertips.
Read the lvm howto, and make this turn on at boot. You get one very fat pupeee.
Thanks for the gslapt package and to the pupeee team