Re: How does "btrfs fi show" show full?

2014-05-05 Thread Brendan Hide
On 05/05/14 07:50, Marc MERLIN wrote: On Mon, May 05, 2014 at 06:11:28AM +0200, Brendan Hide wrote: The "per-device" used amount refers to the amount of space that has been allocated to chunks. That first one probably needs a balance. Btrfs doesn't behave very well when available diskspace is so

Please review and comment, dealing with btrfs full issues

2014-05-05 Thread Marc MERLIN
I've just written this new page: http://marc.merlins.org/perso/btrfs/post_2014-05-04_Fixing-Btrfs-Filesystem-Full-Problems.html First, are there problems in it? Second, are there other FS full issues I should mention in it? Thanks, Marc -- "A mouse is a device used to point at the xterm you wan

Re: Using mount -o bind vs mount -o subvol=vol

2014-05-05 Thread Chris Mason
On 05/03/2014 08:47 PM, Marc MERLIN wrote: Is there any functional difference between mount -o subvol=usr /dev/sda1 /usr and mount /dev/sda1 /mnt/btrfs_pool mount -o bind /mnt/btrfs_pool/usr /usr The internal implementation of mount -o subvol is a bind mount. The only real difference is havi

Back from leave

2014-05-05 Thread Josef Bacik
Hello, I had way too much email so I just deleted it all, if there was something you wanted my specific attention on then bounce it back at me and I'll look at it. Thanks, Josef -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majord...@vg

Re: Back from leave

2014-05-05 Thread Shilong Wang
2014-05-05 22:28 GMT+08:00 Josef Bacik : > Hello, > > I had way too much email so I just deleted it all, if there was something > you wanted my specific attention on then bounce it back at me and I'll look > at it. Thanks, Welcome back, Josef! Wang > > Josef > -- > To unsubscribe from this list:

[PATCH] btrfs-progs: doc: fix symlink target for btrfsck.8

2014-05-05 Thread David Sterba
The manpage of btrfsck.8 is supposed to link to btrfs-check.8 . Reported-by: WorMzy Tykashi Signed-off-by: David Sterba --- Documentation/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/Makefile b/Documentation/Makefile index e22f5bca0ff2..e3ad34133832

Re: [PATCH] btrfs-progs: doc: link btrfsck to btrfs-check

2014-05-05 Thread David Sterba
On Wed, Apr 30, 2014 at 01:14:59PM +0100, WorMzy Tykashi wrote: > $(LNS) btrfs-check.8.gz $(DESTDIR)$(man8dir) > > should be > > $(LNS) btrfs-check.8.gz $(DESTDIR)$(man8dir)/btrfsck.8.gz Thank you, fix sent. -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the

RE: Unable to boot

2014-05-05 Thread George Pochiscan
Hello Chris, Thanks for your response. I tried the steps you gave me, but still no luck. Each time i try to mount ( normally, -o recovery, -o ro,recovery) i have the following error: [root@localhost liveuser]# mount /dev/md127 /tmp/hdd mount: wrong fs type, bad option, bad superblock on /dev/md

Re: Unable to boot

2014-05-05 Thread Hugo Mills
On Mon, May 05, 2014 at 03:04:05PM +, George Pochiscan wrote: > Hello Chris, > > Thanks for your response. I tried the steps you gave me, but still no luck. > > Each time i try to mount ( normally, -o recovery, -o ro,recovery) i have the > following error: > > [root@localhost liveuser]# mou

RE: Unable to boot

2014-05-05 Thread George Pochiscan
Hello Hugo, Running btrfs-zero-log /dev/md127 i have the following error: checksum verify failed on 1001492480 found 74CC3F5D wanted C222A2C9 Csum didn't match btrfs-zero-log: extent-tree.c:2717: alloc_reserved_tree_block: Assertion `!(ret)' failed. Aborted (core dumped) Full output : http://pa

Re: metadata vs data errors

2014-05-05 Thread David Sterba
On Sun, May 04, 2014 at 11:19:15AM +1000, Russell Coker wrote: > To discover whether there were any metadata errors I grepped for "metadata" > in > the kernel message log and found lots of lines like the above. Will all > errors that involve metadata match a grep for "metadata" in the kernel >

Re: Very high load when reading/writing

2014-05-05 Thread David Sterba
On Thu, May 01, 2014 at 07:50:11PM +0200, Hendrik Friedel wrote: > I have very high load when writing/reading from/to two of my btrfs volumes. > One sda1, mounted as /mnt/BTRFS, the other, sdd2/sde2 (raid) as / > sda1 is a 3TB disc, whereas the sdd2/sde2 are small SSDs of 16GB. > > I wrote a small

Re: Please review and comment, dealing with btrfs full issues

2014-05-05 Thread Brendan Hide
On 05/05/14 14:16, Marc MERLIN wrote: I've just written this new page: http://marc.merlins.org/perso/btrfs/post_2014-05-04_Fixing-Btrfs-Filesystem-Full-Problems.html First, are there problems in it? Second, are there other FS full issues I should mention in it? Thanks, Marc "In the case above,

Re: Please review and comment, dealing with btrfs full issues

2014-05-05 Thread Brendan Hide
On 05/05/14 19:07, Brendan Hide wrote: On 05/05/14 14:16, Marc MERLIN wrote: I've just written this new page: http://marc.merlins.org/perso/btrfs/post_2014-05-04_Fixing-Btrfs-Filesystem-Full-Problems.html First, are there problems in it? Second, are there other FS full issues I should menti

[PATCH 1/3] btrfs check: Fix wrong level access

2014-05-05 Thread Hugo Mills
There's no reason to assume that the bad key order is in a leaf block, so accessing level 0 of the path is going to be an error if it's actually a node block that's bad. Reported-by: Chris Mason Signed-off-by: Hugo Mills --- cmds-check.c | 10 ++ 1 file changed, 6 insertions(+), 4 delet

[PATCH 2/3] btrfs check: Pre-sort keys in a block while searching

2014-05-05 Thread Hugo Mills
When we think we might have a messed-up block with keys out of order (e.g. during fsck), we still need to be able to find a key in the block. To deal with this, we copy the keys, keeping track of where they came from in the original node/leaf, sort them, and then do the binary search. Signed-off-b

[PATCH 3/3] btrfs check: Attempt to fix misordered keys with bitflips in them

2014-05-05 Thread Hugo Mills
If someone has had bad RAM which has been used to store a metadata block, there's a chance that one or more of the keys has had a bit changed. The block checksum doesn't help us here, because it's made on the bad data. To fix this, if there's a block with a bad key order in it, we find out-of- ord

[[PATCH] 0/3] btrfs-check: Fix bitflipped keys from bad RAM

2014-05-05 Thread Hugo Mills
If you have RAM with stuck or unreliable bits in it, and a metadata block is stored in it, you can end up with keys with errors in. These usually show up as "bad key order". In many cases, these out-of-order keys can be identified and fixed with a simple heuristic. This patch series implements that

Re: Please review and comment, dealing with btrfs full issues

2014-05-05 Thread Calvin Walton
On Mon, 2014-05-05 at 19:07 +0200, Brendan Hide wrote: > On 05/05/14 14:16, Marc MERLIN wrote: > > I've just written this new page: > > http://marc.merlins.org/perso/btrfs/post_2014-05-04_Fixing-Btrfs-Filesystem-Full-Problems.html > > > > First, are there problems in it? > > > > Second, are there o

btrfs on software RAID0

2014-05-05 Thread john terragon
Hi. I'm about to try btrfs on an RAID0 md device (to be precise there will be dm-crypt in between the md device and btrfs). If I used ext4 I would set the stride and stripe_width extended options. Is there anything similar I should be doing with mkfs.btrfs? Or maybe some mount options beneficial to

Thoughts on RAID nomenclature

2014-05-05 Thread Hugo Mills
A passing remark I made on this list a day or two ago set me to thinking. You may all want to hide behind your desks or in a similar safe place away from the danger zone (say, Vladivostok) at this point... If we switch to the NcMsPp notation for replication, that comfortably describes most o

Re: btrfs on software RAID0

2014-05-05 Thread Marc MERLIN
On Mon, May 05, 2014 at 10:51:46PM +0200, john terragon wrote: > Hi. > I'm about to try btrfs on an RAID0 md device (to be precise there will > be dm-crypt in between the md device and btrfs). If I used ext4 I > would set the stride and stripe_width extended options. Is there > anything similar I s

Re: Thoughts on RAID nomenclature

2014-05-05 Thread Marc MERLIN
On Mon, May 05, 2014 at 10:17:38PM +0100, Hugo Mills wrote: >Given these four (spread, dup, linear, grouped), I think it's > fairly obvious that spread is a special case of grouped, where each > device is its own group. Then dup is the opposite of grouped (i.e. you > must have one or the other

Re: btrfs on software RAID0

2014-05-05 Thread ronnie sahlberg
start-btrfs-dmcrypt : ... echo "$pwd" | ... Hmmm. This makes the plaintext password visible in ps output. It is probably better to pass this in by redirecting a file to stdin. On Mon, May 5, 2014 at 2:25 PM, Marc MERLIN wrote: > On Mon, May 05, 2014 at 10:51:46PM +0200, john terragon wrote: >>

Re: Thoughts on RAID nomenclature

2014-05-05 Thread Brendan Hide
On 2014/05/05 11:17 PM, Hugo Mills wrote: A passing remark I made on this list a day or two ago set me to thinking. You may all want to hide behind your desks or in a similar safe place away from the danger zone (say, Vladivostok) at this point... I feel like I can brave some "mild horrors"

Re: Unable to boot

2014-05-05 Thread Chris Murphy
On May 5, 2014, at 9:11 AM, George Pochiscan wrote: > Hello Hugo, > > Running btrfs-zero-log /dev/md127 i have the following error: > > checksum verify failed on 1001492480 found 74CC3F5D wanted C222A2C9 > Csum didn't match > btrfs-zero-log: extent-tree.c:2717: alloc_reserved_tree_block: Asser

Re: btrfs on software RAID0

2014-05-05 Thread Marc MERLIN
On Mon, May 05, 2014 at 02:42:53PM -0700, ronnie sahlberg wrote: > start-btrfs-dmcrypt : > ... > echo "$pwd" | > ... > > Hmmm. This makes the plaintext password visible in ps output. > It is probably better to pass this in by redirecting a file to stdin. echo is built in, it will not show up in p

Re: btrfs on software RAID0

2014-05-05 Thread john terragon
On Mon, May 5, 2014 at 11:25 PM, Marc MERLIN wrote: > This is not directly an answer to your question, so far I haven't used a > special option like this with btrfs on my arrays although my > undertstanding is that it's not as important as with ext4. > > That said, please read > http://marc.merlin

Re: Very high load when reading/writing

2014-05-05 Thread Chris Murphy
On May 1, 2014, at 11:50 AM, Hendrik Friedel wrote: > > Here the output: > Test from /mnt/BTRFS to /tmp I'm not sure what this is testing, what the file size is or how many files. These days it's increasingly common to see tmpfs mount on /tmp rather than persistent storage; and then at some

Re: Please review and comment, dealing with btrfs full issues

2014-05-05 Thread Russell Coker
On Mon, 5 May 2014 14:36:09 Calvin Walton wrote: > The standard response on the mailing list for this issue is to > temporarily add an additional device to the filesystem (even e.g. a 4GB > USB flash drive is often enough) - this will add space to allocate a few > new chunks, allowing the balance t

Re: 3.14.0rc3: did not find backref in send_root

2014-05-05 Thread David Brown
On Mon, Feb 24, 2014 at 10:36:52PM -0800, Marc MERLIN wrote: I got this during a btrfs send: BTRFS error (device dm-2): did not find backref in send_root. inode=22672, offset=524288, disk_byte=1490517954560 found extent=1490517954560 I'll try a scrub when I've finished my backup, but is there a

[RFC PATCH 0/2] Kernel space btrfs missing device detection.

2014-05-05 Thread Qu Wenruo
Original btrfs will not detection any missing device since there is no notification mechanism for fs layer to detect missing device in block layer. However we don't really need to notify fs layer upon dev remove, probing in dev_info/rm_dev ioctl is good enough since they are the only two ioctls ca

[RFC PATCH 2/2] btrfs-progs: Add userspace support for kernel missing dev detection.

2014-05-05 Thread Qu Wenruo
Add userspace support for kernel missing dev detection from dev_info ioctl. Now 'btrfs fi show' will auto detect the output format of dev_info ioctl and use kernel missing dev detection if supported. Also userspace missing dev detection is used as a fallback method and when used, a info message wi

[RFC PATCH 2/2] btrfs: Add new member of btrfs_ioctl_dev_info_args.

2014-05-05 Thread Qu Wenruo
Add flags member for btrfs_ioctl_dev_info_args to preset missing btrfs devices. The new member is added in the original padding area so the ioctl API is not affected but user headers needs to be updated. Cc: Anand Jain Signed-off-by: Qu Wenruo --- fs/btrfs/ioctl.c | 3 +++ include/ua

[RFC PATCH 1/2] btrfs: Add missing device check in dev_info/rm_dev ioctl

2014-05-05 Thread Qu Wenruo
Old btrfs can't find a missing btrfs device since there is no mechanism for block layer to inform fs layer. But we can use a workaround that only check status(by using request_queue->queue_flags) of every device in a btrfs filesystem when calling dev_info/rm_dev ioctl, since other ioctls do not re

[RFC PATCH 1/2] btrfs-progs: Follow kernel changes to add new member of btrfs_ioctl_dev_info_args.

2014-05-05 Thread Qu Wenruo
Follow the kernel header changes to add new member of btrfs_ioctl_dev_info_args. This change will use special bit to keep backward compatibility, so even on old kernels this will not screw anything up. Signed-off-by: Qu Wenruo --- ioctl.h | 5 - 1 file changed, 4 insertions(+), 1 deletion(-