Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Hi i cloned a local repository on another server http://localipaddress/git/project . It created an empty repository. When i tried to pull from the repository, it gave me an error

Your configuration specifies to merge with the ref 'master' from the remote but no such ref was detected.

On push i get the following message

error:Cannot access url "http://localipaddress/git/project" , return code 22 . Fatal git-http-push failed

What could have been wrong.

share|improve this question
up vote 3 down vote accepted

The issue is resolved. In mycase , it just worked out using the following url while cloning

http://username:password@localipaddress/git/project ,
instead of http://localipaddress/git/project.

May be some issue with the way username/pwds are handled by the repsoitory.

also in the .git/config file, need to check whether the following details are present

[remote "origin"]
    url = http://username:password@localipaddress/git/project 
    fetch = +refs/heads/*:refs/remotes/origin/*

[branch "master"]
    remote = origin
    merge = refs/heads/master
share|improve this answer
In my case, supplying the username was enough, storing the password in not necessary. So the URL gets username@localipaddress/git/project and the password will then be demanded later on. – Joma May 6 '14 at 13:54

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.