VERITAS Volume Manager and Vx Objects

VERITAS is a logical volume manager. The operative word here is "logical". So, in order to keep things in order we have some basic pieces which are used in different ways for building volumes. The better you understand these guys, the better you'll understand VERITAS. Here's the list of objects:

Now, lets talk about these objects a bit. A disk is nothing new or magical. When we want to use a disk in VERITAS we need to turn it over to VERITAS control. A disk turned over to VERITAS control is then given a VERITAS name (like disk01). After doing this the disk is no longer available to the system for anything outside of use inside VERITAS. Also, when we turn disks over to VERITAS control we don't turn over a partition (c0t0d0s0), but the whole disk itself (c0t0d0). Now that we've got a VM Disk we then create a Sub Disk from the VM Disk. Think of a subdisk as a VERITAS partition. We could make one big subdisk from the VM Disk and use the whole disk, or we could create a bunch of smaller subdisks. You can divide VM Disks into subdisks however you like. From subdisks (one or more) we create what is called a plex. Plexes are confusing so let's talk about these in some length.

Say the following out loud: "A Plex is a Mirror. A Plex is a Mirror. A Plex is a Mirror." Maybe you should do that a couple times. You may feel silly, but plexes are a sort of cornerstone in VERITAS. A Volume is a container, in VERITAS. The volume is made up of one or more plexes. See the catch? A Plex is a mirror, yes, however you can make a volume with only one plex. Is a volume made with only one plex mirrored? No. We'll explain this more later, but for the time being keep it in your head. So, subdisks are grouped together into a plex. The interesting thing is that in VERITAS the plexes do all the work, so lets say you wanted to create a Striped volume. You would actually create a striped plex, and then attach that striped plex to a volume. The volume doesn't care, it's just a container. See the beauty here? Let's put all this stuff together and build an imaginary volume in VERITAS.

We're going to build a striped (RAID0) volume from 2 9G disks. We'll say that the first disk is c1t0d0, and the second is c1t1d0. First, we need to put them in VERITAS control, so we create VM disks. The VM disks are then named disk01, and disk02. Next, we'll create subdisks using these two disks. Let's use the whole disks and just create 2 subdisks, one for each VM disk. We'll call disk01's subdisk "disk01-01", and disk02's subdisk "disk02-01". Now, it's plex time! We're going to build a striped plex using our two subdisks, which we'll call "myplex". (Don't worry yet about how we create the plex, just get the concepts now.) So now we've got a plex, which contains the subdisks "disk01-01" and "disk02-01". Now, we create a volume named "myvol" using "myplex". And bingo! We've got a striped 18G volume ready to create a file system on! Maybe, if we used the short names mentioned earlier (with the list of objects) and make an outline it'd look something like this:

dm      disk01  c1t0d0 <-- VM Disk named "disk01" made from "c1t0d0"
dm      disk02  c1t1d0 <-- VM named "disk02" made from "c1t1d0"

sd      disk01-01 disk01 <-- Subdisk named "disk01-01" made from "disk01"
sd      disk02-01 disk02 <-- Subdisk named "disk02-01" made from "disk02"

pl      myplex  striped <-- Striped Plex named "myplex"
sd      disk01-01       <-- Made using subdisk "disk01-01"
sd      disk02-01       <--   and subdisk "disk02-01"

v       myvol           <-- Volume made from....
pl      myplex striped  <-- the striped plex named "myplex", made from...
sd      disk01-01       <-- Subdisk "disk01-01", and...
sd      disk02-01       <--     "disk02-01"

Look OK? Because if it does, take a look at this, real output from VERITAS, from a real volume I created on my test machine:

v  myvol        fsgen        ENABLED  35356957 -        ACTIVE   -       -
pl myplex       myvol        ENABLED  35357021 -        ACTIVE   -       -
sd disk01-01    myplex       ENABLED  17678493 0        -        -       -
sd disk02-01    myplex       ENABLED  17678493 0        -        -       -

Does that make any sense? Any at all? I hope it does. And if it does, you're ready for VERITAS. We're going to explain more, much more, as we roll along, but at least understand that:

        Volumes are made up of plexes.
        Plexes are made up of subdisks.
        Subdisks are made up of VM Disks.
        VM Disks are made up of (real) Disks.

        and,

        Disks can be turned into VM Disks.
        Vm Disks can be turned into Subdisks.
        Subdisks can be grouped into Plexes.
        Plexes can be grouped into a Volume.

Good. One more note about plexes before we move on. Here's the groovy thing about plexes. Because plexes are "mirrors", we can mirror the volume we built earlier simply by building another plex identical to the first one, using two more subdisks (which means we need 2 more vmdisks, etc,etc). Once we build the second plex, we attach it to the volume (myvol) and presto chango! We're mirrored! This is really kool... mirrors are something magical, they are a part of everything. If you have only one mirror you may see yourself, but you'll need a second mirror to see yourself holding the mirror. Hmmm?