Reported on IRC that the inode number limit appears to be 264, while the
actual value is 2^64. Fix that for the manual page backend by redefining
the format.
Signed-off-by: David Sterba <dsterba@suse.com>
Add a new section, QUOTA RESCAN, to explain why and when we need a full
quota rescan when assigning/removing qgroup relationship.
Also, since 'remove' shares the same options of 'assign', add reference
to 'assign' options for 'remove' subcommand.
Signed-off-by: Qu Wenruo <wqu@suse.com>
[ update ]
Signed-off-by: David Sterba <dsterba@suse.com>
Even though we have --rescan option, it still needs the user to manually
specify it or call quota rescan command.
This does not make much sense for the most common usecase and only
confuses users. When the rescan is not desired, the --no-rescan option
can be used, eg. when a mass qgruop assignment happens and the repeated
rescan would slow things down. This is considered a marginal usecase.
Signed-off-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Originally print-tree uses depth first search to print trees.
This works fine until we reach 3 level trees (root node level is 2).
For tall trees whose root level is 2 or higher, DFS will mix nodes and
leaves like the following example:
Level 2 A
/ \
Level 1 B C
/ | | \
Level 0 D E F G
DFS will cause the following output sequence:
A B D E C F G
Which in term of node/leave is:
N N L L N L L
Such mixed node/leave result is sometimes hard for human to read.
This patch will introduce 2 new options, --bfs and --dfs.
--dfs: keeps the original output sequence, and to keep things
compatible it's the default behavior.
--bfs: uses breadth-first search, and will cause better output
sequence like:
A B C D E F G
Which in term of node/leave is:
N N N L L L L
Much better sorted and may become default in the future.
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Some information is obsolete and updated as follows:
- add missing explanations of some options
- remove outdated explanation of "subvolrootid" mount option
- reorder/group options of "subvolume list" so it matches the help
message
- add explanation of different meanings of parent in "parent ID/UUID"
- fix indentation/spelling
- add missing comma
Signed-off-by: Misono Tomohiro <misono.tomohiro@jp.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
There's a regular manual page that matches the file glob mask *.8 so we
have to be more careful and remove only the known intermediate files.
Signed-off-by: David Sterba <dsterba@suse.com>
The manual pages are not compressed anymore and we can remove gzip from
build dependencies and build steps.
Signed-off-by: David Sterba <dsterba@suse.com>
Build systems do not typically compress man pages when installing them.
This is generally left to distro packaging mechanisms, which may end up
recompressing them using a different compressor.
Author: Mike Gilbert <floppym@gentoo.org>
Signed-off-by: David Sterba <dsterba@suse.com>
In order to install uncompressed manual pages we can't use the symlink
for the deprecated btrfsck page. Replace it by source command provided
by the manual page format.
Old: man8/btrfsck.8.gz (symlink)
New: man8/btrfsck.8 (file)
Reported-by: Mike Gilbert <floppym@gentoo.org>
Signed-off-by: David Sterba <dsterba@suse.com>
The option '-R' of btrfs-scrub was documented by mistake as
'print raw statistics per-device instead of a summary'.
Here change it to 'raw print mode, print full data instead of
summary' which it works actually.
Fixes: 162257574a ("btrfs-progs: docs: update btrfs-scrub")
Reported-by: Chris Murphy <chris@colorremedies.com>
Signed-off-by: Su Yue <suy.fnst@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Update the information to reflect the status of 4.18
Main Updates:
- Add explanation of improved compression heuristic algorithm
- Add explanation that norecovery == nologreplay
- Add explanation of nossd_spread mount option
- Add explanation of rmdir_subovl feature
Signed-off-by: Misono Tomohiro <misono.tomohiro@jp.fujitsu.com>
[ minor updates ]
Signed-off-by: David Sterba <dsterba@suse.com>
Its function has been superseded by btrfs inspect-internal show-super.
Furthermore the tools is currently not built by default. Just remove it.
Deprecated since 4.8.
Issue: #97
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Its function has been subsumed by "btrfs rescue zero-log". Remove its
source file and adjust make/tests soruces accordingly.
Deprecated since 4.0.
Issue: #97
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
There is already a replacement in the face of btrfs inspect-internal
dump-tree. And this command is just a simple wrapper around it. Just
remove it and adjust the show-blocks script to call the main btrfs
binary to achieve the same effect.
Informally deprecated since 4.4.
Issue: #97
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
A few more typo fixes, merged with the pull request.
Pull-request: #120
Signed-off-by: Gu Jinxiang <gujx@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
When debuging with "btrfs inspect dump-tree", it's not that handy if we
want to iterate all child tree blocks starting from a specified block.
-b can only print a single block, while without -b "btrfs inspect dump-tree"
will need extra tree roots fulfilled to continue, which is not possible
for a damaged filesystem.
Add a new option --follow to iterate a sub-tree starting from block
specified by --block.
Signed-off-by: Qu Wenruo <wqu@suse.com>
[ remove the short option for now ]
Signed-off-by: David Sterba <dsterba@suse.com>
We've been using asciidoc that's written in python2, which is going to
be phased out and deprecated next year. There's a replacement,
asciidoctor. Add a configure-time detection which tool is available,
update Documentation/Makefile.in.
The original asciidoc tool is still preferred as it produces slightly
better output. The file asciidoc.conf does not have a direct equivalten
in asciidoct and would need to be replaced by extension written in ruby.
The differences:
- the <literal> are not automatically underlined and are less visible in
the generated manual page, but it's still acceptable
- the inline CSS for the html output looks subjectively worse, is less
compact and colourful
Issue: #89
Signed-off-by: David Sterba <dsterba@suse.com>
Make --shrink a separate option for --rootdir, and change the default to
off.
The shrinking behaviour is not a commonly used feature but can be useful
for creating minimal pre-filled images, in one step, without requiring
to mount.
Signed-off-by: Qu Wenruo <wqu@suse.com>
[ update changelog and error messages ]
Signed-off-by: David Sterba <dsterba@suse.com>
To simplify, I suggest moving the 'writable/readonly' issue only to the
-r line, instead of having it introduced in two places.
Pull-request: #80
Author: Howard <hwj@BridgeportContractor.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Introduce new subcommand 'fix-device-size' to the rescue group, to fix
device size alignment-related problems.
Especially for people unable to mount their fs with super::total_bytes
mismatch, this tool will fix the problems and let the mount continue.
Reported-by: Asif Youssuff <yoasif@gmail.com>
Reported-by: Rich Rauenzahn <rrauenza@gmail.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Qu Wenruo <wqu@suse.com>
This patch updates help/document of "btrfs device remove" in two points:
1. Add explanation of 'missing' for 'device remove'. This is only
written in wikipage currently.
(https://btrfs.wiki.kernel.org/index.php/Using_Btrfs_with_Multiple_Devices)
2. Add example of device removal in the man document. This is because
that explanation of "remove" says "See the example section below", but
there is no example of removal currently.
Signed-off-by: Tomohiro Misono <misono.tomohiro@jp.fujitsu.com>
Reviewed-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
[ move "" from the macro to help strings ]
Signed-off-by: David Sterba <dsterba@suse.com>
Some people were asking why disabling compression via properties is not
set by "none" instead. As this is purely userspace conversion to "" that
kernel accepts, let's add "none" as well for convenience.
Signed-off-by: David Sterba <dsterba@suse.com>
It's messy to use "" to disable compression. Introduce the new value "no"
which can also be used for this purpose.
Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
[ coding style fixes ]
Signed-off-by: David Sterba <dsterba@suse.com>
This patch changes "subvol set-default" to also accept the subvolume path
for convenience.
If there are two args, they are assumed as subvol id and path to the fs
(the same as current behavior), and if there is only one arg, it is assumed
as the path to the subvolume.
subvol id is resolved by test_issubvolume() + lookup_path_rootid().
The empty subvol (ino == 2) will get error on test_issubvolume() which
checks whether inode num is 256 or not.
Issue: #35
Signed-off-by: Tomohiro Misono <misono.tomohiro@jp.fujitsu.com>
[ update documentation, use the new multi-line command scheme ]
Signed-off-by: David Sterba <dsterba@suse.com>
Start documenting the ioctl interface to btrfs. The overall structure
should be settled, the formatting of the ioctl description may change in
the future, newly added ioctl descriptions should follow the examples of
BTRFS_IOC_SUBVOL_CREATE.
The document is not finished yet and will not be installed until most of
ioctls' details are filled in.
Signed-off-by: David Sterba <dsterba@suse.com>
Adds zstd support to the btrfs program. An optional dependency on libzstd
>= 1.0.0 is added. Autoconf accepts `--enable-zstd' or `--disable-zstd' and
defaults to detecting if libzstd is present using `pkg-config'.
The patch is also available in my fork of btrfs-progs [1], which passes
Travis-CI with the new tests. The prebuilt binary is available there.
I haven't updated Android.mk.
[1] https://github.com/terrelln/btrfs-progs/tree/devel
Signed-off-by: Nick Terrell <terrelln@fb.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Sometimes it's needed to do a check on a mounted filesystem. This should
work fine on a quiescent filesystem or a read-only mount. Changes on the
block device done by kernel might confuse the userspace checker and it
might crash when it reads some stale data.
Repair without mount checks is not supported right now.
Signed-off-by: David Sterba <dsterba@suse.cz>
Usage info of "btrfs check" shows "-Q|--qgroup-report" (and first patch
enables -Q), but the document only shows "--qgroup-report".
Therefore add -Q to the doc.
Signed-off-by: Tomohiro Misono <misono.tomohiro@jp.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Code block of kernel backtrace lacks leading change line, causing the
following man page result:
------
One can determine whether zero-log is needed according to the
kernel backtrace:
? replay_one_dir_item+0xb5/0xb5 [btrfs]
? walk_log_tree+0x9c/0x19d [btrfs]
? btrfs_read_fs_root_no_radix+0x169/0x1a1 [btrfs]
? btrfs_recover_log_trees+0x195/0x29c [btrfs]
? replay_one_dir_item+0xb5/0xb5 [btrfs]
? btree_read_extent_buffer_pages+0x76/0xbc [btrfs]
? open_ctree+0xff6/0x132c [btrfs]
+ If the errors are like above, then zero-log should be used to clear
the log and the filesystem may be mounted normally again. The keywords
------
Not only "+" is rendered as is, but also wrong indent.
Fix it by adding change line before code block.
Signed-off-by: Qu Wenruo <quwenruo.btrfs@gmx.com>
Signed-off-by: David Sterba <dsterba@suse.com>