### global_common.conf ################## global { usage-count no; # minor-count dialog-refresh disable-ip-verification } common { syncer { rate 100M; c-plan-ahead 20; c-fill-target 50k; c-min-rate 10M; al-extents 3833; use-rle; } handlers { # These are EXAMPLE handlers only. # They may have severe implications, # like hard resetting the node under certain circumstances. # Be careful when chosing your poison. pri-on-incon-degr "/usr/lib/drbd/notify-pri-on-incon-degr.sh; /usr/lib/drbd/notify-emergency-reboot.sh; echo b > /proc/sysrq-trigger ; reboot -f"; pri-lost-after-sb "/usr/lib/drbd/notify-pri-lost-after-sb.sh; /usr/lib/drbd/notify-emergency-reboot.sh; echo b > /proc/sysrq-trigger ; reboot -f"; local-io-error "/usr/lib/drbd/notify-io-error.sh; /usr/lib/drbd/notify-emergency-shutdown.sh; echo o > /proc/sysrq-trigger ; halt -f"; out-of-sync "/usr/lib/drbd/notify-out-of-sync.sh root"; ## avoid split-brain in pacemaker cluster fence-peer "/usr/lib/drbd/crm-fence-peer.sh"; split-brain "/usr/lib/drbd/notify-split-brain.sh root"; after-resync-target "/usr/lib/drbd/crm-unfence-peer.sh"; # before-resync-target "/usr/lib/drbd/snapshot-resync-target-lvm.sh -p 15 -- -c 16k"; # after-resync-target /usr/lib/drbd/unsnapshot-resync-target-lvm.sh; } startup { # wfc-timeout degr-wfc-timeout outdated-wfc-timeout wait-after-sb } options { # cpu-mask on-no-data-accessible } disk { # size max-bio-bvecs on-io-error fencing disk-barrier disk-flushes # disk-drain md-flushes resync-rate resync-after al-extents # c-plan-ahead c-delay-target c-fill-target c-max-rate # c-min-rate disk-timeout ## avoid split-brain in pacemaker cluster fencing resource-only; } net { # protocol timeout max-epoch-size max-buffers unplug-watermark # connect-int ping-int sndbuf-size rcvbuf-size ko-count # allow-two-primaries cram-hmac-alg shared-secret after-sb-0pri # after-sb-1pri after-sb-2pri always-asbp rr-conflict # ping-timeout data-integrity-alg tcp-cork on-congestion # congestion-fill congestion-extents csums-alg verify-alg # use-rle ## DRBD recovery policy after-sb-0pri discard-least-changes; after-sb-1pri call-pri-lost-after-sb; after-sb-2pri call-pri-lost-after-sb; } } #### r0.res file content ############# resource r0 { protocol C; startup { wfc-timeout 0; # non-zero wfc-timeout can be dangerous (http://forum.proxmox.com/threads/3465-Is-it-safe-to-use-wfc-timeout-in-DRBD-configuration) degr-wfc-timeout 60; become-primary-on sher; } net { shared-secret "S3cr3t"; sndbuf-size 0; max-buffers 8000; max-epoch-size 8000; } on sher { device /dev/drbd0; disk /dev/md0p1; address 192.168.0.21:7788; meta-disk internal; } on lock { device /dev/drbd0; disk /dev/md0p1; address 192.168.0.22:7788; meta-disk internal; } disk { # no-disk-barrier and no-disk-flushes should be applied only to systems with non-volatile (battery backed) controller caches. # Follow links for more information: # http://www.drbd.org/users-guide-8.3/s-throughput-tuning.html#s-tune-disable-barriers # http://www.drbd.org/users-guide/s-throughput-tuning.html#s-tune-disable-barriers # no-disk-barrier; # no-disk-flushes; no-md-flushes; } }