From: Lukas Czerner <lczerner@redhat.com>
To: Theodore Ts'o <tytso@mit.edu>
Cc: Ext4 Developers List <linux-ext4@vger.kernel.org>,
darrick.wong@oracle.com
Subject: Re: [PATCH 5/9] e2fscrub: add the -n option which shows what commands e2scrub would execute
Date: Thu, 21 Mar 2019 11:57:51 +0100 [thread overview]
Message-ID: <20190321105751.l7vlfhzmufgu3dfn@work> (raw)
In-Reply-To: <20190321020218.5154-5-tytso@mit.edu>
On Wed, Mar 20, 2019 at 10:02:14PM -0400, Theodore Ts'o wrote:
> Signed-off-by: Theodore Ts'o <tytso@mit.edu>
> ---
> scrub/e2scrub.8.in | 5 +++++
> scrub/e2scrub.in | 6 ++++--
> 2 files changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/scrub/e2scrub.8.in b/scrub/e2scrub.8.in
> index ff03523e3..7342876a3 100644
> --- a/scrub/e2scrub.8.in
> +++ b/scrub/e2scrub.8.in
> @@ -38,6 +38,11 @@ If the filesystem is not repaired,
> will be run before the next mount.
> .SH OPTIONS
> .TP
> +\fB-n\fR
> +Print what commands
> +.B e2scrub
> +would execute (but don't actually execute them).
We should be a bit more clear that it's not all the commands that will
be printed but not executed. Some of commands, like lsblk and lvs will
actually be executed so it's not like you can run this without proper
privledges.
It sounds nit-picky, and obvious to us, but I am sure someone will
complaing about this.
-Lukas
> +.TP
> \fB-r\fR
> Remove the e2scrub snapshot and exit without checking anything.
> .TP
> diff --git a/scrub/e2scrub.in b/scrub/e2scrub.in
> index 51a909373..301574968 100644
> --- a/scrub/e2scrub.in
> +++ b/scrub/e2scrub.in
> @@ -37,6 +37,7 @@ print_help() {
> echo "Usage: $0 [OPTIONS] mountpoint | device"
> echo
> echo "mountpoint must be on a LVM-managed block device"
> + echo "-n: Show what commands e2scrub would execute."
> echo "-r: Remove e2scrub snapshot and exit, do not check anything."
> echo "-t: Run fstrim if successful."
> echo "-V: Print version information and exit."
> @@ -68,8 +69,9 @@ exitcode() {
> exit "${ret}"
> }
>
> -while getopts "rtV" opt; do
> - case "${opt}" in
> +while getopts "nrtV" opt; do
> + case "${opt}" in
> + "n") DBG="echo Would execute: " ;;
> "r") reap=1;;
> "t") fstrim=1;;
> "V") print_version; exitcode 0;;
> --
> 2.19.1
>
next prev parent reply other threads:[~2019-03-21 10:57 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-21 2:02 [PATCH 1/9] e2scrub: check to make sure lvm2 is installed Theodore Ts'o
2019-03-21 2:02 ` [PATCH 2/9] debian: drop lvm2 from the recommends line Theodore Ts'o
2019-03-21 3:57 ` Darrick J. Wong
2019-03-21 2:02 ` [PATCH 3/9] Fix "make install-strip" Theodore Ts'o
2019-03-21 2:02 ` [PATCH 4/9] e2scrub: fix up "make install-strip" support Theodore Ts'o
2019-03-21 2:02 ` [PATCH 5/9] e2fscrub: add the -n option which shows what commands e2scrub would execute Theodore Ts'o
2019-03-21 3:59 ` Darrick J. Wong
2019-03-21 10:57 ` Lukas Czerner [this message]
2019-03-21 14:32 ` Theodore Ts'o
2019-03-21 2:02 ` [PATCH 6/9] e2scrub_all: add the -n option which shows what e2scrub_all would do Theodore Ts'o
2019-03-21 4:01 ` Darrick J. Wong
2019-03-21 2:02 ` [PATCH 7/9] e2scrub_all: make sure there's enough free space for a snapshot Theodore Ts'o
2019-03-21 4:02 ` Darrick J. Wong
2019-03-21 11:18 ` Lukas Czerner
2019-03-21 14:26 ` Theodore Ts'o
2019-03-21 2:02 ` [PATCH 8/9] e2scrub_all: refactor device probe loop Theodore Ts'o
2019-03-21 4:05 ` Darrick J. Wong
2019-03-21 10:27 ` Lukas Czerner
2019-03-21 14:31 ` Theodore Ts'o
2019-03-21 15:57 ` Lukas Czerner
2019-03-21 18:24 ` Theodore Ts'o
2019-03-21 20:17 ` Lukas Czerner
2019-03-21 20:48 ` Theodore Ts'o
2019-03-21 21:14 ` Lukas Czerner
2019-03-21 22:04 ` Theodore Ts'o
2019-03-21 22:08 ` Theodore Ts'o
2019-03-22 9:38 ` Lukas Czerner
2019-03-21 20:09 ` Andreas Dilger
2019-03-21 17:48 ` Theodore Ts'o
2019-03-21 19:49 ` Lukas Czerner
2019-03-21 20:23 ` Theodore Ts'o
2019-03-21 16:10 ` Lukas Czerner
2019-03-21 2:02 ` [PATCH 9/9] e2scrub,e2scrub_all: print a (more understandable) error if not run as root Theodore Ts'o
2019-03-21 4:04 ` Darrick J. Wong
2019-03-21 11:36 ` Lukas Czerner
2019-03-21 14:40 ` Theodore Ts'o
2019-03-21 3:55 ` [PATCH 1/9] e2scrub: check to make sure lvm2 is installed Darrick J. Wong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190321105751.l7vlfhzmufgu3dfn@work \
--to=lczerner@redhat.com \
--cc=darrick.wong@oracle.com \
--cc=linux-ext4@vger.kernel.org \
--cc=tytso@mit.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox