Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.
On 2004-09-15T10:39:55, Shallyee Shang <shallyee.shang at jp.sony.com> said: > I am trying write a script under drbd-0.7.x, which can probe if a drbd > device can transfer to primary state when it receive a "drbdadm primary ..." > command. Device monitor will call this script to determine if a device > is avaliable. > > "drbdadm state" command tells device's status, which may help me > make the decision. I can get a state list by greping drbd source code, > I guess these are all that "state" command can tell, but I don't understand > which state can transfer to primary state. > > Can anyone teach me about this, or advise me a good way to write a > monitor script? Any drbd which is not "Inconsistent" can become master; even a SyncTarget can become master as long as it is connected to the SyncSource. The full logic which side of the two you might want to promote to primary is somewhat more complex, in particular if they are internally split... With what cluster manager are you trying to integrate drbd? Sincerely, Lars Marowsky-Brée <lmb at suse.de> -- High Availability & Clustering SUSE Labs, Research and Development SUSE LINUX AG - A Novell company