From: Junio C Hamano <gitster@pobox•com>
To: Thomas Ackermann <th.acker@arcor•de>
Cc: git@vger•kernel.org, wking@tremily•us, peff@peff•net
Subject: Re: [PATCH 13/13] "git prune" is safe now
Date: Sat, 24 Aug 2013 20:59:54 -0700 [thread overview]
Message-ID: <xmqqsixyl8sl.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <1590776724.1091303.1377329872606.JavaMail.ngmail@webmail08.arcor-online.net> (Thomas Ackermann's message of "Sat, 24 Aug 2013 09:37:52 +0200 (CEST)")
Thomas Ackermann <th.acker@arcor•de> writes:
> According to the man-pages of "git prune" and "git fsck",
> both are safe nowadays.
Safe does not have much to do with the latter. "git fsck" has
always been safe in that it would not alter the object store, and if
you run it while you are actively creating (or pruning for that
matter) objects, it _will_ get confused.
For that matter, running "prune", even though we designed it to be
safe from concurrent accesses, deliberately on a non-quiescent
repository is not a good idea, either. It may be a good idea to
weaken the phrasing used to discourage it, but discouraging itself
is not a bad idea.
> Signed-off-by: Thomas Ackermann <th.acker@arcor•de>
> ---
> Documentation/user-manual.txt | 12 +-----------
> 1 file changed, 1 insertion(+), 11 deletions(-)
>
> diff --git a/Documentation/user-manual.txt b/Documentation/user-manual.txt
> index 08d8c91..29945d9 100644
> --- a/Documentation/user-manual.txt
> +++ b/Documentation/user-manual.txt
> @@ -3283,17 +3283,7 @@ state, you can just prune all unreachable objects:
> $ git prune
> ------------------------------------------------
>
> -and they'll be gone. But you should only run `git prune` on a quiescent
> -repository--it's kind of like doing a filesystem fsck recovery: you
> -don't want to do that while the filesystem is mounted.
> -
> -(The same is true of `git fsck` itself, btw, but since
> -`git fsck` never actually *changes* the repository, it just reports
> -on what it found, `git fsck` itself is never 'dangerous' to run.
> -Running it while somebody is actually changing the repository can cause
> -confusing and scary messages, but it won't actually do anything bad. In
> -contrast, running `git prune` while somebody is actively changing the
> -repository is a *BAD* idea).
> +and they'll be gone.
>
> [[recovering-from-repository-corruption]]
> Recovering from repository corruption
next prev parent reply other threads:[~2013-08-25 4:00 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-24 7:22 [PATCH 0/13] Modernize user-manual Thomas Ackermann
2013-08-24 7:24 ` [PATCH 01/13] Call it "Git User Manual" and remove reference to very old Git version Thomas Ackermann
2013-08-25 3:05 ` Jonathan Nieder
2013-08-25 3:07 ` Junio C Hamano
2013-08-24 7:25 ` [PATCH 02/13] Use current "detached HEAD" message Thomas Ackermann
2013-08-25 3:49 ` Jonathan Nieder
2013-08-25 8:10 ` Aw: " Thomas Ackermann
2013-08-24 7:26 ` [PATCH 03/13] Use current output for "git repack" Thomas Ackermann
2013-08-25 4:15 ` Jonathan Nieder
2013-08-25 8:37 ` Aw: " Thomas Ackermann
2013-08-24 7:27 ` [PATCH 04/13] Use "git merge" instead of "git pull ." Thomas Ackermann
2013-08-25 3:17 ` Junio C Hamano
2013-08-25 4:19 ` Jonathan Nieder
2013-08-25 5:26 ` Martin von Zweigbergk
2013-08-24 7:28 ` [PATCH 05/13] Fix some typos Thomas Ackermann
2013-08-25 5:01 ` Jonathan Nieder
2013-08-25 9:13 ` Aw: " Thomas Ackermann
2013-08-24 7:29 ` [PATCH 06/13] Simplify "How to make a commit" Thomas Ackermann
2013-08-25 3:20 ` Junio C Hamano
2013-08-25 5:05 ` Jonathan Nieder
2013-08-25 9:20 ` Aw: " Thomas Ackermann
2013-08-24 7:30 ` [PATCH 07/13] Improve description in "How to merge" Thomas Ackermann
2013-08-25 3:22 ` Junio C Hamano
2013-08-25 5:08 ` Jonathan Nieder
2013-08-25 11:31 ` Aw: " Thomas Ackermann
2013-08-24 7:31 ` [PATCH 08/13] Improve section "Manipulating branches" Thomas Ackermann
2013-08-25 3:25 ` Junio C Hamano
2013-08-25 11:41 ` Aw: " Thomas Ackermann
2013-08-24 7:32 ` [PATCH 09/13] Improve section "Merge multiple trees" Thomas Ackermann
2013-08-25 5:23 ` Jonathan Nieder
2013-08-25 12:06 ` Aw: " Thomas Ackermann
2013-08-25 20:10 ` Jonathan Nieder
2013-08-24 7:33 ` [PATCH 10/13] Remove unnecessary historical note from "Object storage format" Thomas Ackermann
2013-08-25 3:28 ` Junio C Hamano
2013-08-24 7:34 ` [PATCH 11/13] Remove obscure reference from "Examples" Thomas Ackermann
2013-08-25 3:53 ` Junio C Hamano
2013-08-25 5:25 ` Jonathan Nieder
2013-08-25 9:30 ` Aw: " Thomas Ackermann
2013-08-24 7:35 ` [PATCH 12/13] Remove irrelevant reference from "Tying it all together" Thomas Ackermann
2013-08-25 3:56 ` Junio C Hamano
2013-08-26 13:51 ` Jon Loeliger
2013-08-24 7:37 ` [PATCH 13/13] "git prune" is safe now Thomas Ackermann
2013-08-25 3:59 ` Junio C Hamano [this message]
2013-08-24 19:31 ` [PATCH 0/13] Modernize user-manual Philip Oakley
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=xmqqsixyl8sl.fsf@gitster.dls.corp.google.com \
--to=gitster@pobox$(echo .)com \
--cc=git@vger$(echo .)kernel.org \
--cc=peff@peff$(echo .)net \
--cc=th.acker@arcor$(echo .)de \
--cc=wking@tremily$(echo .)us \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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