Forum
Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: DRBD Sync Rates

DRBD Sync Rates 2 months 3 weeks ago #1729

I have noticed a few people looking for answers about adjusting the replication sync rate for DRBD in HA-Lizard so I thought I'd just share some notes for those looking at improving theirs.

I myself was only getting a maximum of 40MB/s over a gigabit ethernet link which is stable but rather slow.

I improved that rate to 110MB/s to consume about 90% of my replication port bandwidth ie an ethernet crossover at 1Gbps (bypassing any switching gear). But not so much as to saturate.

The key is to increase the native max-buffers setting:

Just add a max-buffers entry to the net section of /etc/drbd.conf then execute 'service drbd reload' to apply the change.

a good place to start is:
max-buffers 100000

Just up the value from there until you reach a happy medium.

You might need to bump the syncer rate up a bit also as the default 100M refers to 100MB/s which is only about 800Mbps (80% of 1Gbe)

Additionally, you might want to add a disk{} section and use some further tweaks such as:

c-plan-ahead 0;


A tweaked drbd.conf might look something like this ;)
global { usage-count no; }
common { syncer { rate 120M; } }
resource iscsi1 {
protocol C;
disk {
c-plan-ahead 0;
c-fill-target 24M;
c-min-rate 80M;
c-max-rate 120M;
}
net {
max-buffers 120000;
after-sb-0pri discard-zero-changes;
after-sb-1pri consensus;
cram-hmac-alg sha1;
shared-secret PUTyourSECREThere;
}
on xcp1 {
device /dev/drbd1;
disk /dev/sda3;
address 10.10.10.1:7789;
meta-disk internal;
}
on xcp2 {
device /dev/drbd1;
disk /dev/sda3;
address 10.10.10.2:7789;
meta-disk internal;
}
}

Don't just slap it in and expect it to work for you...

There is some good reading about DRBD configuration here:
https://docs.linbit.com/docs/users-guide-8.3/p-performance/

and here:
https://docs.linbit.com/man/v9/drbd-conf-5/

Please Log in or Create an account to join the conversation.

Last edit: by Nathan.
  • Page:
  • 1