Re: [RFC PATCH v9 1/2] Btrfs: Add a new ioctl to get the label of a mounted file system

2013-01-07 Thread Jeff Liu
Hi Goffredo, On 01/08/2013 01:32 AM, Goffredo Baroncelli wrote: > Hi Jeff, > > On 01/07/2013 07:24 AM, Jeff Liu wrote: >> Hi, >> On 01/07/2013 02:44 AM, Goffredo Baroncelli wrote: >>> Hi Jeff, >>> >>> On 01/05/2013 03:48 AM, Jeff Liu wrote: Add a new ioctl(2) BTRFS_IOC_GET_FSLABLE, so that w

Re: [PATCH] Btrfs: replace simple_strtoull() with kstrtoull() in btrfs_ioctl_resize()

2013-01-07 Thread Jeff Liu
On 01/08/2013 12:03 AM, David Sterba wrote: > On Sun, Jan 06, 2013 at 11:53:41AM +0800, Jeff Liu wrote: >> -devid = simple_strtoull(devstr, &end, 10); >> +ret = kstrtoull(devstr, 10, &devid); >> +if (ret) { >> +pr_err("btrfs: resizer unable t

Btrfs fs not mounting or being identified after power loss.

2013-01-07 Thread Jordan Windsor
Hello, The power to my computer was suddenly cut, one of my btrfs fs (not the root) has somewhat disappeared, I can't mount it or use any of the available btrfs tools on it. Here's some command output: [root@archpc ~]# fdisk -l /dev/sdb Disk /dev/sdb: 808.9 GB, 80614912 bytes, 1579860576 sect

Re: chattr +C vs. btrfs subvolume snapshot

2013-01-07 Thread Liu Bo
On Tue, Jan 08, 2013 at 12:37:11AM +, Jun Lion wrote: > What happens if you set an individual file inside a subvolume as nocow > (chattr +C) and then take a snapshot of that subvolume and modify the > file in both? > > Will btrfs now ignore the nocow attribute completely or will it do "as > fe

Re: [PATCH] Btrfs: fix off-by-one in lseek

2013-01-07 Thread Liu Bo
On Mon, Jan 07, 2013 at 05:20:50PM +0100, David Sterba wrote: > On Mon, Jan 07, 2013 at 11:53:08AM +0800, Liu Bo wrote: > > Lock end is inclusive. > > > > Signed-off-by: Liu Bo > > --- > > fs/btrfs/file.c |1 + > > 1 files changed, 1 insertions(+), 0 deletions(-) > > > > diff --git a/fs/btr

Re: Open for contribution towards xfstests for btrfs

2013-01-07 Thread Kiran Patil
Hi, >> >> By any chance, are these the same people behind >> http://sourceforge.net/projects/btrfstest/ ? No, they are not the same people. > > If so, you might want to consider that > > http://www.tuxera.com/community/posix-test-suite/ > > probably already covers some of the tests that "btrfste

Re: [bug] csum mismatches and failed xfstests with 3.8-rc1 and rc2

2013-01-07 Thread Chris Mason
On Mon, Jan 07, 2013 at 10:06:40AM -0700, David Sterba wrote: > On Mon, Jan 07, 2013 at 06:03:51PM +0100, David Sterba wrote: > > with top commit 5f243b9b46a22e5790dbbc36f574c2417af49a41 (something post > > -rc2) I see more checksum errors > > > > $ dmesg|grep csum|wc -l > > 100 > > more of dmesg:

chattr +C vs. btrfs subvolume snapshot

2013-01-07 Thread Jun Lion
What happens if you set an individual file inside a subvolume as nocow (chattr +C) and then take a snapshot of that subvolume and modify the file in both? Will btrfs now ignore the nocow attribute completely or will it do "as few copies as possible"? (I'd love to know if it's possible to visualize

Re: [PATCH] btrfs: add "no file data" flag to btrfs send ioctl

2013-01-07 Thread Tsutomu Itoh
(2013/01/08 8:33), Mark Fasheh wrote: On Mon, Jan 07, 2013 at 11:01:17PM +0100, David Sterba wrote: On Mon, Jan 07, 2013 at 01:51:19PM -0800, Mark Fasheh wrote: +#define BTRFS_SEND_FLAG_NO_FILE_DATA 0x1 + + sctx->flags = arg->flags; + For compatibility reasons, you should mask th

Re: [PATCH] btrfs: add "no file data" flag to btrfs send ioctl

2013-01-07 Thread Mark Fasheh
On Mon, Jan 07, 2013 at 11:01:17PM +0100, David Sterba wrote: > On Mon, Jan 07, 2013 at 01:51:19PM -0800, Mark Fasheh wrote: > > +#define BTRFS_SEND_FLAG_NO_FILE_DATA 0x1 > > + > > > + sctx->flags = arg->flags; > > + > > For compatibility reasons, you should mask the user input value and on

Re: /boot as a btrfs subvolume

2013-01-07 Thread Chris Murphy
On Jan 7, 2013, at 2:41 PM, Gene Czarcinski wrote: >> >> And then if a distribution is deleted from the system, how is this >> discovered, and the old entry in the primary grub.cfg removed? Messy. > The hardware systems have four or five software systems on each. It is not > so much of deleti

[PATCH] Btrfs-progs: make btrfsck aware of free space inodes

2013-01-07 Thread Josef Bacik
From: Josef Bacik The new xfstests will run fsck against the volume to make sure we didn't introduce any inconsistencies, which is nice except we will error out immediately if we mount with inode_cache. We need to make btrfsck skip the special free space cache items and then just assume that we

Re: [PATCH] btrfs: add "no file data" flag to btrfs send ioctl

2013-01-07 Thread David Sterba
On Mon, Jan 07, 2013 at 01:51:19PM -0800, Mark Fasheh wrote: > +#define BTRFS_SEND_FLAG_NO_FILE_DATA 0x1 > + > + sctx->flags = arg->flags; > + For compatibility reasons, you should mask the user input value and only allow the supported flag(s). david -- To unsubscribe from this list: sen

[PATCH] Btrfs: add orphan before truncating pagecache

2013-01-07 Thread Josef Bacik
Running xfstests 83 in a loop would sometimes fail the fsck. This happens because if we invalidate a page that already has an ordered extent setup for it we will complete the ordered extent ourselves, assuming that the truncate will clean everything up. The problem with this is there is plenty of

[PATCH] btrfs: add "no file data" flag to btrfs send ioctl

2013-01-07 Thread Mark Fasheh
This patch adds the flag, BTRFS_SEND_FLAG_NO_FILE_DATA to the btrfs send ioctl code. When this flag is set, the btrfs send code will never write file data into the stream (thus also avoiding expensive reads of that data in the first place). BTRFS_SEND_C_UPDATE_EXTENT commands will be sent (instead

Re: /boot as a btrfs subvolume

2013-01-07 Thread Gene Czarcinski
On 01/07/2013 01:42 PM, Chris Murphy wrote: On Jan 7, 2013, at 8:42 AM, Gene Czarcinski wrote: On 01/06/2013 09:00 PM, Chris Murphy wrote: On Jan 6, 2013, at 1:05 PM, Gene Czarcinski wrote: On 01/06/2013 02:17 PM, Swâmi Petaramesh wrote: Le 06/01/2013 20:11, Chris Murphy a écrit : If you

Re: /boot as a btrfs subvolume

2013-01-07 Thread Chris Murphy
On Jan 7, 2013, at 10:48 AM, Swâmi Petaramesh wrote: > Le 06/01/2013 21:05, Gene Czarcinski a écrit : >> I assume you have a "grub partition" (or its equivalent) with a >> grub.cfg file having menuentry definitions [pointing to the different >> grub.cfg file for each system ... that seems to wor

Re: /boot as a btrfs subvolume

2013-01-07 Thread Chris Murphy
On Jan 7, 2013, at 8:42 AM, Gene Czarcinski wrote: > On 01/06/2013 09:00 PM, Chris Murphy wrote: >> On Jan 6, 2013, at 1:05 PM, Gene Czarcinski wrote: >> >>> On 01/06/2013 02:17 PM, Swâmi Petaramesh wrote: Le 06/01/2013 20:11, Chris Murphy a écrit : > If you use UUID, and you use subv

Re: Btrfs: wipe all the superblock [redhat bugzilla 889888]

2013-01-07 Thread Goffredo Baroncelli
Hi hugo On 01/07/2013 07:24 PM, Hugo Mills wrote: [...] >> print "Superblock #%d - %20d - '%s'"%(i,pos,sign) >> >> $ python extract-sign.py >> Superblock #0 -65600 - '_BHRfS_M' > > 64 KiB OK, (above) > >> Superblock #1 - 67108928 - '_BHRfS_M' > > 256 MiB

Re: Btrfs: wipe all the superblock [redhat bugzilla 889888]

2013-01-07 Thread Hugo Mills
On Mon, Jan 07, 2013 at 07:20:16PM +0100, Goffredo Baroncelli wrote: > Hi David, > > On 01/07/2013 05:33 PM, David Sterba wrote: > > On Sun, Jan 06, 2013 at 07:28:55PM +0100, Goffredo Baroncelli wrote: > >> Currently wipefs doesn't clear all the superblock of btrfs. Only the first > >> one is cle

Re: Btrfs: wipe all the superblock [redhat bugzilla 889888]

2013-01-07 Thread Goffredo Baroncelli
Hi David, On 01/07/2013 05:33 PM, David Sterba wrote: > On Sun, Jan 06, 2013 at 07:28:55PM +0100, Goffredo Baroncelli wrote: >> Currently wipefs doesn't clear all the superblock of btrfs. Only the first >> one is cleared. >> >> Btrfs has three superblocks. The first one is placed at 64KB, the sec

Re: Open for contribution towards xfstests for btrfs

2013-01-07 Thread Eric Sandeen
On 1/7/13 9:31 AM, David Sterba wrote: > On Mon, Jan 07, 2013 at 03:48:43PM +0530, Kiran Patil wrote: >> We have a team of 5 students who would like to contribute to btrfs >> filesystem testing using xfstests. > > By any chance, are these the same people behind > http://sourceforge.net/projects/bt

Re: /boot as a btrfs subvolume

2013-01-07 Thread Swâmi Petaramesh
Le 06/01/2013 21:05, Gene Czarcinski a écrit : > I assume you have a "grub partition" (or its equivalent) with a > grub.cfg file having menuentry definitions [pointing to the different > grub.cfg file for each system ... that seems to work well (at least > for me). Currently, os-prober does not su

Re: [RFC PATCH v9 1/2] Btrfs: Add a new ioctl to get the label of a mounted file system

2013-01-07 Thread Goffredo Baroncelli
Hi Jeff, On 01/07/2013 07:24 AM, Jeff Liu wrote: > Hi, > On 01/07/2013 02:44 AM, Goffredo Baroncelli wrote: >> Hi Jeff, >> >> On 01/05/2013 03:48 AM, Jeff Liu wrote: >>> Add a new ioctl(2) BTRFS_IOC_GET_FSLABLE, so that we can get the label upon >>> a mounted filesystem. >>> >>> Signed-off-by: Ji

Re: Online Deduplication for Btrfs (Master's thesis)

2013-01-07 Thread Martin Křížek
On Tue, Dec 18, 2012 at 2:31 AM, Chris Mason wrote: > On Mon, Dec 17, 2012 at 06:33:24AM -0700, Alexander Block wrote: >> I did some research on deduplication in the past and there are some >> problems that you will face. I'll try to list some of them (for sure >> not all). > > Thanks Alexander fo

Re: Open for contribution towards xfstests for btrfs

2013-01-07 Thread Kiran Patil
On Mon, Jan 7, 2013 at 10:31 PM, Kiran Patil wrote: > On Mon, Jan 7, 2013 at 9:28 PM, Eric Sandeen wrote: >> On 1/7/13 4:18 AM, Kiran Patil wrote: >>> Hello, >>> >>> We have a team of 5 students who would like to contribute to btrfs >>> filesystem testing using xfstests. >>> >>> Is there space fo

Re: [bug] csum mismatches and failed xfstests with 3.8-rc1 and rc2

2013-01-07 Thread David Sterba
On Mon, Jan 07, 2013 at 06:03:51PM +0100, David Sterba wrote: > with top commit 5f243b9b46a22e5790dbbc36f574c2417af49a41 (something post > -rc2) I see more checksum errors > > $ dmesg|grep csum|wc -l > 100 more of dmesg: [15303.739076] btrfs csum failed ino 63791 off 368640 csum 3994424334 priva

Re: [bug] csum mismatches and failed xfstests with 3.8-rc1 and rc2

2013-01-07 Thread David Sterba
with top commit 5f243b9b46a22e5790dbbc36f574c2417af49a41 (something post -rc2) I see more checksum errors $ dmesg|grep csum|wc -l 100 and they appeared in a period of like last 30 minutes. previous test rounds were clean, and I can see that the same test sequenece run 3 time in a row with the s

Re: Open for contribution towards xfstests for btrfs

2013-01-07 Thread Kiran Patil
On Mon, Jan 7, 2013 at 9:28 PM, Eric Sandeen wrote: > On 1/7/13 4:18 AM, Kiran Patil wrote: >> Hello, >> >> We have a team of 5 students who would like to contribute to btrfs >> filesystem testing using xfstests. >> >> Is there space for them to contribute? >> >> If yes, to whom do they need to ke

Re: Btrfs: wipe all the superblock [redhat bugzilla 889888]

2013-01-07 Thread David Sterba
On Sun, Jan 06, 2013 at 07:28:55PM +0100, Goffredo Baroncelli wrote: > Currently wipefs doesn't clear all the superblock of btrfs. Only the first > one is cleared. > > Btrfs has three superblocks. The first one is placed at 64KB, the second > one at 64MB, the third one at 256GB. It can have as

Re: [bug] oops in linux-3.8-rc2

2013-01-07 Thread Tom Gundersen
On Mon, Jan 7, 2013 at 2:00 PM, Chris Mason wrote: > The big question is, can you make it happen again? I wish I could, but I don't want to ;-) At least not on this machine (it is, very foolishly, my work machine). I'll try to reproduce it in a VM and let you know if/when I manage. Cheers, Tom

Re: [PATCH] Btrfs: fix off-by-one in lseek

2013-01-07 Thread David Sterba
On Mon, Jan 07, 2013 at 11:53:08AM +0800, Liu Bo wrote: > Lock end is inclusive. > > Signed-off-by: Liu Bo > --- > fs/btrfs/file.c |1 + > 1 files changed, 1 insertions(+), 0 deletions(-) > > diff --git a/fs/btrfs/file.c b/fs/btrfs/file.c > index 77061bf..1e16b6d 100644 > --- a/fs/btrfs/fil

Re: [PATCH] Btrfs: replace simple_strtoull() with kstrtoull() in btrfs_ioctl_resize()

2013-01-07 Thread David Sterba
On Sun, Jan 06, 2013 at 11:53:41AM +0800, Jeff Liu wrote: > - devid = simple_strtoull(devstr, &end, 10); > + ret = kstrtoull(devstr, 10, &devid); > + if (ret) { > + pr_err("btrfs: resizer unable to parse device %s\n", > +

Re: Open for contribution towards xfstests for btrfs

2013-01-07 Thread Eric Sandeen
On 1/7/13 4:18 AM, Kiran Patil wrote: > Hello, > > We have a team of 5 students who would like to contribute to btrfs > filesystem testing using xfstests. > > Is there space for them to contribute? > > If yes, to whom do they need to keep in touch for guidance. (cc: xfs list) Are you thinking

Re: /boot as a btrfs subvolume

2013-01-07 Thread Gene Czarcinski
On 01/06/2013 09:00 PM, Chris Murphy wrote: On Jan 6, 2013, at 1:05 PM, Gene Czarcinski wrote: On 01/06/2013 02:17 PM, Swâmi Petaramesh wrote: Le 06/01/2013 20:11, Chris Murphy a écrit : If you use UUID, and you use subvol=, and you don't rename/move your subvolume, it's perfectly safe. Nev

Re: Open for contribution towards xfstests for btrfs

2013-01-07 Thread David Sterba
On Mon, Jan 07, 2013 at 03:48:43PM +0530, Kiran Patil wrote: > We have a team of 5 students who would like to contribute to btrfs > filesystem testing using xfstests. By any chance, are these the same people behind http://sourceforge.net/projects/btrfstest/ ? > Is there space for them to contribu

Re: Open for contribution towards xfstests for btrfs

2013-01-07 Thread Arne Jansen
On 07.01.2013 14:01, Liu Bo wrote: > On Mon, Jan 07, 2013 at 03:48:43PM +0530, Kiran Patil wrote: >> Hello, >> >> We have a team of 5 students who would like to contribute to btrfs >> filesystem testing using xfstests. >> >> Is there space for them to contribute? > > xfstests is lacking of testcas

Re: Open for contribution towards xfstests for btrfs

2013-01-07 Thread Liu Bo
On Mon, Jan 07, 2013 at 03:48:43PM +0530, Kiran Patil wrote: > Hello, > > We have a team of 5 students who would like to contribute to btrfs > filesystem testing using xfstests. > > Is there space for them to contribute? xfstests is lacking of testcases targetting for btrfs send/recieve, you may

Re: [bug] oops in linux-3.8-rc2

2013-01-07 Thread Chris Mason
On Mon, Jan 07, 2013 at 04:10:37AM -0700, David Sterba wrote: > Hi, > > On Mon, Jan 07, 2013 at 01:51:21AM +0100, Tom Gundersen wrote: > > I ran into a bug today with 3.8-rc2 [0], following an "make > > modules_install && make install" of the kernel. > > > > I have been using the same kernel with

Re: [bug] oops in linux-3.8-rc2

2013-01-07 Thread David Sterba
Hi, On Mon, Jan 07, 2013 at 01:51:21AM +0100, Tom Gundersen wrote: > I ran into a bug today with 3.8-rc2 [0], following an "make > modules_install && make install" of the kernel. > > I have been using the same kernel without problems for some days, the > only change immediately before the oops wa

[PATCH] Btrfs: fix a bug when llseek for delalloc bytes behind prealloc extents

2013-01-07 Thread Liu Bo
xfstests case 285 complains. It it because btrfs did not try to find unwritten delalloc bytes(only dirty pages, not yet writeback) behind prealloc extents, it ends up finding nothing while we're with SEEK_DATA. Signed-off-by: Liu Bo --- fs/btrfs/file.c |9 ++--- fs/btrfs/inode.c | 11