From: Rafael Darder Calvo <rdarder@spiralti.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: git-push error: Cannot write keep file
Date: Tue, 24 Feb 2009 19:21:42 -0200 [thread overview]
Message-ID: <49A464E6.3080802@spiralti.com> (raw)
In-Reply-To: <7v7i3fivx2.fsf@gitster.siamese.dyndns.org>
[-- Attachment #1: Type: text/plain, Size: 3222 bytes --]
Junio C Hamano wrote:
> Rafael Darder Calvo <rdarder@spiralti.com> writes:
>
>> Hello,
>> I am having the following error when I try to git push.
>>
>>
>> rdarder@shiny:~/Sources/promotoras$ git push origin ranto:ranto
>> Counting objects: 256, done.
>> Compressing objects: 100% (199/199), done.
>> Writing objects: 100% (213/213), 216.94 KiB, done.
>> Total 213 (delta 60), reused 1 (delta 0)
>>
>> fatal: cannot write keep file
>>
>> error: unpack failed: index-pack abnormal exit
>> To ssh://fherrero@10.7.1.20:2222/var/www/promotoras.git
>> ! [remote rejected] ranto -> ranto (n/a (unpacker error))
>> error: failed to push some refs to
>> 'ssh://fherrero@10.7.1.20:2222/var/www/promotoras.git'
>>
>>
>> I couldn't find any significant description on the error "cannot write
>> keep file". git-fsck passes without errors in both repositories, and I
>> find no permission problems. Can anyone give me some directions on how
>> to diagnose this?
>
> If you have access to the receiving side of the repository and the machine
> that hosts it, the debug patch attached may help.
>
> One possibility is the receiving repository was initialized long time ago
> with an ancient git (ealier than f49fb35 (git-init-db: create "pack"
> subdirectory under objects, 2005-06-27), and never had a packfile in it
> since then. We started creating '.git/objects/pack/' subdirectory in
> git-init only after that commit. It was Ok for a long time because we
> lazily create "pack" subdirectory as needed, but a recent change 8b4eb6b
> (Do not perform cross-directory renames when creating packs, 2008-09-22)
> carelessly assumed that .git/objects/pack/ directory would always exist
> and tries to create files in there without making sure the leading
> directories exist. See $gmane/110621
The receiving repository was indeed lacking a .git/objects/pack/
directory, but it was created with a recent (1.5.4.3) git version. I
suspect the repo owner has deleted de dir by mistake or something.
Thank you very much for your help.
>
> Subject: [PATCH] Make sure objects/pack exists before creating a new pack
> To: git@vger.kernel.org
> Date: Wed, 18 Feb 2009 20:48:07 -0800
> Message-ID: <7vr61vnibc.fsf@gitster.siamese.dyndns.org>
>
> for details.
>
> And the debug patch...
>
> index-pack.c | 8 ++++++--
> 1 files changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/index-pack.c b/index-pack.c
> index f7a3807..acdc85f 100644
> --- a/index-pack.c
> +++ b/index-pack.c
> @@ -802,14 +802,18 @@ static void final(const char *final_pack_name, const char *curr_pack_name,
> keep_fd = open(keep_name, O_RDWR|O_CREAT|O_EXCL, 0600);
> if (keep_fd < 0) {
> if (errno != EEXIST)
> - die("cannot write keep file");
> + die("cannot write keep file '%s' (%s)",
> + keep_name,
> + strerror(errno));
> } else {
> if (keep_msg_len > 0) {
> write_or_die(keep_fd, keep_msg, keep_msg_len);
> write_or_die(keep_fd, "\n", 1);
> }
> if (close(keep_fd) != 0)
> - die("cannot write keep file");
> + die("cannot close the written keep file '%s' (%s)",
> + keep_name,
> + strerror(errno));
> report = "keep";
> }
> }
>
>
>
>
>
[-- Attachment #2: rdarder.vcf --]
[-- Type: text/x-vcard, Size: 266 bytes --]
begin:vcard
fn:Rafael Darder Calvo
n:Darder Calvo;Rafael
org:;Infraestructura
adr:;;Mitre 1017 Piso 5;Rosario;Santa Fe;S2000COU;Argentina
email;internet:rdarder@spiralti.com
title:Spiralti Rosario
tel;work:+54 341 5302041
url:www.spiralti.com
version:2.1
end:vcard
next prev parent reply other threads:[~2009-02-24 21:23 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-24 17:04 git-push error: Cannot write keep file Rafael Darder Calvo
2009-02-24 17:31 ` Junio C Hamano
2009-02-24 21:21 ` Rafael Darder Calvo [this message]
2009-02-25 7:11 ` [PATCH v2] Make sure objects/pack exists before creating a new pack Junio C Hamano
2009-02-25 7:15 ` Junio C Hamano
2009-02-26 9:19 ` Johannes Sixt
2009-02-26 11:19 ` Mike Ralphson
2009-02-26 15:31 ` Johannes Sixt
2009-02-26 15:54 ` Mike Ralphson
2009-02-26 17:07 ` Junio C Hamano
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=49A464E6.3080802@spiralti.com \
--to=rdarder@spiralti.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/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;
as well as URLs for NNTP newsgroup(s).