[Solved] git push: “error: insufficient permission for adding an object to repository database ./objects”

Yeah, I know, this thing has been on here before, I’ve seen the questions.
git push gives me this:

error: insufficient permission for adding an object to repository database ./objects

I have just one question: Is this error regarding the local or the server-side repository database?

And why am I the only one getting this error among the developers?

(I’m asking this question because my server guy doesn’t want to believe me that this is a server-side problem)


Alright, here’s the long version:

Two users have pulled a rep into their workspace.

  1. User 2 pushes some change.
  2. User 1 changes something, commits, then pulls the change of User 2 to be merged.
  3. User 1 tries to push, but gets this:

    git.exe push –progress “origin” dev:dev

    Counting objects: 18, done.
    Compressing objects: 100% (10/10)
    Writing objects: 100% (10/10)
    Writing objects: 100% (10/10), 870 bytes, done.
    Total 10 (delta 6), reused 0 (delta 0)
    error: insufficient permission for adding an object to repository database ./objects

    fatal: failed to write object
    error: unpack failed: unpack-objects abnormal exit
    To [email protected]:twf
    ! [remote rejected] dev -> dev (n/a (unpacker error))
    error: failed to push some refs to ‘[email protected]:twf’

    git did not exit cleanly (exit code 1)

Solution #1:

Perhaps I didn’t get your question, but… you’re right, of course, there are several questions asked here about exactly the same. Let’s check this one, for example:

Usually this problem is caused by wrong user and group permissions on
your git servers file-system.

UPDATE: anyway, it’s actually quite easy to make the check who is to blame – your local environment or the server’s one. Let some other developer (but not user 2!) to make exactly the same update that you did (update the same files you did; it won’t be too hard, considering your report), then try to git push these updates from his/her machine.

Respondent: raina77ow

The answers/resolutions are collected from stackoverflow, are licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0 .

Leave a Reply

Your email address will not be published.