xfs
[Top] [All Lists]

Re: [patch] xfsprogs: repair never return if device removed

To: xfs@xxxxxxxxxxx
Subject: Re: [patch] xfsprogs: repair never return if device removed
From: Ajeet Yadav <ajeet.yadav.77@xxxxxxxxx>
Date: Mon, 31 Jan 2011 11:41:16 +0900
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=dtaIw4u82mHjjTAa8cr4ETIrP3dnmSDlwIzdQXh79Gk=; b=oW3JxtQD6V1w/V2v8BU98CSbIqNlD9cGw8P2+LPy8Fnp7x3+vZPZT2kvkkhowOBFT6 b+XgwCT7o9Evli2bWtUTUxP727w+flV75QLPh3WdfKPcsGuNEt3sYpk8ojPW2qDP9S4i BLVqMV6Z4VZpQg9PpBC6RQTyKdespsJIGY69I=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=gEiuv3oq6dUSEYU+KDLltdDNocDy3poU0YI2zmo3V+KQYuvOmBCjr/DEWf6JO+bjOB mb9KMSctdbZ+n+pOLaqTkuJRzZj2eaZByugJuZsbYQDkmKG9L6X0Kx+rm8Q5qzKC5mip S/mVFiyjE0q7uHX4fzlv+d6xDXb2qtibQb04w=
In-reply-to: <AANLkTimoZE8kD2Qz+ynZhceGuHqZxe9VSHKXho_tbdWi@xxxxxxxxxxxxxx>
References: <AANLkTimoZE8kD2Qz+ynZhceGuHqZxe9VSHKXho_tbdWi@xxxxxxxxxxxxxx>
I did not receive and response / reviews on patch.

diff -Nurp xfsprogs/repair/sb.c xfsprogs-dirty/repair/sb.c

--- xfsprogs/repair/sb.c 2011-01-28 20:23:02.000000000 +0900

+++ xfsprogs-dirty/repair/sb.c 2011-01-28 20:21:06.000000000 +0900

@@ -122,8 +122,9 @@ find_secondary_sb(xfs_sb_t *rsb)

done = 1;

}

- if (!done && (bsize = read(x.dfd, sb, BSIZE)) == 0) {

+ if (!done && (bsize = read(x.dfd, sb, BSIZE)) <= 0) {

done = 1;

+ do_warn(_("Couldn't find candidate secondary superblock, exiting...\n"));

}

do_warn(".");


On Fri, Jan 28, 2011 at 8:31 PM, Ajeet Yadav <ajeet.yadav.77@xxxxxxxxx> wrote:
xfsprogs all version, delete primary superblock of xfs partition
 
dd if=/dev/zero of=/dev/sda1 bs=512 count=1
sync
 
Run xfs_repair in partition, while its searching for secondary superblock, remove the disk (USB) xfs_repair will never exit and will loop in never ending ............
 
Please find patch attached with mail

<Prev in Thread] Current Thread [Next in Thread>