From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: From: Philipp Reisner To: drbd-dev@lists.linbit.com Subject: Re: [Drbd-dev] DRBD8: An attach after a disk fault on the sync target causes a deadlock in WFBitMapT Date: Tue, 10 Jul 2007 15:48:16 +0200 References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200707101548.16674.philipp.reisner@linbit.com> Cc: "Montrose, Ernest" List-Id: Coordination of development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On Monday 09 July 2007 17:25:08 Montrose, Ernest wrote: > Hi all, > We are seeing a problem where while syncing if the sync target detaches > then attempts to attach, both nodes end up in cs:WABitMapT state. This > happens if both nodes where in Secondary/Secondary state and the dettach > happened on the SyncTarget. > Hi Ernest, Thanks for pointing this out. The cause for this was that the UUIDs... Node1: C:0:H:H Node2: C:0:H:H upon start of resync an "S" gets created. sync target: S:0:C:H sync source: C:S:H:H but it should be sync target: S:0:H:H sync source: C:S:H:H On the sync target side we got S left of C while on the sync source side we had C left of S. This was bad. The should not appear in different order! C should be left of S on sync source, and nowhere on the sync target. (= even further left = in the future ) Ok, I guess the explanation is sufficient incomprehensible ;) Index: drbd_receiver.c =================================================================== --- drbd_receiver.c (revision 2965) +++ drbd_receiver.c (revision 2966) @@ -2474,7 +2474,9 @@ if (drbd_recv(mdev, h->payload, h->length) != h->length) return FALSE; - drbd_uuid_set(mdev,Current,be64_to_cpu(p->uuid)); + /* Here the _drbd_uuid_ functions are right, current should + _not_ be rotated into the history */ + _drbd_uuid_set(mdev,Current,be64_to_cpu(p->uuid)); _drbd_uuid_set(mdev,Bitmap,0UL); drbd_start_resync(mdev,SyncTarget); -Phil -- : Dipl-Ing Philipp Reisner Tel +43-1-8178292-50 : : LINBIT Information Technologies GmbH Fax +43-1-8178292-82 : : Vivenotgasse 48, 1120 Vienna, Austria http://www.linbit.com :