Git error: Insufficient permission for adding a object to repository database. git/objects

Source: Internet
Author: User

After building the GIT server locally, push the new code on the development machine and discover the GIT hint:

Insufficient permission for adding a object to repository database. git/objects

This occurs because there is no write permission on the directory where the repository resides, causing the new file to not be uploaded.

So note that in the use

sudo git init--bare xx.git

After you create a repository, you need to adjust the permissions, otherwise you will need root permission when you create it with sudo.

To change the permissions command for the Xx.git repository:

sudo chown-r user:group xx.git

Git error: Insufficient permission for adding a object to repository database. git/objects

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.