Re: Untar on empty partition returns ENOSPACE

2018-10-17 Thread Henk Slager
On Thu, Oct 18, 2018 at 6:04 AM Jean-Denis Girard wrote: > > Hi list, > > My goal is to duplicate some SD cards, to prepare 50 similar Raspberry Pi. > > First, I made a tar of my master SD card (unmounted). Then I made a > script, which creates 2 partitions (50 MB for boot, 14 GB for /), > creates

Re: Conversion to btrfs raid1 profile on added ext device renders some systems unable to boot into converted rootfs

2018-10-17 Thread Tony Prokott
On Wed, 17 Oct 2018 17:57:25 -0700 Qu Wenruo wrote ... > > But after chrooting to update-initramfs and cataloging resulting image > > content, usb_storage and uas were present under /lib/modules/xxx already, > > and failing systems still just busybox without a real rootfs rather

Re: [PATCH 09/29] vfs: combine the clone and dedupe into a single remap_file_range

2018-10-17 Thread Darrick J. Wong
On Thu, Oct 18, 2018 at 05:54:29AM +0100, Al Viro wrote: > On Wed, Oct 17, 2018 at 09:47:18PM -0700, Darrick J. Wong wrote: > > > > > +#define REMAP_FILE_DEDUP (1 << 0) > > > > + > > > > +/* > > > > + * These flags should be taken care of by the implementation (possibly > > > > usin

Re: [PATCH 09/29] vfs: combine the clone and dedupe into a single remap_file_range

2018-10-17 Thread Al Viro
On Wed, Oct 17, 2018 at 09:47:18PM -0700, Darrick J. Wong wrote: > > > +#define REMAP_FILE_DEDUP (1 << 0) > > > + > > > +/* > > > + * These flags should be taken care of by the implementation (possibly > > > using > > > + * vfs helpers) but can be ignored by the implementation. > > > + */

Re: [PATCH 09/29] vfs: combine the clone and dedupe into a single remap_file_range

2018-10-17 Thread Darrick J. Wong
On Thu, Oct 18, 2018 at 01:48:26AM +0100, Al Viro wrote: > On Wed, Oct 17, 2018 at 03:45:17PM -0700, Darrick J. Wong wrote: > > From: Darrick J. Wong > > > > Combine the clone_file_range and dedupe_file_range operations into a > > single remap_file_range file operation dispatch since they're > >

Re: [PATCH 04/29] vfs: strengthen checking of file range inputs to generic_remap_checks

2018-10-17 Thread Darrick J. Wong
On Thu, Oct 18, 2018 at 01:41:56AM +0100, Al Viro wrote: > On Wed, Oct 17, 2018 at 03:44:43PM -0700, Darrick J. Wong wrote: > > +static int generic_access_check_limits(struct file *file, loff_t pos, > > + loff_t *count) > > +{ > > + struct inode *inode = file->f_m

Untar on empty partition returns ENOSPACE

2018-10-17 Thread Jean-Denis Girard
Hi list, My goal is to duplicate some SD cards, to prepare 50 similar Raspberry Pi. First, I made a tar of my master SD card (unmounted). Then I made a script, which creates 2 partitions (50 MB for boot, 14 GB for /), creates the file-systems (vfat and btrfs, default options), mounts the two part

Re: Conversion to btrfs raid1 profile on added ext device renders some systems unable to boot into converted rootfs

2018-10-17 Thread Qu Wenruo
On 2018/10/18 上午12:38, Tony Prokott wrote: > Good day. My technical trouble seems to be beyond the scope of active helpers > on debian's irc support channel. Reasonable supposition that it's quite > particular to the development stage of btrfs infrastructure on 4.17.xxx > backport kernels and

Re: [PATCH 09/29] vfs: combine the clone and dedupe into a single remap_file_range

2018-10-17 Thread Al Viro
On Wed, Oct 17, 2018 at 03:45:17PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong > > Combine the clone_file_range and dedupe_file_range operations into a > single remap_file_range file operation dispatch since they're > fundamentally the same operation. The differences between the two ca

Re: Urgent: Need BTRFS-Expert

2018-10-17 Thread Qu Wenruo
On 2018/10/17 下午11:50, Michael Post wrote: > Hello Qu, > Hello Hugo, > > i got this result when i try to recover the chunk tree. > > # btrfs check /dev/mapper/vg0-virtualbox > bytenr mismatch, want=1263835381760, have=0 > ERROR: cannot open file system This means some essential trees get corru

Re: [PATCH 04/29] vfs: strengthen checking of file range inputs to generic_remap_checks

2018-10-17 Thread Al Viro
On Wed, Oct 17, 2018 at 03:44:43PM -0700, Darrick J. Wong wrote: > +static int generic_access_check_limits(struct file *file, loff_t pos, > +loff_t *count) > +{ > + struct inode *inode = file->f_mapping->host; > + > + /* Don't exceed the LFS limits. */ >

[PATCH 24/29] xfs: fix pagecache truncation prior to reflink

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Prior to remapping blocks, it is necessary to remove pages from the destination file's page cache. Unfortunately, the truncation is not aggressive enough -- if page size > block size, we'll end up zeroing subpage blocks instead of removing them. So, round the start offset

[PATCH 18/29] vfs: clean up generic_remap_file_range_prep return value

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Since the remap prep function can update the length of the remap request, we can change this function to return the usual return status instead of the odd behavior it has now. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig --- fs/ocfs2/refcounttree.c |

[PATCH 17/29] vfs: hide file range comparison function

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong There are no callers of vfs_dedupe_file_range_compare, so we might as well make it a static helper and remove the export. Signed-off-by: Darrick J. Wong Reviewed-by: Amir Goldstein Reviewed-by: Christoph Hellwig --- fs/read_write.c| 187 +---

[PATCH 27/29] xfs: remove redundant remap partial EOF block checks

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Now that we've moved the partial EOF block checks to the VFS helpers, we can remove the redundant functionality from XFS. Signed-off-by: Darrick J. Wong Reviewed-by: Dave Chinner --- fs/xfs/xfs_reflink.c | 19 --- 1 file changed, 19 deletions(-) diff

[PATCH 29/29] xfs: remove [cm]time update from reflink calls

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Now that the vfs remap helper dirties the inode [cm]time for us, xfs no longer needs to do that on its own. Signed-off-by: Darrick J. Wong --- fs/xfs/xfs_reflink.c |7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/fs/xfs/xfs_reflink.c b/fs/xfs/

[PATCH 28/29] xfs: remove xfs_reflink_remap_range

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Since xfs_file_remap_range is a thin wrapper, move the contents of xfs_reflink_remap_range into the shell. This cuts down on the vfs calls being made from internal xfs code. Signed-off-by: Darrick J. Wong --- fs/xfs/xfs_file.c| 65 ++

[PATCH 26/29] xfs: support returning partial reflink results

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Back when the XFS reflink code only supported clone_file_range, we were only able to return zero or negative error codes to userspace. However, now that copy_file_range (which returns bytes copied) can use XFS' clone_file_range, we have the opportunity to return partial res

[PATCH 25/29] xfs: clean up xfs_reflink_remap_blocks call site

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Move the offset <-> blocks unit conversions into xfs_reflink_remap_blocks to make the call site less ugly. Signed-off-by: Darrick J. Wong --- fs/xfs/xfs_reflink.c | 37 ++--- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git

[PATCH 23/29] xfs: add a per-xfs trace_printk macro

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Add a "xfs_tprintk" macro so that developers can use trace_printk to print out arbitrary debugging information with the XFS device name attached to the trace output. Signed-off-by: Darrick J. Wong --- fs/xfs/xfs_error.h |6 ++ 1 file changed, 6 insertions(+) dif

[PATCH 21/29] ocfs2: support partial clone range and dedupe range

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Change the ocfs2 remap code to allow for returning partial results. Signed-off-by: Darrick J. Wong --- fs/ocfs2/file.c |7 + fs/ocfs2/refcounttree.c | 72 +-- fs/ocfs2/refcounttree.h | 12 3 files ch

[PATCH 22/29] ocfs2: remove ocfs2_reflink_remap_range

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Since ocfs2_remap_file_range is a thin shell around ocfs2_remap_remap_range, move everything from the latter into the former. Signed-off-by: Darrick J. Wong --- fs/ocfs2/file.c | 68 +++- fs/ocfs2/refcounttree.c | 113 +++

[PATCH 16/29] vfs: enable remap callers that can handle short operations

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Plumb in a remap flag that enables the filesystem remap handler to shorten remapping requests for callers that can handle it. Now copy_file_range can report partial success (in case we run up against alignment problems, resource limits, etc.). We also enable CAN_SHORTEN fo

[PATCH 19/29] ocfs2: truncate page cache for clone destination file before remapping

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong When cloning blocks into another file, truncate the page cache before we start remapping blocks so that concurrent reads wait for us to finish. Signed-off-by: Darrick J. Wong --- fs/ocfs2/refcounttree.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-)

[PATCH 20/29] ocfs2: fix pagecache truncation prior to reflink

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Prior to remapping blocks, it is necessary to remove pages from the destination file's page cache. Unfortunately, the truncation is not aggressive enough -- if page size > block size, we'll end up zeroing subpage blocks instead of removing them. So, round the start offset

[PATCH 13/29] vfs: make remap_file_range functions take and return bytes completed

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Change the remap_file_range functions to take a number of bytes to operate upon and return the number of bytes they operated on. This is a requirement for allowing fs implementations to return short clone/dedupe results to the user, which will enable us to obey resource lim

[PATCH 12/29] vfs: remap helper should update destination inode metadata

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Extend generic_remap_file_range_prep to handle inode metadata updates when remapping into a file. If the operation can possibly alter the file contents, we must update the ctime and mtime and remove security privileges, just like we do for regular file writes. Signed-off-b

[PATCH 15/29] vfs: plumb remap flags through the vfs dedupe functions

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Plumb a remap_flags argument through the vfs_dedupe_file_range_one functions so that dedupe can take advantage of it. Signed-off-by: Darrick J. Wong Reviewed-by: Amir Goldstein --- fs/overlayfs/file.c |3 ++- fs/read_write.c |9 ++--- include/linux/fs.h

[PATCH 14/29] vfs: plumb remap flags through the vfs clone functions

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Plumb a remap_flags argument through the {do,vfs}_clone_file_range functions so that clone can take advantage of it. Signed-off-by: Darrick J. Wong Reviewed-by: Amir Goldstein --- fs/ioctl.c |2 +- fs/nfsd/vfs.c |2 +- fs/overlayfs/copy_up.c

[PATCH 11/29] vfs: pass remap flags to generic_remap_checks

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Pass the same remap flags to generic_remap_checks for consistency. Signed-off-by: Darrick J. Wong Reviewed-by: Amir Goldstein Reviewed-by: Christoph Hellwig --- fs/read_write.c|2 +- include/linux/fs.h |2 +- mm/filemap.c |4 ++-- 3 files changed,

[PATCH 10/29] vfs: pass remap flags to generic_remap_file_range_prep

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Plumb the remap flags through the filesystem from the vfs function dispatcher all the way to the prep function to prepare for behavior changes in subsequent patches. Signed-off-by: Darrick J. Wong Reviewed-by: Amir Goldstein Reviewed-by: Christoph Hellwig --- fs/ocfs2/f

[PATCH 09/29] vfs: combine the clone and dedupe into a single remap_file_range

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Combine the clone_file_range and dedupe_file_range operations into a single remap_file_range file operation dispatch since they're fundamentally the same operation. The differences between the two can be made in the prep functions. Signed-off-by: Darrick J. Wong Reviewed-

[PATCH 06/29] vfs: skip zero-length dedupe requests

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Don't bother calling the filesystem for a zero-length dedupe request; we can return zero and exit. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig Reviewed-by: Amir Goldstein --- fs/read_write.c |5 + 1 file changed, 5 insertions(+) diff --git a/

[PATCH 05/29] vfs: avoid problematic remapping requests into partial EOF block

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong A deduplication data corruption is exposed in XFS and btrfs. It is caused by extending the block match range to include the partial EOF block, but then allowing unknown data beyond EOF to be considered a "match" to data in the destination file because the comparison is only

[PATCH 07/29] vfs: rename vfs_clone_file_prep to be more descriptive

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong The vfs_clone_file_prep is a generic function to be called by filesystem implementations only. Rename the prefix to generic_ and make it more clear that it applies to remap operations, not just clones. Signed-off-by: Darrick J. Wong Reviewed-by: Amir Goldstein --- fs/oc

[PATCH 08/29] vfs: rename clone_verify_area to remap_verify_area

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Since we use clone_verify_area for both clone and dedupe range checks, rename the function to make it clear that it's for both. Signed-off-by: Darrick J. Wong Reviewed-by: Amir Goldstein --- fs/read_write.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(

[PATCH 04/29] vfs: strengthen checking of file range inputs to generic_remap_checks

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong File range remapping, if allowed to run past the destination file's EOF, is an optimization on a regular file write. Regular file writes that extend the file length are subject to various constraints which are not checked by range cloning. This is a correctness problem bec

[PATCH 03/29] vfs: exit early from zero length remap operations

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong If a remap caller asks us to remap to the source file's EOF and the source file length leaves us with a zero byte request, exit early. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig --- fs/read_write.c |2 ++ 1 file changed, 2 insertions(+) diff --gi

[PATCH 02/29] vfs: check file ranges before cloning files

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong Move the file range checks from vfs_clone_file_prep into a separate generic_remap_checks function so that all the checks are collected in a central location. This forms the basis for adding more checks from generic_write_checks that will make cloning's input checking more c

[PATCH v6 00/29] fs: fixes for serious clone/dedupe problems

2018-10-17 Thread Darrick J. Wong
Hi all, Dave, Eric, and I have been chasing a stale data exposure bug in the XFS reflink implementation, and tracked it down to reflink forgetting to do some of the file-extending activities that must happen for regular writes. We then started auditing the clone, dedupe, and copyfile code and rea

[PATCH 01/29] vfs: vfs_clone_file_prep_inodes should return EINVAL for a clone from beyond EOF

2018-10-17 Thread Darrick J. Wong
From: Darrick J. Wong vfs_clone_file_prep_inodes cannot return 0 if it is asked to remap from a zero byte file because that's what btrfs does. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig --- fs/read_write.c |3 --- 1 file changed, 3 deletions(-) diff --git a/fs/read_wr

Re: [PATCH] btrfs: delayed-ref: extract find_first_ref_head from find_ref_head

2018-10-17 Thread David Sterba
On Mon, Oct 15, 2018 at 02:25:38PM +0800, Lu Fengqi wrote: > The find_ref_head shouldn't return the first entry even if no exact match > is found. So move the hidden behavior to higher level. > > Besides, remove the useless local variables in the btrfs_select_ref_head. > > Signed-off-by: Lu Fengq

Conversion to btrfs raid1 profile on added ext device renders some systems unable to boot into converted rootfs

2018-10-17 Thread Tony Prokott
Good day. My technical trouble seems to be beyond the scope of active helpers on debian's irc support channel. Reasonable supposition that it's quite particular to the development stage of btrfs infrastructure on 4.17.xxx backport kernels and userland tools available on debian 9.5 stretch as wel

Re: [PATCH 25/26] xfs: support returning partial reflink results

2018-10-17 Thread Darrick J. Wong
On Wed, Oct 17, 2018 at 01:40:02AM -0700, Christoph Hellwig wrote: > > @@ -1415,11 +1419,17 @@ xfs_reflink_remap_range( > > > > trace_xfs_reflink_remap_range(src, pos_in, len, dest, pos_out); > > > > + if (len == 0) { > > + ret = 0; > > + goto out_unlock; > > + } > >

Re: [PATCH 17/26] vfs: enable remap callers that can handle short operations

2018-10-17 Thread Darrick J. Wong
On Wed, Oct 17, 2018 at 01:36:52AM -0700, Christoph Hellwig wrote: > > /* Update inode timestamps and remove security privileges when remapping. > > */ > > @@ -2023,7 +2034,8 @@ loff_t vfs_dedupe_file_range_one(struct file > > *src_file, loff_t src_pos, > > { > > loff_t ret; > > > > - W

Re: Urgent: Need BTRFS-Expert

2018-10-17 Thread Michael Post
Hello Qu, Hello Hugo, i got this result when i try to recover the chunk tree. # btrfs check /dev/mapper/vg0-virtualbox bytenr mismatch, want=1263835381760, have=0 ERROR: cannot open file system # btrfs rescue chunk-recover -y /dev/mapper/vg0-virtualbox Scanning: DONE in dev0 open with broken c

Re: [PATCH] Btrfs: fix assertion on fsync of regular file when using no-holes feature

2018-10-17 Thread David Sterba
On Mon, Oct 15, 2018 at 09:51:00AM +0100, fdman...@kernel.org wrote: > From: Filipe Manana > > When using the NO_HOLES feature and logging a regular file, we were > expecting that if we find an inline extent, that either its size in ram > (uncompressed and unenconded) matches the size of the file

Re: [PATCH v4 0/4] btrfs: Refactor find_free_extent()

2018-10-17 Thread David Sterba
On Wed, Oct 17, 2018 at 02:56:02PM +0800, Qu Wenruo wrote: > Can be fetched from github: > https://github.com/adam900710/linux/tree/refactor_find_free_extent > > Which is based on v4.19-rc1. > > extent-tree.c::find_free_extent() could be one of the most > ill-structured functions, it has at least

Re: [PATCH v4 2/4] btrfs: Refactor clustered extent allocation into find_free_extent_clustered()

2018-10-17 Thread David Sterba
On Wed, Oct 17, 2018 at 02:56:04PM +0800, Qu Wenruo wrote: > --- a/fs/btrfs/extent-tree.c > +++ b/fs/btrfs/extent-tree.c > @@ -7261,6 +7261,115 @@ struct find_free_extent_ctl { > u64 found_offset; > }; > > + No extra newlines. > +/* > + * Helper function for find_free_extent(). > + * > +

Re: [PATCH] Btrfs: fix deadlock when writing out free space caches

2018-10-17 Thread David Sterba
On Fri, Oct 12, 2018 at 10:03:55AM +0100, fdman...@kernel.org wrote: > From: Filipe Manana > > When writing out a block group free space cache we can end deadlocking > with ourseves on an extent buffer lock resulting in a warning like the > following: > > [245043.379979] WARNING: CPU: 4 PID: 2

Re: [PATCH 9/9] btrfs: Add RAID 6 recovery for a btrfs filesystem.

2018-10-17 Thread Daniel Kiper
On Thu, Oct 11, 2018 at 08:51:03PM +0200, Goffredo Baroncelli wrote: > From: Goffredo Baroncelli > > Add the RAID 6 recovery, in order to use a RAID 6 filesystem even if some > disks (up to two) are missing. This code use the md RAID 6 code already > present in grub. > > Signed-off-by: Goffredo Ba

Re: [PATCH 7/9] btrfs: Add support for recovery for a RAID 5 btrfs profiles.

2018-10-17 Thread Daniel Kiper
On Thu, Oct 11, 2018 at 08:51:01PM +0200, Goffredo Baroncelli wrote: > From: Goffredo Baroncelli > > Add support for recovery for a RAID 5 btrfs profile. In addition > it is added some code as preparatory work for RAID 6 recovery code. > > Signed-off-by: Goffredo Baroncelli > --- > grub-core/fs/

Re: [PATCH] btrfs: Fix the return value in case of error in 'btrfs_mark_extent_written()'

2018-10-17 Thread David Sterba
On Wed, Oct 17, 2018 at 11:13:59AM +0200, Christophe JAILLET wrote: > We return 0 unconditionally in most of the error handling paths of > 'btrfs_mark_extent_written()'. > However, 'ret' is set to some error codes in several error handling paths. > > Return 'ret' instead to propagate the error cod

Re: [PATCH 4/9] btrfs: Avoid a rescan for a device which was already not found.

2018-10-17 Thread Daniel Kiper
On Thu, Oct 11, 2018 at 08:50:58PM +0200, Goffredo Baroncelli wrote: > From: Goffredo Baroncelli > > Currently read from missing device triggers rescan. However, it is never > recorded that the device is missing. So, each read of a missing device > triggers rescan again and again. This behavior ca

Re: [PATCH 1/9] btrfs: Add support for reading a filesystem with a RAID 5 or RAID 6 profile.

2018-10-17 Thread Daniel Kiper
On Thu, Oct 11, 2018 at 08:50:55PM +0200, Goffredo Baroncelli wrote: > From: Goffredo Baroncelli > > Signed-off-by: Goffredo Baroncelli > Signed-off-by: Daniel Kiper One nit pick below... Otherwise you can add Reviewed-by: Daniel Kiper > --- > grub-core/fs/btrfs.c | 73 +

Re: CRC mismatch

2018-10-17 Thread Austin S. Hemmelgarn
On 2018-10-16 16:27, Chris Murphy wrote: On Tue, Oct 16, 2018 at 9:42 AM, Austin S. Hemmelgarn wrote: On 2018-10-16 11:30, Anton Shepelev wrote: Hello, all What may be the reason of a CRC mismatch on a BTRFS file in a virutal machine: csum failed ino 175524 off 1876295680 csum 45176055

Re: [PATCH 42/42] btrfs: don't run delayed_iputs in commit

2018-10-17 Thread David Sterba
On Fri, Oct 12, 2018 at 03:32:56PM -0400, Josef Bacik wrote: > This could result in a really bad case where we do something like > > evict > evict_refill_and_join > btrfs_commit_transaction > btrfs_run_delayed_iputs > evict > evict_refill_and_join > btrfs_

Re: [PATCH 19/42] btrfs: set max_extent_size properly

2018-10-17 Thread David Sterba
On Fri, Oct 12, 2018 at 03:32:33PM -0400, Josef Bacik wrote: > From: Josef Bacik > > We can't use entry->bytes if our entry is a bitmap entry, we need to use > entry->max_extent_size in that case. Fix up all the logic to make this > consistent. > > Signed-off-by: Josef Bacik > --- > fs/btrfs/

my subject

2018-10-17 Thread test
I am Peter Wong director of operations, Hong Kong and Shanghai Banking Corporation Limited Hong Kong. I have a very confidential business proposition involving transfer of $18.350.000.00 that will be of great benefit for both of us. Reply for more details as regards this transaction Best Regards P

Re: btrfs send receive: No space left on device

2018-10-17 Thread Henk Slager
On Wed, Oct 17, 2018 at 10:29 AM Libor Klepáč wrote: > > Hello, > i have new 32GB SSD in my intel nuc, installed debian9 on it, using btrfs as > a rootfs. > Then i created subvolumes /system and /home and moved system there. > > System was installed using kernel 4.9.x and filesystem created using

Re: Urgent: Need BTRFS-Expert

2018-10-17 Thread Qu Wenruo
On 2018/10/17 下午5:27, Michael Post wrote: > Hello Hugo, > > thanks for your information. > > I have an 1 TB BTRFS-Partition which suddenly could not be mounted. > > I tried the following commands > > > host@:btrfs check -b /dev/mapper/vg0-virtualbox > This is the important part. Please

Re: Urgent: Need BTRFS-Expert

2018-10-17 Thread Michael Post
Hello Hugo, thanks for your information. I have an 1 TB BTRFS-Partition which suddenly could not be mounted. I tried the following commands host@:btrfs check -b /dev/mapper/vg0-virtualbox Errors found in extent allocation tree or chunk allocation bytenr mismatch, want=1263661723648, have=

Re: Urgent: Need BTRFS-Expert

2018-10-17 Thread Hugo Mills
Hi, Michael, On Wed, Oct 17, 2018 at 09:58:31AM +0200, Michael Post wrote: > Hello together, > > i need a BTRFS-Expert for remote support. > > Anyone who can assist me? This is generally the wrong approach to take in open-source circles. Instead, if you describe your problem here on this

Re: CRC mismatch

2018-10-17 Thread Anton Shepelev
[I accdientally replied to Chris instead of the mailing list] Chris Murphy: >Is there still that O_DIRECT related "bug" (or more of a >limitation) if the guest is using cache=none on the block >device? I know nothing about it. >Anton what virtual machine tech are you using? qemu/kvm >managed wi

[PATCH] btrfs: Fix the return value in case of error in 'btrfs_mark_extent_written()'

2018-10-17 Thread Christophe JAILLET
We return 0 unconditionally in most of the error handling paths of 'btrfs_mark_extent_written()'. However, 'ret' is set to some error codes in several error handling paths. Return 'ret' instead to propagate the error code. Fixes: 9c8e63db1de9 ("Btrfs: kill BUG_ON()'s in btrfs_mark_extent_written"

Re: [PATCH 26/26] xfs: remove redundant remap partial EOF block checks

2018-10-17 Thread Christoph Hellwig
On Mon, Oct 15, 2018 at 08:21:02PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong > > Now that we've moved the partial EOF block checks to the VFS helpers, we > can remove the redundant functionality from XFS. > > Signed-off-by: Darrick J. Wong > Reviewed-by: Dave Chinner Looks fine,

Re: [PATCH 25/26] xfs: support returning partial reflink results

2018-10-17 Thread Christoph Hellwig
> @@ -1415,11 +1419,17 @@ xfs_reflink_remap_range( > > trace_xfs_reflink_remap_range(src, pos_in, len, dest, pos_out); > > + if (len == 0) { > + ret = 0; > + goto out_unlock; > + } > + As pointed out last time this check is superflous, right above we have

Re: [PATCH 24/26] xfs: fix pagecache truncation prior to reflink

2018-10-17 Thread Christoph Hellwig
On Mon, Oct 15, 2018 at 08:20:48PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong > > Prior to remapping blocks, it is necessary to remove pages from the > destination file's page cache. Unfortunately, the truncation is not > aggressive enough -- if page size > block size, we'll end up ze

Re: [PATCH 19/26] vfs: clean up generic_remap_file_range_prep return value

2018-10-17 Thread Christoph Hellwig
On Mon, Oct 15, 2018 at 08:20:14PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong > > Since the remap prep function can update the length of the remap > request, we can change this function to return the usual return status > instead of the odd behavior it has now. > > Signed-off-by: Darr

Re: [PATCH 17/26] vfs: enable remap callers that can handle short operations

2018-10-17 Thread Christoph Hellwig
> /* Update inode timestamps and remove security privileges when remapping. */ > @@ -2023,7 +2034,8 @@ loff_t vfs_dedupe_file_range_one(struct file *src_file, > loff_t src_pos, > { > loff_t ret; > > - WARN_ON_ONCE(remap_flags & ~(REMAP_FILE_DEDUP)); > + WARN_ON_ONCE(remap_flags &

Re: [PATCH 13/26] vfs: create generic_remap_file_range_touch to update inode metadata

2018-10-17 Thread Christoph Hellwig
On Mon, Oct 15, 2018 at 08:19:26PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong > > Create a new VFS helper to handle inode metadata updates when remapping > into a file. If the operation can possibly alter the file contents, we > must update the ctime and mtime and remove security priv

Re: [PATCH 12/26] vfs: pass remap flags to generic_remap_checks

2018-10-17 Thread Christoph Hellwig
On Mon, Oct 15, 2018 at 08:11:19PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong > > Pass the same remap flags to generic_remap_checks for consistency. > > Signed-off-by: Darrick J. Wong > Reviewed-by: Amir Goldstein Looks good, Reviewed-by: Christoph Hellwig

Re: [PATCH 11/26] vfs: pass remap flags to generic_remap_file_range_prep

2018-10-17 Thread Christoph Hellwig
On Mon, Oct 15, 2018 at 08:11:12PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong > > Plumb the remap flags through the filesystem from the vfs function > dispatcher all the way to the prep function to prepare for behavior > changes in subsequent patches. Looks good, Reviewed-by: Christo

Re: [PATCH 10/26] vfs: combine the clone and dedupe into a single remap_file_range

2018-10-17 Thread Christoph Hellwig
> +/* All valid REMAP_FILE flags */ > +#define REMAP_FILE_VALID_FLAGS (REMAP_FILE_DEDUP) It looks like this still isn't used after the whole series. With it removed: Reviewed-by: Christoph Hellwig

btrfs send receive: No space left on device

2018-10-17 Thread Libor Klepáč
Hello, i have new 32GB SSD in my intel nuc, installed debian9 on it, using btrfs as a rootfs. Then i created subvolumes /system and /home and moved system there. System was installed using kernel 4.9.x and filesystem created using btrfs-progs 4.7.x Details follow: main filesystem # btrfs filesy

Re: [PATCH 04/26] vfs: exit early from zero length remap operations

2018-10-17 Thread Christoph Hellwig
On Mon, Oct 15, 2018 at 08:10:23PM -0700, Darrick J. Wong wrote: > From: Darrick J. Wong > > If a remap caller asks us to remap to the source file's EOF and the > source file has zero bytes, exit early. > > Signed-off-by: Darrick J. Wong Looks good, Reviewed-by: Christoph Hellwig

Urgent: Need BTRFS-Expert

2018-10-17 Thread Michael Post
Hello together, i need a BTRFS-Expert for remote support. Anyone who can assist me via Skype or teamviewer? I will pay for it. Please let me know, Michael Post

Urgent: Need BTRFS-Expert

2018-10-17 Thread Michael Post
Hello together, i need a BTRFS-Expert for remote support. Anyone who can assist me? Please let me know, Michael Post