btrfs crash with 3.1.5

2011-12-20 Thread Jeremy Sanders
Hi - this crash occured with Fedora 16 kernel 3.1.5-6.fc16.x86_64. The message below appeared and the machine locked up with the hard drive on and the keyboard lights blinking. Btrfs was running with compress-force=zlib on a software raid md linear array (~5GB), around 50% full. [

COW a file from snapshot

2011-12-20 Thread Dave
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 So I've got a daily snapshot of my /home subvolume. Due to a fat finger, I've damaged a rather large file so I'd like to pull if from one of these snapshot backups. I don't want to simply copy the file since it's many gigs and cp -

Re: [PATCH] btrfs: add new ioctl to determine size of compressed file

2011-12-20 Thread David Sterba
On Tue, Dec 20, 2011 at 09:33:06AM +0800, Liu Bo wrote: +static long btrfs_ioctl_compr_size(struct file *file, void __user *argp) +{ + struct inode *inode = fdentry(file)-d_inode; + struct btrfs_ioctl_compr_size_args compr_args; + u64 len; + u64 compressed_size = 0; + u64

[PATCH V2] btrfs: add new ioctl to determine size of compressed file

2011-12-20 Thread David Sterba
Go through all extents of a file in a given [start,end) range and sum for: * regular extent: -block_len, size is already rounded up to blocks * inline extents: length rounded up to 512 The range is start inclusive / end exclusive. For whole a file pass 0 and (u64)-1. The values returned are

[PATCH V2] btrfs-progs: Add ioctl to read compressed size of a file

2011-12-20 Thread David Sterba
Signed-off-by: David Sterba dste...@suse.cz --- V1-V2: * match current kernel side and print uncompressed length as well * now it's easy to print the compression ratio for the given range btrfs.c |9 ++- btrfs_cmds.c | 68 ++

Re: COW a file from snapshot

2011-12-20 Thread Jérôme Poulin
You would need to apply this patch to your kernel: http://www.mail-archive.com/linux-btrfs@vger.kernel.org/msg09096.html Is there any chance this patch gets in linux-next ? I use this feature all the time and it never broke on me. On Tue, Dec 20, 2011 at 10:07 AM, Dave d...@thekilempire.com

Re: speeding up slow btrfs filesystem

2011-12-20 Thread Goffredo Baroncelli
Ciao Andrea, On Sunday, 18 December, 2011 19:41:49 you wrote: 2011/12/16 Goffredo Baroncelli kreij...@inwind.it: I found a solution, but requires a bit of setup. Did you try: echo force-unsafe-io /etc/dpkg/dpkg.cfg stracing an apt-get update, it seems that --force-unsafe-io doesn't stop

Re: [PATCH V2] btrfs-progs: Add ioctl to read compressed size of a file

2011-12-20 Thread Goffredo Baroncelli
Hi David On Tuesday, 20 December, 2011 18:49:58 David Sterba wrote: Signed-off-by: David Sterba dste...@suse.cz --- V1-V2: * match current kernel side and print uncompressed length as well * now it's easy to print the compression ratio for the given range btrfs.c |9 ++-

Re: 3.2-rc4: scrubbing locks up the kernel, then hung tasks on boot

2011-12-20 Thread Martin Steigerwald
Hi again! Any hints about this one? Since scrubbing worked okay on other machines, I can also redo the BTRFS filesystem on this machine. Maybe it really has gained a corruption. (Still scrubbing should not lock up the kernel hard, but…) Thanks, Martin Am Samstag, 17. Dezember 2011 schrieb

bad tree block problems

2011-12-20 Thread Chris Baines
Hello, I am having problems with my btrfs filesystem, I have a 1TB RAID-1 setup that I use as /home. When accessing certain programs, or moving large amounts of data, I often get errors looking like the one attached, after I get the error, /home becomes unusable and I reboot. I have tried running

Re: bad tree block problems

2011-12-20 Thread Chris Mason
On Tue, Dec 20, 2011 at 10:34:20PM +, Chris Baines wrote: Hello, I am having problems with my btrfs filesystem, I have a 1TB RAID-1 setup that I use as /home. When accessing certain programs, or moving large amounts of data, I often get errors looking like the one attached, after I get

Re: bad tree block problems

2011-12-20 Thread Chris Baines
On 20 December 2011 23:36, Chris Mason chris.ma...@oracle.com wrote: On Tue, Dec 20, 2011 at 10:34:20PM +, Chris Baines wrote: Hello, I am having problems with my btrfs filesystem, I have a 1TB RAID-1 setup that I use as /home. When accessing certain programs, or moving large amounts of

Re: bad tree block problems

2011-12-20 Thread Liu Bo
On 12/21/2011 07:39 AM, Chris Baines wrote: On 20 December 2011 23:36, Chris Mason chris.ma...@oracle.com wrote: On Tue, Dec 20, 2011 at 10:34:20PM +, Chris Baines wrote: Hello, I am having problems with my btrfs filesystem, I have a 1TB RAID-1 setup that I use as /home. When accessing

Re: bad tree block problems

2011-12-20 Thread Chris Baines
I have built the btrfs-progs from git, and get this output when running the command: ioctl ret=-1, error: No such file or directory Thanks, Chris -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH] fs: push file_update_time into -page_mkwrite

2011-12-20 Thread Dave Chinner
On Tue, Nov 29, 2011 at 04:50:20PM +0100, Jan Kara wrote: On Tue 29-11-11 10:40:59, Josef Bacik wrote: The fault code has been calling file_update_time after -page_mkwrite after it drops the page lock, but this is annoying because this calls mark_inode_dirty which can fail in Btrfs,