git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Corruption: empty refs/heads in otherwise filled repo: cannot clone?
@ 2008-06-30  9:49 Jan Wielemaker
  2008-06-30 10:10 ` Jakub Narebski
  0 siblings, 1 reply; 10+ messages in thread
From: Jan Wielemaker @ 2008-06-30  9:49 UTC (permalink / raw)
  To: git

Hi,

I'm a bit puzzled. I have a bare repository, somehow without any files
in refs/heads.

It started using conversion from CVS via SVN using git-1.5.3.4. It is
configured for group access and there are a number of SSH accounts on
the machine in the proper group using git-shell for fellow developers. 

I never have any problems, but after upgrading to git-git (1.5.6.rc3)
fellow users get error:

error: no such remote ref refs/heads/JPL31
error: no such remote ref refs/heads/V57X
error: no such remote ref refs/heads/V5_4_patches
error: no such remote ref refs/heads/XML_UNICODE
error: no such remote ref refs/heads/attvar
error: no such remote ref refs/heads/gmp

Creating a new account and doing a fresh clone I even got the fatal
error there are no remote branches!? Still, using my own user id, I
could do anything I wanted. I checked permissions to see whether there
are differences between group and owner permissions, but couldn't find
anything suspicious.  git fsck --full on the repo gives no errors.

It turns out the directory refs/heads is empty!?

I made a fresh clone of the repo as myself, creating all references
nicely in refs/remotes/origin. Then I copied these files to refs/heads
into the main bare repository and now all appears to work nicely again.
Still, this is a bit worrying ...  My questions:

    * Is my work-around safe and sound?
    * How can this have happened?
    * Why can I clone as myself and not as anyone else!?  Stranger:
    after a "sudo -u <someone> /bin/bash" I could not clone.  I can
    copy the entire tree using cp -a, but I still cannot clone the
    copy with this user, while as myself I can clone the copy. 
    Somehow `as myself' appears to get the branchheads from somewhere.
    There is only one copy of git installed, so both users use the
    same.  What can cause this difference?

	Thanks --- Jan

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2008-06-30 19:56 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-30  9:49 Corruption: empty refs/heads in otherwise filled repo: cannot clone? Jan Wielemaker
2008-06-30 10:10 ` Jakub Narebski
2008-06-30 10:30   ` Jan Wielemaker
2008-06-30 11:26     ` Jakub Narebski
2008-06-30 11:44       ` Jan Wielemaker
2008-06-30 12:03         ` Jakub Narebski
2008-06-30 12:20           ` Jan Wielemaker
2008-06-30 19:33             ` Daniel Barkalow
2008-06-30 19:46               ` Jan Wielemaker
2008-06-30 11:50       ` Björn Steinbrink

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).