Help with DRBD tuning

johjoh

Member
Feb 4, 2011
43
0
6
Hi, how I can deactivate encryption in DRBD resource, it's sufficient to erase the line into /etc/drbd.d/r0.res?
I'm thinking to convert DRBD from primary/primary to active/passive how I need to modify the configuration files?
Based on your experiences, I have two HP ProLiant DL360 G5 with two HP Smart Array P400 (512 MB + battery) and Gigabit NIC are HP NC373i, how would you tune up the configuration file of DRBD?

This are mine /etc/drbd.d/ro.res
Code:
resource r0 {        protocol C;
        startup {
                wfc-timeout  15;
                degr-wfc-timeout 60;
                become-primary-on both;
                }
        net {
                max-buffers 8000;
                max-epoch-size 8000;
                sndbuf-size 512k;
                cram-hmac-alg sha1;
                shared-secret "******";
                allow-two-primaries;
                after-sb-0pri discard-zero-changes;
                after-sb-1pri discard-secondary;
                after-sb-2pri disconnect;
                }
        syncer {
                rate 150M;
                }
        on emu1 {
                device /dev/drbd0;
                disk /dev/cciss/c0d1p1;
                address 192.168.50.1:7788;
                meta-disk internal;
                }
        on emu2 {
                device /dev/drbd0;
                disk /dev/cciss/c0d1p1;
                address 192.168.50.2:7788;
                meta-disk internal;
                }
}

And this are mine /etc/drbd.d/global_common.conf
Code:
global {    usage-count no;
    # minor-count dialog-refresh disable-ip-verification
}


common {
    protocol C;


    handlers {
        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";
        # fence-peer "/usr/lib/drbd/crm-fence-peer.sh";
        split-brain "/usr/lib/drbd/notify-split-brain.sh email@domain.ext";
        out-of-sync "/usr/lib/drbd/notify-out-of-sync.sh email@domain.ext";
        # 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;
    }


    disk {
        # on-io-error fencing use-bmbv no-disk-barrier no-disk-flushes
        # no-disk-drain no-md-flushes max-bio-bvecs   
    }


    net {
        # sndâ€buf-size rcvbuf-size timeout connect-int ping-int ping-timeout max-buffers
        # max-epoch-size ko-count allow-two-primaries cram-hmac-alg shared-secret
        # after-sb-0pri after-sb-1pri after-sb-2pri data-integrity-alg no-tcp-cork
    }


    syncer {
        # rate after al-extents use-rle cpu-mask verify-alg csums-alg
    }
}


Thank you very much :D !
 
Hi, how I can deactivate encryption in DRBD resource, it's sufficient to erase the line into /etc/drbd.d/r0.res?
I'm thinking to convert DRBD from primary/primary to active/passive how I need to modify the configuration files?
Based on your experiences, I have two HP ProLiant DL360 G5 with two HP Smart Array P400 (512 MB + battery) and Gigabit NIC are HP NC373i, how would you tune up the configuration file of DRBD?

This are mine /etc/drbd.d/ro.res
Code:
..
        net {
                max-buffers 8000;
                max-epoch-size 8000;
                sndbuf-size 512k;
                cram-hmac-alg sha1;
                shared-secret "******";
                allow-two-primaries;
                after-sb-0pri discard-zero-changes;
                after-sb-1pri discard-secondary;
                after-sb-2pri disconnect;
                }
       ...
Hi,
simply comment out "cram-hmac-alg sha1;" + "shared-secret "******";"
Code:
        net {
                max-buffers 8000;
                max-epoch-size 8000;
                sndbuf-size 512k;
                #cram-hmac-alg sha1;
                #shared-secret "******";
                allow-two-primaries;
                after-sb-0pri discard-zero-changes;
                after-sb-1pri discard-secondary;
                after-sb-2pri disconnect;
                }
Udo
 
I've never had to tune DRBD over a 1GB connection. DRBD should have no issues consuming that 1g link with no tuning parameters. Once you get into 10GB though, its best to use some of them.