From: Ted Ts'o Subject: Re: [PATCH] e2fsck: fix "can't find dup_blk" error Date: Mon, 28 Nov 2011 12:02:25 -0500 Message-ID: <20111128170225.GA4348@thunk.org> References: <1321584758-4259-1-git-send-email-hao.bigrat@gmail.com> <20111119040215.GE4130@thunk.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="h31gzZEtNLTqOjlF" Cc: linux-ext4@vger.kernel.org To: Robin Dong Return-path: Received: from li9-11.members.linode.com ([67.18.176.11]:34393 "EHLO test.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751904Ab1K1RCa (ORCPT ); Mon, 28 Nov 2011 12:02:30 -0500 Content-Disposition: inline In-Reply-To: Sender: linux-ext4-owner@vger.kernel.org List-ID: --h31gzZEtNLTqOjlF Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Ok, I was able to replicate it, and created a small test case (see attached), but it turns out your patch wasn't sufficient. It didn't actually fix the problem correctly, and left the file system in a corrupted state, which was seen when we ran e2fsck a second time and the i_blocks field was not correctly. Your patch also resulted in blocks within a logical cluster incorrectly assigned to two physical clusters. (I still need to add some code in e2fsck to notice this particular corruption, but it's highly unlikely for this to happen due to hardware errors --- just kernel/e2fsck bugs.) I'll attach to this mail thread the patches I used to fix this, plus the test case. - Ted --h31gzZEtNLTqOjlF Content-Type: application/octet-stream Content-Disposition: attachment; filename="image.gz" Content-Transfer-Encoding: base64 H4sIAIYF004CA+3YzWtUVxgH4HNPok0zUzOxda1YrR+BqVFbP1bxH4hi14JgEAVRoVWXTaF/ QHFhoasusunOZVfqTtyZjWs3LkTFhREKFcZ3Zu4VkaBH/ILxeeC978m9c+c390w43DspAZ+r uf5mPKU90TpjKc3U+3PU2sFoIqXF4ev+v7Y837q+PF+lXu+nx1WqYt/T2Ne8V1X3VhqckrZH HY03qqKmj03/Of3f4f1Lt75cc+/KP5de/RzfX1w48aGv9c7DpZX2w7l/f195dvPg7sOX+5+3 XR97+Trep2qVfTHd6bR/PQAAPoH+ff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