lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <51707E06.2050105@gmail.com>
Date:	Fri, 19 Apr 2013 07:13:10 +0800
From:	Zheng Liu <gnehzuil.liu@...il.com>
To:	Theodore Ts'o <tytso@....edu>
CC:	Ext4 Developers List <linux-ext4@...r.kernel.org>,
	"Darrick J. Wong" <darrick.wong@...cle.com>
Subject: Re: [PATCH] ext4: disable defrag for metadata_csum file systems

[Sorry, it seems that I got a delivery error.  So send again]

On 04/19/2013 05:58 AM, Theodore Ts'o wrote:
> It looks like there is absolutely no support for metadata checksums in
> fs/ext4/move_extent.c.  So if you try to defrag a file on a
> metadata_csum, it leaves the file system corrupted.
> 
> We really, really should get this fixed ASAP, but until we do, let's
> disable e4defrag on metadata_csum file systems so we avoid corrupting
> file systems.
> 
> Cc: "Darrick J. Wong" <darrick.wong@...cle.com>
> Signed-off-by: "Theodore Ts'o" <tytso@....edu>

Yes, I also notice this problem.  So currently it seems that the best
choice is to disable defrag for metadata_csum.

Reviewed-By: Zheng Liu <wenqing.lz@...bao.com>

Thanks,
						- Zheng

> ---
>  fs/ext4/ioctl.c | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/fs/ext4/ioctl.c b/fs/ext4/ioctl.c
> index 9491ac0..2d043da 100644
> --- a/fs/ext4/ioctl.c
> +++ b/fs/ext4/ioctl.c
> @@ -450,6 +450,15 @@ group_extend_out:
>  			goto mext_out;
>  		}
>  
> +		if (EXT4_HAS_RO_COMPAT_FEATURE(inode->i_sb,
> +			EXT4_FEATURE_RO_COMPAT_METADATA_CSUM)) {
> +			ext4_msg(sb, KERN_ERR,
> +				 "Online defrag not supported with "
> +				 "metadata_csum");
> +			err = -EOPNOTSUPP;
> +			goto mext_out;
> +		}
> +
>  		err = mnt_want_write_file(filp);
>  		if (err)
>  			goto mext_out;
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ