In this lesson,
we're going to discuss data redundancy.
Now, one of the most effective ways
to create data redundancy is to use a RAID.
A RAID is a redundant array of independent disks,
which allows an organization
to combine multiple physical storage devices
into a single logical storage device
that's recognized by your operating system.
There are many types of RAIDs out there,
but the most common ones
and most popular ones we're going to discuss
are RAID 0, RAID 1, RAID 5, RAID 6,
and RAID 10.
First, we have a RAID 0.
A RAID 0 provides data striping across multiple disks,
and it's used to increase your performance.
The keyword that you need to remember
for a RAID 0 is striping.
Now, a RAID 0 should be used when you need performance,
but you don't really care about fault tolerance.
In fact, a RAID 0 is the only kind of RAID
that does not provide you with any kind of data redundancy,
but instead, it provides us with faster read
and write speeds
because your data is being split across multiple drives
inside of that RAID
to overcome the physical speed limitations
of traditional hard disk drives
and other slower storage devices.
For example, if I was building
a high-end video editing workstation,
I might want to use a RAID 0
to have two hard disk drives working together,
so I could work on my raw video files
faster than I could by using a single hard disk drive.
To create a RAID 0, you need to have at least two disks
that can be configured to work in tandem with each other.
Second, we have a RAID 1.
Now, a RAID 1 is going to be used to provide redundancy
by mirroring your data identically onto two hard disk drives
or solid state devices.
This way, if one of those storage devices fails,
the other one can continue to operate
because it has a full copy of everything
that was included on those drives.
The key word you need to remember
for a RAID 1 is mirroring.
Now a RAID 1 provides the least amount of downtime
because there's always a complete copy
of your data ready at a moment's notice
that can be served up to your end users.
A RAID 1 is going to provide us
with some great fault tolerance,
but it can only be used with two physical storage devices,
which, in turn, only provides you
with one single logical storage device
that can be read or written to by the operating system.
For a RAID 1, you can only lose one storage device
and still be able to operate the array
without suffering from any data loss or downtime.
For example, on that high-end video editing workstation
I mentioned, I might also want to add
two other physical storage devices
that are configured as a RAID 1.
This way, I can use that
to store all of my finished videos on.
This will ensure that I always have an online
and on-demand backup ready
in case one of my storage devices fails
because both devices will have a fully mirrored
identical copy of the data on them.
Third, we have a RAID 5.
Now, a RAID 5 is known as a striping disk with parity,
and it requires the use
of at least three physical storage devices
in order for it to work.
A RAID 5 will provide us with fault tolerance
by striping the data
across multiple physical storage devices,
as well as writing the parity data across the disk array.
The keywords that you need to remember
for a RAID 5 is striping with parity.
Now, if one disk fails, the other two are going to be able
to reconstruct the data based on the parity,
and that way they can continue their normal operations,
but at a slower speed
because the missing portions of data
have to be calculated on the fly
when the user's requesting the data from the server.
So if one of those drives fails,
you can actually remove the failed drive,
install a new drive into the server,
while the server continues to operate,
which we call a hot swap,
and then the server will rebuild the missing data
onto the newly installed drive
by calculating all those missing pieces
by using the Stripe data pieces
and the parity to calculate the missing dataset.
Now, for a RAID 5, you can only lose one storage device
and still be able to rebuild the data in the RAID
without suffering from any downtime.
So keep that in mind, too.
Fourth, we have a RAID 6.
Now, a RAID 6 is a modified form of a RAID 5
that relies on the use
of data striping across multiple storage devices,
like a RAID 5 does,
but instead of having a single piece of parity data,
we're actually going to have two identical pieces
of parity data.
I like to joke around and say
that "RAID 6 is one better than RAID 5,
so instead of having one set of parity,
we now have two sets of parity
because it is one more than RAID 5."
Now, to achieve this double parity,
your RAID must have at least four storage devices
contained within your RAID 6 array.
Now, the benefit of using a RAID 6
over a RAID 5 is that you can now lose
two of your storage devices
and still be able to rebuild the data
without suffering from any downtime.
So it does give you some more resiliency and redundancy.
Now, the keywords you need to remember
for a RAID 6 is striping with double parity.
Fifth, we have a RAID 10, also known as a RAID 10.
Now, a RAID 10, or a RAID 10
will combine the advantages of a RAID 1
and a RAID 0 into a single RAID array.
Essentially, a RAID 10 is going to be a striped array
that contains two sets of mirrored arrays within it.
This is why we call it a RAID 10
because it first mirrors the two sets
of storage devices into a RAID 1,
and then it stripes the data across both sets
of mirrored storage devices using a RAID 0 configuration.
So RAID 1 plus RAID 0 gives us RAID 10,
or RAID 10 as we write it out.
Now, the keywords you need to remember
for a RAID 10 is that
it is a striped array of mirrored arrays.
Now, a RAID 10 or RAID 10 also supports the use
of even numbers of physical storage devices
to create this kind of an array,
and you have to at least force physical storage devices
in the RAID to create a minimum of two sets
of mirrored RAID 1s to be able to use
inside of your RAID 10.
A RAID 10 will provide us
with fault tolerance due to the mirrored arrays
inside of the RAID 10.
But it also provides us with faster speeds
because of the striping of the data
across two different sets of mirrored arrays
inside of the RAID 10.
Now, a RAID 10 can support the loss
of up to two of your storage devices
and still be able to rebuild the data
without suffering from any downtime,
as long as the loss of the storage devices
are not both located in the same mirrored array.
So if you lose one storage device
from each mirrored set, that's fine.
The RAID 10 will continue to operate
without any issues,
but you will have lost your fault tolerance capability
if you lost a drive from each set of the mirrors.
So you'll want to replace those failed storage devices
as soon as possible.
Now, when we talk about the classification
and categorization of our RAIDs,
we call these either failure-resistant, fault-tolerant,
or disaster-tolerant.
Each of these terms describes a level of resilience
that a RAID system can provide against data loss
and system downtime.
When we're dealing with failure-resistant systems,
these are systems that are designed
to withstand certain hardware malfunctions
without losing the associated data.
And failure resistance is going to be achieved
through redundancy of your storage devices
by mirroring data across multiple storage devices.
This means that if one device fails,
the system can continue to operate
using the data on the remaining devices.
So when you think about a failure-resistant system,
we're really talking about any of the systems
that use mirroring, which is a RAID 1
or a RAID 10.
Now, a fault-tolerant system, on the other hand,
is going to be designed to not only allow
for the continued operation
without any downtime being experienced,
but also allows the system to maintain its operations
in the event of a hardware failure
due to either mirroring or striping with parity,
such as in a RAID 1, RAID 5, RAID 6, or RAID 10.
With fault tolerant systems, your system has the ability
to quickly rebuild any lost data
from the remaining healthy storage devices
to ensure your systems remain resilient.
Now, a disaster-tolerant system
includes a broader level of protection
by safeguarding your data against catastrophic events.
Disaster-tolerant RAIDs utilize two independent zones
that always have full access to all of the data.
A RAID 1 and a RAID 10 are both examples
of disaster-tolerant RAIDs
because they have full mirrors of the data
on at least one of the storage devices within the array.
So remember, RAIDs are a great thing to use
when you're trying to ensure
you have a good redundancy of your data,
both online and available at all times.
A RAID is a redundant array of independent disks,
which allows an organization
to combine multiple physical storage devices
into a single logical storage device
that is recognized by your operating system.
A RAID 0 is going to enhance the performance
by striping your data evenly
across two or more storage devices
without any kind of redundancy
to facilitate a high speed access,
but you're not going to have any fault tolerance.
A RAID 1 is going to maintain an exact copy of the data,
which is known as a mirror,
on two or more storage devices
to increase your read performance
and ensure data integrity and availability,
even if a single storage device in the RAID fails.
A RAID 5 is going to distribute data and parity information
across three or more disks to improve the read
and write performance while also providing fault tolerance.
A RAID 6 is similar to a RAID 5,
but it adds an extra parity block
so that the data and double parity
is going to be striped across four or more storage devices
to help withstand the failure
of two storage devices simultaneously
without having any kind of data loss.
A RAID 10,
will combine the advantages of a RAID 1 and a RAID 0
by striping data across mirrored sets of storage devices
to offer higher performance, fault tolerance,
and improved data redundancy.
By relying on the use of RAIDs,
we can increase our overall availability
when we're designing high availability systems
for our enterprise networks.