[DRBD-user] heartbeat with drbd

Thomas Fischer tfj at gmx.de
Fri May 14 11:22:58 CEST 2004

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


Hello *,

I use drbd and dm-crypt with kernel 2.6.5 with debian woody on
db1 (192.168.1.1) and db2 (192.168.1.2).

It works fine. I copied some files on db1 into the directory /database
(where /dev/nb0 is mounted on) and they appeared on db2 also.

Now i want combine heartbeat with drbd and i have some questions.

I would say there exists four states:
1. db1 up (primary)     db2 up (secondary) - should be normal ;-)
2. db1 up (primary)     db2 down (unknown) - :-(
3. db1 down (unknown)   db2 up (primary)   - :-(
4. db1 down (unknown)   db2 down (unknown) - :-(((

Which actions i have to perform for the transitions? I got puzzled,
because heartbeat offers only the possibility to start and stop.

For example a normal start up for db2 is
drbdadm up resource
drbdadm secondary resource,
but if db1 (the primary) fails then on db2 you have to issue:
drbdadm down resource
drbdadm up resource
drbdadm primary resource
mount /dev/nb0 /database
haven't you?

And what happens, if db1 comes up again? I really want db1 as primary.
Should i wait for resync and make db1 then primary? Or should i
switch db1 directly to primary and db2 to secondary?

I am puzzled. It would be great when somebody could help.

With best regards

tom

-- 
NEU : GMX Internet.FreeDSL
Ab sofort DSL-Tarif ohne Grundgebühr: http://www.gmx.net/dsl




More information about the drbd-user mailing list