From: Eric Sandeen Subject: Re: How can I flush all writes before yanking the power cable? Date: Thu, 07 Feb 2013 15:29:47 -0600 Message-ID: <51141CCB.9060908@redhat.com> References: <5113EE8F.2080104@redhat.com> <20130207205803.GB28084@thunk.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: "Theodore Ts'o" , linux-ext4@vger.kernel.org To: Autif Khan Return-path: Received: from mx1.redhat.com ([209.132.183.28]:54888 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1030275Ab3BGV3w (ORCPT ); Thu, 7 Feb 2013 16:29:52 -0500 In-Reply-To: Sender: linux-ext4-owner@vger.kernel.org List-ID: On 2/7/13 3:28 PM, Autif Khan wrote: > On Thu, Feb 7, 2013 at 3:58 PM, Theodore Ts'o wrote: >> On Thu, Feb 07, 2013 at 02:37:02PM -0500, Autif Khan wrote: >>> >>> That was precisely my ignorance. I did not know about barrier. Adding >>> it during mount ro and remount rw seems to have fixed these issues. >> >> You also didn't say what file system you were using. Was it ext4? >> ext3? ext2? What kernel version? On modern kernels barrier is >> enabled by default for both ext3 and ext4. > > The filesystem is ext4. Kernel version is 3.2.0 > > I could not grep -i barrier in the kernel config. How is barrier > enabled or disabled in the kernel by default? in ext4_fill_super(): if ((def_mount_opts & EXT4_DEFM_NOBARRIER) == 0) set_opt(sb, BARRIER); It's a mount option, not a kernel config option. -Eric