8.2.4. Setting Up a Resource


First see Resource Template (Protocol C) and add such settings to your drbd.conf file with the desired settings. Then setup a ZVOL in which you can mount the DRBD Resource.

Now proceed to create the meta-data for the DRBD Resource on every node

drbdadm create-md drbd0

Once that’s done you’ll want to start the DRBD Service on both nodes

service drbd start

Then you’ll want to make one of the nodes primary and have it overwrite whatever is on the other node’s Block Device.

drbdadm -- --overwrite-data-of-peer primary drbd0

Check sync status with

drbdadm status drbd0

Once both nodes finish sync you can make the other one a primary node too

drbdadm primary drbd0   ON NODE 2

Now if we go ahead and check the status of the DRBD Resource we should see both nodes are “uptodate” and Primary nodes.

After configuring everything you can now add the DRBD storage as an LVM storage on the clustered nodes that you’ve defined. (E.g.: PVE01 and PVE02). – YOU DON’T NEED TO ADD A FILESYSTEM


Remember to tick the “Shared” box when adding the storage.


You’ll always want to avoid unnecessary levels of complexity and layering when it comes to storage so that performance doesn’t tank too much.