Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to configure a 2 node cluster with shared storage, but the configuration is probably little unusual. It is described below:

  1. Both nodes have access to a shared storage that has a number of drives. To cluster nodes they appear as local (SAN type of connection).
  2. Node A is going to use half of those drives to assemble a s/w RAID (let's name it SW_RAID1). On top of this s/w RAID there going to be LVM (say VG-1).
    Same for Node B except for that Node B creates its own s/w RAID (SW-RAID2) using other hard drives than node A.
  3. In case of a failure, the remaining node should take over all resources (both SW-RAID1 and 2 with VG-1 and VG-2 respectively).

The picture below illustrates the setup.

cluster topology

The question is: can I use plain LVM for this kind of setup or do I have to go with clustered LVM?

To my thinking I can use plain LVM because each volume group reseeds on an entity (/dev/md*) that is never going to be available on both nodes at a time (ensured by the cluster as it manages the above s/w RAIDs), so from LVM's perspective it is not even A/P.

Am I right? When answering, please, provide some reasoning if possible. Thanks!

share|improve this question

If I'm reading your question right, I think you're looking for DRBD. This will transparently keep the two servers' disks in sync, allowing one to fail over to the other without data loss.

share|improve this answer
Thanks for your answer - this is the first one I get here) No, not really. An external shared storage with a bunch of disks is something that is given (these drives do not belong to cluster nodes as in case with DRBD), so there is really no need to replicate them. What I'm asking for is whether I can use simple LVM instead of clustered LVM if all my LVs reseed on s/w RAIDs that I manage in cluster (the same s/w RAID is never activated on both nodes at the same time). Please, let me know what is unclear in my question and I'll try to rewrite that part. Thanks! – Pavel A Jan 29 '13 at 7:59
I have revised the question, so it should be more clear. Can you see what I mean now? – Pavel A Jan 29 '13 at 10:59

Theoretically you could, but I wouldn't. Sharing volumes between two servers when you have clean dismounts between handoffs should be fairly safe.

But what you're doing would not give you a clean dismount. This is why you should be using a clustered filesystem: it's designed to handle a server disappearing without corrupting the filesystem.

And as long as each server is not accessing the same files at the same time, there should be no effective difference in performance.

share|improve this answer
Thanks for answering. But what you're doing would not give you a clean dismount. Could you explain what you mean? What am I doing? This is why you should be using a clustered filesystem: it's designed to handle a server disappearing without corrupting the filesystem. Never heard of A/P clusters that use clustered filesystems. Or at least there are numerous A/P clusters that use normal filesystems and can surely handle the case when the active node fails. Please, explain your point further, because right now it seems to me as if you proposed to always use clustered FS even in A/P setups. – Pavel A Jan 29 '13 at 15:42
To further explain my setup: the cluster controls all the resources: s/w raid, lvm activation, filesystem mounting. If you are talking about node failure, than there is clearly no way filesystem can be cleanly dismounted, though it usually works. When using a normal filesystem in A/P setup we would rather kill/fence the errant node than let it access the storage, thus initiating the situation when FS is not cleanly unmounted. – Pavel A Jan 29 '13 at 15:52

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.