#2959 Git repository : Could not read from remote repository

self-service
Chris Tsai
git (47)
2014-08-28
2013-02-28
Emmanuel Guyot
No

Hi,

I've previously opened a ticket which has been closed too early : #1448 New GIT repository "not found"
I'm still having problem with my git repository.

Here are a few of my tries :

1) Trying to clone my fresh new repository
$ git clone ssh://emmguyot@git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source
Cloning into 'beauty-hair-mng-source'...
fatal: Could not read from remote repository.

Please make sure you have the correct access rights and the repository exists.

2) Trying to create an minimalist repository as stated in the page https://sourceforge.net/p/beauty-hair-mng/source/ref/master~/
$ git push origin master
fatal: Could not read from remote repository.

Please make sure you have the correct access rights and the repository exists.

3) I've tried to delete the repository from the admin panel and to create one afterwards. No change

To sum up : My git repository in not usable at all. Please help me.

Discussion

  • Emmanuel Guyot
    Emmanuel Guyot
    2013-02-28

    As I'm still trying to make git works, here are a few more tries I've made :

    4) I've tried to create the git repository from a SourceForge shell in /home/scm_git/beauty-hair-mng/beauty-hair-mng using the "Creating Multiple Repositories" instructions on https://sourceforge.net/apps/trac/sourceforge/wiki/Git

    No change

    5) I've uploaded my local repository I've created from the SVN repository. It is now in /home/scm_git/beauty-hair-mng/beauty-hair-mng
    I still can't clone the repository with :
    $ git clone ssh://emmguyot@beauty-hair-mng.git.sourceforge.net/gitroot/beauty-hair-mng/beauty-hair-mng beauty-hair-mng-source
    Cloning into 'beauty-hair-mng-source'...
    fatal: Could not read from remote repository.

    Please make sure you have the correct access rights and the repository exists.

    BUT I can clone it anonymously with
    $ git clone git://beauty-hair-mng.git.sourceforge.net/gitroot/beauty-hair-mng/b
    eauty-hair-mng beauty-hair-mng-source
    Cloning into 'beauty-hair-mng-source'...
    remote: Counting objects: 6526, done.
    remote: Compressing objects: 100% (6330/6330), done.
    remote: Total 6526 (delta 4116), reused 0 (delta 0)
    Receiving objects: 100% (6526/6526), 31.91 MiB | 444 KiB/s, done.
    Resolving deltas: 100% (4116/4116), done.
    Checking out files: 100% (2712/2712), done.

    So it seems that the problem is about my authentication. How can I check this ?
    Please note that if I do direct ssh access, it seems that the authentication is fine.
    $ ssh -l emmguyot beauty-hair-mng.git.sourceforge.net
    fatal: Interactive git shell is not enabled.
    hint: ~/git-shell-commands should exist and have read and execute access.
    Connection to beauty-hair-mng.git.sourceforge.net closed.

    $ ssh -l emmguyot beauty-hair-mng.git.sourceforge.net ls -al
    fatal: unrecognized command 'ls -al'

     
  • Chris Tsai
    Chris Tsai
    2013-02-28

    For 4 & 5, those both reference the classic SourceForge system, not the new SourceForge system your project is on. That said, let's assume that you see the same behavior with git.code.sf.net as you do with beauty-hair-mng.git.sourceforge.net

    I do not think it is a problem with the repository itself as I can get a clone of it without issue, eg.:

    $ git clone ssh://ctsai@git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source
    Cloning into 'beauty-hair-mng-source'...
    warning: You appear to have cloned an empty repository.
    $
    

    On the authentication front, can you clarify how you're authenticating? I'm assuming it's an ssh key, as I don't see a password prompt in your error messages. But, if it were an authentication problem, I'd expect a "Too many authentication failures" error message or something like that.

    If we rule out a problem with the repository itself, and we rule out authentication, then it seems to me that the most likely culprit would be the git client, or possibly how your computer or network is handling ssh connections.

    Perhaps it would be worthwhile to try other protocols, for read-only, we also support git:// and http:// and for read/write, we support https://

    eg.,

    $ git clone git://git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source-git
    Cloning into 'beauty-hair-mng-source-git'...
    warning: You appear to have cloned an empty repository.
    
    $ git clone http://git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source-http
    Cloning into 'beauty-hair-mng-source-http'...
    warning: You appear to have cloned an empty repository.
    
    $ git clone https://ctsai@git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source-https
    Cloning into 'beauty-hair-mng-source-https'...
    Password for 'https://ctsai@git.code.sf.net': 
    warning: You appear to have cloned an empty repository.
    $
    

    Regards,
    Chris Tsai, SourceForge.net Support

     
  • Chris Tsai
    Chris Tsai
    2013-02-28

    • status: unread --> pending
    • assigned_to: Chris Tsai
     
  • Emmanuel Guyot
    Emmanuel Guyot
    2013-02-28

    Hi,

    Thanks for your answer.

    Ok, first I haven't noticed the differences between the 2 hosts git.code.sf.net and beauty-hair-mng.git.sourceforge.net. Does it mean that the folder /home/scm_git/beauty-hair-mng/beauty-hair-mng on your server is for old fashioned project and that I can remove the content I've put in ? Where is the new folder ?

    I've tried the fourth clone method :

    $ git clone ssh://emmguyot@git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source2
    Cloning into 'beauty-hair-mng-source2'...
    fatal: Could not read from remote repository.
    
    Please make sure you have the correct access rights and the repository exists.
    
    $ git clone git://git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source-git
    Cloning into 'beauty-hair-mng-source-git'...
    warning: You appear to have cloned an empty repository.
    
    $ git clone http://git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source-http
    Cloning into 'beauty-hair-mng-source-http'...
    warning: You appear to have cloned an empty repository.
    
    $ git clone https://emmguyot@git.code.sf.net/p/beauty-hair-mng/source beauty-hair-mng-source-https
    Cloning into 'beauty-hair-mng-source-https'...
    Password for 'https://emmguyot@git.code.sf.net':
    warning: You appear to have cloned an empty repository.
    

    So it seems that it my ssh layer that have a problem. As I'd prefer to user ssh authentication and that I'd like to understand where the problem is, I need hint to solve them.
    Here are the versions I use from my Windows desktop :

    $ git --version
    git version 1.8.0.msysgit.0
    
    $ ssh -v
    OpenSSH_4.6p1, OpenSSL 0.9.8e 23 Feb 2007
    

    Do you see a problem with these versions ?

     
  • Chris Tsai
    Chris Tsai
    2013-02-28

    When you're in the shell service, you can use sf-help --scm to tell you the paths of your repositories (both new and old systems).

    As for your git ssh issue, I don't have much experience with git on windows myself, but perhaps the GIT_SSH environment variable isn't set correctly?

    Regards,
    Chris Tsai, SourceForge.net Support

     
  • Emmanuel Guyot
    Emmanuel Guyot
    2013-02-28

    Thank you Chris!

    My GIT_SSH was pointing to plink.exe
    I've unset the variable and now I can clone the repository through ssh.
    I'm currently push my local repository !! Great.

    You can close this ticket.

     
  • Chris Tsai
    Chris Tsai
    2013-02-28

    • status: pending --> self-service
     
  • Chris Tsai
    Chris Tsai
    2013-02-28

    Excellent, thanks for the update.

    Best regards,
    Chris Tsai, SourceForge.net Support