Chapter 4. Installing and Setting Up a BeagleBone RAID System

This chapter will serve as an installation guide for the software that will be used to create a RAID array out of the partitions that you will create on your USB-connected drives. This storage array will then hold all your media files (pictures, videos, and audio) in one drive instead of being spread out over several drives.

For the basics of RAID systems, take a look at http://en.wikipedia.org/wiki/RAID.

I don't want to discuss the basics because it is beyond the scope of this book, and other people have done a better job of explaining them than I can ever do. It is, however, important to understand that we will be building a "software" type of RAID array. There are two basic types of RAID arrays (not to be confused with modes, as in mode 0, mode 1, and so on).

The first type is called a hardware RAID, which as the name suggests, has specialized hardware that makes the array appear as one hard drive to the operating system.

The second type is the type that we will be creating here. This is called a software RAID because it uses a software program (mdadm) to create a RAID array using discrete drives attached to system.

Determining the available partitions

The first thing that we have to do is to determine the volumes that the Kernel thinks are available to it. We do this using the fdisk –l command.

Here's the output of the fdisk -l command before you've attached the USB hub and USB disks; the reader should note that only block devices (mmcblk) appear in the listing:

Determining the available partitions

Tip

If you connect the USB flash drives one at a time to your hub, you can label them as sda and sdb in case they are ever removed.

Moreover, here's the output of the command after you've attached the disks. Note that several new devices have appeared now. Rather that block devices, these devices appear as /dev/sda1 and so on.

Determining the available partitions

Tip

The term mount is a leftover from the "good old days" when a techie had to physically mount a disk or magnetic tape on a drive.

If you use the the df –k command, it will show you the filesystems that are mounted and their mount points.

Determining the available partitions
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.191.189.186