btrfs scrub status misreports as interrupted

2014-11-22 Thread Marc Joliet
Hi all, While I haven't gotten any scrub already running type errors any more, I do get one strange case of state misreport. When running scrub on /home (btrfs RAID10), after 3 of 4 drives have completed, the 4th drive (sdb) will report as interrupted, despite still running: # btrfs scrub

[PATCH v2] Btrfs: fix allocationg memory failure for btrfsic_state structure

2014-11-22 Thread Wang Shilong
size of @btrfsic_state needs more than 2M, it is very likely to fail allocating memory using kzalloc(). see following mesage: [91428.902148] Call Trace: [816f6e0f] dump_stack+0x4d/0x66 [811b1c7f] warn_alloc_failed+0xff/0x170 [811b66e1] __alloc_pages_nodemask+0x951/0xc30

[PATCH] Btrfs: switch to kvfree() helper

2014-11-22 Thread Wang Shilong
A new helper kvfree() in mm/utils.c will do this. Signed-off-by: Wang Shilong wangshilong1...@gmail.com --- fs/btrfs/raid56.c | 13 +++-- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/fs/btrfs/raid56.c b/fs/btrfs/raid56.c index 6a41631..12e343b 100644 ---

open_ctree problem

2014-11-22 Thread Russell Coker
I have a workstation running Linux 3.14.something on a 120G SSD. It recently had a problem and now the root filesystem can't be mounted, here is the message I get when trying to mount it read-only on Debian kernel 3.16.2-3: [4703937.784447] BTRFS info (device loop0): disk space caching is

[PATCH-v2 1/5] fs: split update_time() into update_time() and write_time()

2014-11-22 Thread Theodore Ts'o
In preparation for adding support for the lazytime mount option, we need to be able to separate out the update_time() and write_time() inode operations. Currently, only btrfs and xfs uses update_time(). We needed to preserve update_time() because btrfs wants to have a special

[PATCH-v2 3/5] vfs: don't let the dirty time inodes get more than a day stale

2014-11-22 Thread Theodore Ts'o
Guarantee that the on-disk timestamps will be no more than 24 hours stale. Signed-off-by: Theodore Ts'o ty...@mit.edu --- fs/fs-writeback.c | 1 + fs/inode.c | 16 +++- include/linux/fs.h | 1 + 3 files changed, 17 insertions(+), 1 deletion(-) diff --git

[PATCH-v2 4/5] vfs: add lazytime tracepoints for better debugging

2014-11-22 Thread Theodore Ts'o
Signed-off-by: Theodore Ts'o ty...@mit.edu --- fs/fs-writeback.c | 5 - fs/inode.c| 5 + include/trace/events/fs.h | 56 +++ 3 files changed, 65 insertions(+), 1 deletion(-) create mode 100644 include/trace/events/fs.h

[PATCH-v2 5/5] ext4: add support for a lazytime mount option

2014-11-22 Thread Theodore Ts'o
Add an optimization for the MS_LAZYTIME mount option so that we will opportunistically write out any inodes with the I_DIRTY_TIME flag set in a particular inode table block when we need to update some inode in that inode table block anyway. Also add some temporary code so that we can set the

[PATCH-v2 2/5] vfs: add support for a lazytime mount option

2014-11-22 Thread Theodore Ts'o
Add a new mount option which enables a new lazytime mode. This mode causes atime, mtime, and ctime updates to only be made to the in-memory version of the inode. The on-disk times will only get updated when (a) if the inode needs to be updated for some non-time related change, (b) if userspace

[PATCH-v2 0/5] add support for a lazytime mount option

2014-11-22 Thread Theodore Ts'o
This is an updated version of what had originally been an ext4-specific patch which significantly improves performance by lazily writing timestamp updates (and in particular, mtime updates) to disk. The in-memory timestamps are always correct, but they are only written to disk when required for

Re: BTRFS messes up snapshot LV with origin

2014-11-22 Thread Goffredo Baroncelli
On 11/21/2014 05:28 AM, Zygo Blaxell wrote: e.g. if an ext4 filesystem explodes, I can: 1. make a LVM snapshot of the broken filesystem 2. run e2fsck on the snapshot 3. mount and repair the snapshot, e.g. rsync any missing files from backups, salvage anything

Volume/subvolume UUID uniqueness, was: BTRFS messes up snapshot LV with origin

2014-11-22 Thread Chris Murphy
I don't know how to fix this but I've convinced myself there's at least a small problem. And not just with LVM snapshots as in the originating thread. - Via seed device method of creating a Btrfs volume, the resulting volume gets a new UUID. The volume UUID from the seed device doesn't pass

Re: [PATCH v2 5/5] btrfs: enable swap file support

2014-11-22 Thread Omar Sandoval
On Fri, Nov 21, 2014 at 07:00:45PM +0100, David Sterba wrote: + pr_err(BTRFS: swapfile has holes); + ret = -EINVAL; + goto out; + } + if (em-block_start == EXTENT_MAP_INLINE) { + pr_err(BTRFS:

Re: scrub implies failing drive - smartctl blissfully unaware

2014-11-22 Thread Phillip Susi
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 On 11/21/2014 04:12 PM, Robert White wrote: Here's a bug from 2005 of someone having a problem with the ACPI IDE support... That is not ACPI emulation. ACPI is not used to access the disk, but rather it has hooks that give it a chance to diddle

Re: Fixing Btrfs Filesystem Full Problems typo?

2014-11-22 Thread Marc MERLIN
+btrfs list so that someone can correct me if I'm wrong. On Sat, Nov 22, 2014 at 09:34:59PM +0100, Patrik Lundquist wrote: Hi, I was scratching my head over a failing btrfs balance and read your very informative

Re: Volume/subvolume UUID uniqueness, was: BTRFS messes up snapshot LV with origin

2014-11-22 Thread Robert White
On 11/22/2014 02:50 PM, Robert White wrote: Take a couple snapshots of a subvolume, and then send those subvolumes to another file system with send/receive, and then do btrfs subvolume list -u -q on the two filesystems and tell me that mess makes sense. Or try to recreate a subvolume from its

Re: Fixing Btrfs Filesystem Full Problems typo?

2014-11-22 Thread Patrik Lundquist
On 22 November 2014 at 23:26, Marc MERLIN m...@merlins.org wrote: This one hurts my brain every time I think about it :) I'm new to Btrfs so I may very well be wrong, since I haven't really read up on it. :-) So, the bigger the -dusage number, the more work btrfs has to do. Agreed.

Re: Fixing Btrfs Filesystem Full Problems typo?

2014-11-22 Thread Marc MERLIN
On Sun, Nov 23, 2014 at 12:26:38AM +0100, Patrik Lundquist wrote: I realize that I interpret the usage parameter as operating on blocks (chunks? are they the same in this case?) that are = 55% full while you interpret it as = 55% free. Which is correct? I will let someone else answer

Re: Fixing Btrfs Filesystem Full Problems typo?

2014-11-22 Thread Hugo Mills
On Sun, Nov 23, 2014 at 12:26:38AM +0100, Patrik Lundquist wrote: On 22 November 2014 at 23:26, Marc MERLIN m...@merlins.org wrote: This one hurts my brain every time I think about it :) I'm new to Btrfs so I may very well be wrong, since I haven't really read up on it. :-) So, the

Best GIT repository(s) for preparing patches?

2014-11-22 Thread Robert White
Which is the best GIT repository to clone for each of the kernel support and btrfs-progs, for preparing a patch to submit to this email list? -- 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: BTRFS messes up snapshot LV with origin

2014-11-22 Thread Zygo Blaxell
On Sat, Nov 22, 2014 at 06:34:38PM +0100, Goffredo Baroncelli wrote: On 11/21/2014 05:28 AM, Zygo Blaxell wrote: e.g. if an ext4 filesystem explodes, I can: 1. make a LVM snapshot of the broken filesystem 2. run e2fsck on the snapshot 3. mount and repair the

Re: Fixing Btrfs Filesystem Full Problems typo?

2014-11-22 Thread Marc MERLIN
On Sun, Nov 23, 2014 at 12:05:04AM +, Hugo Mills wrote: Which is correct? Less than or equal to 55% full. This confuses me. Does that mean that the fullest blocks do not get rebalanced? I guess I was under the mistaken impression that the more data you had the more you could be out

Re: open_ctree problem

2014-11-22 Thread Russell Coker
Strangely I repeated the same process on the same system (btrfs-zero-log and mount read-only) and it worked. While it's a concern that repeating the same process gives different results it's nice that I'm getting all my data back. On Sun, 23 Nov 2014, Russell Coker russ...@coker.com.au wrote:

Re: Fixing Btrfs Filesystem Full Problems typo?

2014-11-22 Thread Duncan
Marc MERLIN posted on Sat, 22 Nov 2014 17:07:42 -0800 as excerpted: On Sun, Nov 23, 2014 at 12:05:04AM +, Hugo Mills wrote: Which is correct? Less than or equal to 55% full. This confuses me. Does that mean that the fullest blocks do not get rebalanced? Yes. =:^) I guess I