3

I have a problem with a HA Cluster running on CentOS 5.4 x86_64.

Software used:

  • DRBD 8 (kmod-drbd-xen-8.0.16-5.el5_3.x86_64 / drbd-8.0.16-5.el5.centos)
  • Heartbeat
  • LVM2
  • Xen 3.1.2

My DRBD configuration syncs a logical volume. When I first create the meta data for DRBD on the logical volume, it starts syncing and works fine. The problem I am having is that it will not update the data after the first synchronisation, so basically you get a one time copy and than it stops.

When I trash the logical volume on either, re-create it and initialize the meta data for DRBD, it just starts syncing again (but again only once).

It gives no out of sync errors or anything, cat /proc/drbd shows me 2 healthy UpToDate nodes.

I've tried syncing the physical volume instead, this resulted in Xen not being able to boot any VM (mounted in the privileged domain).

It seems that it's not giving me any incremental updates but there are no errors what so ever.

Edit://

I've tried both a active/passive and a active/active setup.

I know it's not being synchronised by sample files being added to the ext3 filesystem running on the LVM that is configured with drbd.

Thanks for your help so far, attached my drbd config;

global { usage-count no; }
resource repdata {
  protocol C;
  startup { wfc-timeout 0; degr-wfc-timeout     120; }
  disk { on-io-error detach; } # or panic, ...
  net {
        allow-two-primaries;
        after-sb-0pri discard-younger-primary;
        after-sb-1pri consensus;
        after-sb-2pri call-pri-lost-after-sb;
        cram-hmac-alg "sha1";
        shared-secret "XXX"; }
  handlers {
        pri-on-incon-degr "echo o > /proc/sysrq-trigger ; halt -f";
        pri-lost-after-sb "echo o > /proc/sysrq-trigger ; halt -f";
  }
  syncer { rate 100M; }
  on node1.xxxxx.com {
    device /dev/drbd0;
    disk /dev/xenVG/vlayer;
    address 10.0.67.50:7788;
    meta-disk internal;
  }
  on node2.xxxxx.com {
    device /dev/drbd0;
    disk /dev/xenVG/vlayer;
    address 10.0.67.60:7788;
    meta-disk internal;
  }
}
3
  • What leads you to believe that the data isn't being synchronised?
    – womble
    Nov 10, 2009 at 13:20
  • is it active/passive or active/active setup? also please paste drbd config
    – Martynas
    Nov 10, 2009 at 13:24
  • Where are your PVs located?
    – Nils
    Mar 15, 2012 at 20:37

1 Answer 1

2

I'm going to go out on a limb; from your description it sounds like you are mounting the volume on both DRBD participants.

You can't do this unless you are using a filesystem which supports shared-storage, such as OCFS2.

If you try do this with a filesystem like ext3 or XFS then you will discover huge inconsistencies in your data. Much like the behaviour which you describe.

2
  • Hi, this seems to indeed be the case. I tried to filter it in the lvm.conf and disable the VG on secondary node with "vgchange -a n", when I tried to start DRBD after this it couldn't find resources and therefore failed to start up.
    – SBO
    Nov 10, 2009 at 18:47
  • Then you'll either need to a) Change the filesystem, or b) Change your usage so that only one node has the block device(s) mounted at any one time.
    – Dan Carley
    Nov 27, 2009 at 10:52

You must log in to answer this question.