Re: [PATCH] [RFC v2] Btrfs: Subpagesize blocksize (WIP).

2012-12-17 Thread Liu Bo
On Mon, Dec 17, 2012 at 11:13:25PM -0800, cli...@linux.vnet.ibm.com wrote: > From: Wade Cline > > v1 -> v2: > - Added Signed-off-by tag (it's kind of important). > > This patch is only an RFC. My internship is ending and I was hoping > to get some feedback and incorporate any suggestions people

[PATCH] [RFC v2] Btrfs: Subpagesize blocksize (WIP).

2012-12-17 Thread clinew
From: Wade Cline v1 -> v2: - Added Signed-off-by tag (it's kind of important). This patch is only an RFC. My internship is ending and I was hoping to get some feedback and incorporate any suggestions people may have before my internship ends along with life as we know it (this Friday). The file

[PATCH] [RFC] Btrfs: Subpagesize blocksize (WIP).

2012-12-17 Thread clinew
From: Wade Cline This patch is only an RFC. My internship is ending and I was hoping to get some feedback and incorporate any suggestions people may have before my internship ends along with life as we know it (this Friday). The filesystem should mount/umount properly but tends towards the explo

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

2012-12-17 Thread Miao Xie
On Tue, 18 Dec 2012 11:06:07 +0800, Jeff Liu wrote: > Introduce a new ioctl BTRFS_IOC_SET_FSLABEL to change the label of a mounted > file system. > > Signed-off-by: Jie Liu > Signed-off-by: Anand Jain > Cc: Miao Xie > Cc: Goffredo Baroncelli Reviewed-by: Miao Xie > > --- > fs/btrfs/ioct

Re: subvolume show

2012-12-17 Thread Anand Jain
This looks like a useful capability. I was trying to find out what the UUID was for a newly created subvolume and have not found out how to do that. btrfs subvol list -u /mnt should help ? btrfs subvol show is quite useful indeed we should consider to have it in git. -Anand On 13/12/

[RFC PATCH V6 2/2] Btrfs: Add a new ioctl to change the label of a mounted file system

2012-12-17 Thread Jeff Liu
Introduce a new ioctl BTRFS_IOC_SET_FSLABEL to change the label of a mounted file system. Signed-off-by: Jie Liu Signed-off-by: Anand Jain Cc: Miao Xie Cc: Goffredo Baroncelli --- fs/btrfs/ioctl.c | 39 +++ fs/btrfs/ioctl.h |2 ++ 2 files changed, 4

[RFC PATCH V6 0/2] Btrfs: get/set label of a mounted file system

2012-12-17 Thread Jeff Liu
Hello, Here is quick fix for btrfs set lable ioctl(2) based on v5, it does label length check up with strnlen() to avoid searching a zero could go beyond the page limit touching an un-mapped page and raising an segmentation fault with strlen(). V6->v5: - Improve the input label string validati

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

2012-12-17 Thread Jeff Liu
Introduce a new ioctl BTRFS_IOC_GET_FSLABEL to fetch the label of a mounted file system. Signed-off-by: Jie Liu Signed-off-by: Anand Jain Reviewed-by: Miao Xie --- fs/btrfs/ioctl.c | 15 +++ fs/btrfs/ioctl.h |2 ++ 2 files changed, 17 insertions(+) diff --git a/fs/btrfs/io

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

2012-12-17 Thread Jeff Liu
On 12/18/2012 10:33 AM, Jeff Liu wrote: > On 12/18/2012 10:21 AM, Miao Xie wrote: >> On mon, 17 Dec 2012 18:34:41 +0100, Goffredo Baroncelli wrote: >>> On 12/17/2012 02:30 PM, Jeff Liu wrote: On 12/17/2012 07:57 PM, Miao Xie wrote: > Onmon, 17 Dec 2012 19:22:11 +0800, Jeff Liu wr

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

2012-12-17 Thread Jeff Liu
On 12/18/2012 10:21 AM, Miao Xie wrote: > Onmon, 17 Dec 2012 18:34:41 +0100, Goffredo Baroncelli wrote: >> On 12/17/2012 02:30 PM, Jeff Liu wrote: >>> On 12/17/2012 07:57 PM, Miao Xie wrote: On mon, 17 Dec 2012 19:22:11 +0800, Jeff Liu wrote: > Introduce a new ioctl BTRFS_IOC_S

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

2012-12-17 Thread Miao Xie
On mon, 17 Dec 2012 18:34:41 +0100, Goffredo Baroncelli wrote: > On 12/17/2012 02:30 PM, Jeff Liu wrote: >> On 12/17/2012 07:57 PM, Miao Xie wrote: >>> On mon, 17 Dec 2012 19:22:11 +0800, Jeff Liu wrote: Introduce a new ioctl BTRFS_IOC_SET_FSLABEL to change the label of a mounted f

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

2012-12-17 Thread Jeff Liu
On 12/18/2012 01:34 AM, Goffredo Baroncelli wrote: > On 12/17/2012 02:30 PM, Jeff Liu wrote: >> On 12/17/2012 07:57 PM, Miao Xie wrote: >>> On mon, 17 Dec 2012 19:22:11 +0800, Jeff Liu wrote: Introduce a new ioctl BTRFS_IOC_SET_FSLABEL to change the label of a mounted file system.

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

2012-12-17 Thread Chris Mason
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 for writing all of this up. There are a lot of great points he

Re: getdents spinning on 0x7fffffff

2012-12-17 Thread Chris Mason
On Mon, Dec 17, 2012 at 04:50:39PM -0700, Zach Brown wrote: > On Mon, Dec 17, 2012 at 06:28:40PM -0500, Chris Mason wrote: > > On Mon, Dec 17, 2012 at 04:09:07PM -0700, Zach Brown wrote: > > > 1) The fundamental fix is to re-use deleted entry positions. Do we add > > > another cache to index unlin

Re: getdents spinning on 0x7fffffff

2012-12-17 Thread Zach Brown
On Mon, Dec 17, 2012 at 06:28:40PM -0500, Chris Mason wrote: > On Mon, Dec 17, 2012 at 04:09:07PM -0700, Zach Brown wrote: > > 1) The fundamental fix is to re-use deleted entry positions. Do we add > > another cache to index unlinked positions? Do we add an unreliable > > best-effort walk of the

Re: getdents spinning on 0x7fffffff

2012-12-17 Thread Chris Mason
On Mon, Dec 17, 2012 at 04:09:07PM -0700, Zach Brown wrote: > I was flipping through the code recently and noticed that we still have > the double whammy of allocating dir entry positions with > parent_dir->counter++ and that weird setting of f_pos to 2^31-1. > > So after enough creates (and delet

getdents spinning on 0x7fffffff

2012-12-17 Thread Zach Brown
I was flipping through the code recently and noticed that we still have the double whammy of allocating dir entry positions with parent_dir->counter++ and that weird setting of f_pos to 2^31-1. So after enough creates (and deletes :)) in a directory we end up with an entry item whose key is past t

[GIT PULL] Btrfs updates

2012-12-17 Thread Chris Mason
[ sorry, resend. My lbdb autocompleted with an extra r in kernel.org ] Hi everyone, My for-linus branch has a big set of fixes and features: git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs.git for-linus This was against 3.7, and it has two easy conflicts against Linus' current

[GIT PULL] Btrfs updates

2012-12-17 Thread Chris Mason
Hi everyone, My for-linus branch has a big set of fixes and features: git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs.git for-linus This was against 3.7, and it has two easy conflicts against Linus' current head. My -next branch has the resolutions, but Linus wills surely fix th

[PATCH][TRIVIAL] Unvalid access check

2012-12-17 Thread Goffredo Baroncelli
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Dear All, I found an incorrect check in the file fs/btrfs/send.c . It was wrote sizeof(*arg->clone_sources * arg->clone_sources_count) instead of sizeof(*arg->clone_sources) * arg->clone_sources_count Unfortunately arg->clone_sources

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

2012-12-17 Thread Goffredo Baroncelli
On 12/17/2012 02:30 PM, Jeff Liu wrote: > On 12/17/2012 07:57 PM, Miao Xie wrote: >> On mon, 17 Dec 2012 19:22:11 +0800, Jeff Liu wrote: >>> Introduce a new ioctl BTRFS_IOC_SET_FSLABEL to change the label of a >>> mounted file system. >>> >>> Signed-off-by: Jie Liu >>> Signed-off-by: Anand Jain

Re: Feeback on RAID1 feature of Btrfs

2012-12-17 Thread Hugo Mills
On Mon, Dec 17, 2012 at 04:51:33PM +0100, Sebastien Luttringer wrote: > Hello, > > I'm testing Btrfs RAID1 feature on 3 disks of ~10GB. Last one is not > exactly 10GB (would be too easy). > > About the test machine, it's a kvm vm running an up-to-date archlinux > with linux 3.7 and btrfs-progs 0.

Re: Feeback on RAID1 feature of Btrfs

2012-12-17 Thread Bart Noordervliet
Hello Sebastien, with btrfs raid1 you get two copies of each extent on separate drives. That means you can lose one drive only, no matter how many drives are in the set. It's not traditional raid1, which is probably what you are confusing it with. Having raid1 with more than 2n-redudancy is not cu

Feeback on RAID1 feature of Btrfs

2012-12-17 Thread Sebastien Luttringer
Hello, I'm testing Btrfs RAID1 feature on 3 disks of ~10GB. Last one is not exactly 10GB (would be too easy). About the test machine, it's a kvm vm running an up-to-date archlinux with linux 3.7 and btrfs-progs 0.19.20121005. #uname -a Linux seblu-btrfs-1 3.7.0-1-ARCH #1 SMP PREEMPT Tue Dec 11 1

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

2012-12-17 Thread Jeff Liu
On 12/17/2012 07:57 PM, Miao Xie wrote: > Onmon, 17 Dec 2012 19:22:11 +0800, Jeff Liu wrote: >> Introduce a new ioctl BTRFS_IOC_SET_FSLABEL to change the label of a mounted >> file system. >> >> Signed-off-by: Jie Liu >> Signed-off-by: Anand Jain >> Cc: Miao Xie >> >> --- >> fs/btrfs/ioctl

Re: Regarding contribution to BTRFS

2012-12-17 Thread Atri Sharma
On Mon, Dec 17, 2012 at 6:34 PM, Atri Sharma wrote: > On Mon, Dec 17, 2012 at 6:23 PM, Atri Sharma wrote: >> On Mon, Dec 17, 2012 at 6:08 PM, Hugo Mills wrote: >>> On Mon, Dec 17, 2012 at 05:39:45PM +0530, Atri Sharma wrote: Sorry,the email is incomplete. As mentioned above, I am

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

2012-12-17 Thread Hubert Kario
On Monday 17 of December 2012 13:05:01 Martin Křížek wrote: > * Limitations > Not really limitations, but this is a list of situations when dedup will > not be triggered: > - compression - basically, dedup is kind of compression, might be worth to > into it in the future though I don't see why it

Re: Regarding contribution to BTRFS

2012-12-17 Thread Atri Sharma
On Mon, Dec 17, 2012 at 6:23 PM, Atri Sharma wrote: > On Mon, Dec 17, 2012 at 6:08 PM, Hugo Mills wrote: >> On Mon, Dec 17, 2012 at 05:39:45PM +0530, Atri Sharma wrote: >>> Sorry,the email is incomplete. >>> >>> As mentioned above, I am a C developer and really interested in file >>> systems, and

Re: Regarding contribution to BTRFS

2012-12-17 Thread Atri Sharma
On Mon, Dec 17, 2012 at 6:08 PM, Hugo Mills wrote: > On Mon, Dec 17, 2012 at 05:39:45PM +0530, Atri Sharma wrote: >> Sorry,the email is incomplete. >> >> As mentioned above, I am a C developer and really interested in file >> systems, and the Fedora community redirected me to BTRFS. I would >> rea

Re: Regarding contribution to BTRFS

2012-12-17 Thread Hugo Mills
On Mon, Dec 17, 2012 at 05:39:45PM +0530, Atri Sharma wrote: > Sorry,the email is incomplete. > > As mentioned above, I am a C developer and really interested in file > systems, and the Fedora community redirected me to BTRFS. I would > really love to contribute to btrfs. > > Please let me know h

Re: Regarding contribution to BTRFS

2012-12-17 Thread Atri Sharma
Sorry,the email is incomplete. As mentioned above, I am a C developer and really interested in file systems, and the Fedora community redirected me to BTRFS. I would really love to contribute to btrfs. Please let me know how I can proceed further, and what are the potential areas I can work in.

Online Deduplication for Btrfs (Master's thesis)

2012-12-17 Thread Martin Křížek
Hello everyone, my name is Martin Krizek. I am a student at Faculty of Information, Brno University of Technology, Czech Republic. As my master's thesis I chose to work on Online Deduplication for Btrfs. My goal is to study Btrfs design, the offline deduplication patch [1] and to come up with a d

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

2012-12-17 Thread Miao Xie
On mon, 17 Dec 2012 19:22:02 +0800, Jeff Liu wrote: > Introduce a new ioctl BTRFS_IOC_GET_FSLABEL to fetch the label of a mounted > file system. > > Signed-off-by: Jie Liu > Signed-off-by: Anand Jain > Cc: Miao Xie Reviewed-by: Miao Xie > > --- > fs/btrfs/ioctl.c | 15 +

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

2012-12-17 Thread Miao Xie
On mon, 17 Dec 2012 19:22:11 +0800, Jeff Liu wrote: > Introduce a new ioctl BTRFS_IOC_SET_FSLABEL to change the label of a mounted > file system. > > Signed-off-by: Jie Liu > Signed-off-by: Anand Jain > Cc: Miao Xie > > --- > fs/btrfs/ioctl.c | 40 +

[PATCH V5 3/4] Btrfs-progs: Fix set_label_unmounted() with label length validation

2012-12-17 Thread Jeff Liu
Currently, we keeping silent if the label length is exceeding BTRFS_LABEL_SIZE - 1, and just truncating the characters beyond that. This patch make it return error and exit in this situation. Signed-off-by: Jie Liu Signed-off-by: Anand Jain --- btrfslabel.c | 10 -- 1 file changed,

[PATCH v5 4/4] Btrfs-progs: fix cmd_label_usage to reflect this change.

2012-12-17 Thread Jeff Liu
Fix the command usage of "btrfs filesystem label" to reflect this change. i.e. so that we can get/set the label of a mounted filesystem against the mountpoint. Signed-off-by: Jie Liu Signed-off-by: Anand Jain --- cmds-filesystem.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)

[PATCH V5 2/4] Btrfs-progs: Change the label of a mounted file system

2012-12-17 Thread Jeff Liu
With this new ioctl(2), we can set/change the label for a mounted file system. It still does normal process for an umounted file system. Signed-off-by: Jie Liu Signed-off-by: Anand Jain --- btrfslabel.c | 90 +++--- ioctl.h |2 ++

[PATCH v5 1/4] Btrfs-progs: get label of a mounted file system

2012-12-17 Thread Jeff Liu
With this new ioctl(2), we can get the label for a mounted file system. It still does normal process to fetch label if the specified file system is unmounted. Signed-off-by: Jie Liu Signed-off-by: Anand Jain --- btrfslabel.c | 74 ++

[RFC PATCH V5 2/2] Btrfs: Add a new ioctl to change the label of a mounted file system

2012-12-17 Thread Jeff Liu
Introduce a new ioctl BTRFS_IOC_SET_FSLABEL to change the label of a mounted file system. Signed-off-by: Jie Liu Signed-off-by: Anand Jain Cc: Miao Xie --- fs/btrfs/ioctl.c | 40 fs/btrfs/ioctl.h |2 ++ 2 files changed, 42 insertions(+) diff --

[RFC PATCH V5 1/2] Btrfs: Add a new ioctl to get the label of a mounted filesystem

2012-12-17 Thread Jeff Liu
Introduce a new ioctl BTRFS_IOC_GET_FSLABEL to fetch the label of a mounted file system. Signed-off-by: Jie Liu Signed-off-by: Anand Jain Cc: Miao Xie --- fs/btrfs/ioctl.c | 15 +++ fs/btrfs/ioctl.h |2 ++ 2 files changed, 17 insertions(+) diff --git a/fs/btrfs/ioctl.c b/f

[RFC PATCH V5 0/2] Btrfs: get/set label of mounted file system

2012-12-17 Thread Jeff Liu
Hello, This patch set is trying to make Btrfs support get/set label for a mounted file sytem via ioctl(2). There are a couple of changes according to Miao's comments which were shown as following. Changes of V5->V4 in kernel: - Revise the ioctl number of BTRFS_IOC_GET_FSLABEL/BTRFS_IOC_SET_FSLA

Re: btrfs subvolume snapshot performance problem

2012-12-17 Thread Russell Coker
On Mon, 17 Dec 2012, Sander wrote: > Let me repeat the answer cwillu gave to Russell on this, and Russell's > response: Also tests did indicate a performance benefit on snapshots when I stopped using discard. It was as much as 15 seconds to create a snapshot and now it's consistently less than

Re: btrfs subvolume snapshot performance problem

2012-12-17 Thread Sander
Sylvain Alain wrote (ao): > gentootux ~ # mount /dev/sda4 -o > noatime,ssd,discard,compress=lzo,noacl,space_cache,subvolid=0 ^^^ > Instead of 3 secondes to run the snapshot, it took almost 4 minutes. Let me repeat the answer cwillu gave to Russell on this, and Russell's response

Re: Snapper snapshot comparison algorithm

2012-12-17 Thread Alex Lyakas
Mohit, (unfortunately, it looks like I can answer emails only once a week:( ) On Mon, Dec 10, 2012 at 3:36 PM, Mohit Bhadade wrote: > Hi, > I started traversing the code and have some doubts in the > btrfs_compare_trees function. > > 1. Can you please explain the transaction join and leav