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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Thu, 9 Aug 2012 09:07:54 -0400
From:	Theodore Ts'o <tytso@....edu>
To:	Ext4 Developers List <linux-ext4@...r.kernel.org>
Subject: Re: [PATCH RFC] ext4: collapse a single extent tree block into the
 inode if possible

Here's a test script which demonstrates how we can up with an external
extent tree block containing a single extent.  It needs to run as root
since it will be mounting a test file system image on /mnt.


#!/bin/bash
fs=/u1/test-fs.img
num=128
max=$(expr $num \* 8)
size=$(expr $num \* 32)k

dd if=/dev/zero of=$fs bs=4k count=$(expr $max \* 4)

mke2fs -t ext4 -b 4096 -qF $fs
mount -t ext4 $fs /mnt

cd /mnt
fallocate -l $size test-file
for i in $(seq 0 8 $max | sed -e '$d') ; do
	dd if=/dev/zero of=test-file conv=notrunc,nocreat bs=4k \
	   seek=$i count=1 > /dev/null 2>&1
done
sync

dd if=/dev/zero of=test-file conv=notrunc,nocreat \
	bs=4k count=$max > /dev/null 2>&1
sync
cd /

umount /mnt
debugfs $fs -R "stat test-file"

--
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