Git/GitHub connection issue on VM/VirtualBox

可紊 提交于 2019-12-11 06:23:12

问题


I cannot connect my Git repository on GitHub from my VM (VirtualBox / Debian):

# git clone git@github.com:username/reponame.git .
Cloning into ....
ssh: Could not resolve hostname github.com: Name or service not known
fatal: The remote end hung up unexpectedly

Then I added an entry for GitHub to my /etc/hosts (it will be the wrong way -- don't believe, that it is always necessary):

207.97.227.239  github.com

Now I'm getting another error:

# git clone git@github.com:username/reponame.git .
Cloning into ....
ssh: connect to host github.com port 22: Connection timed out
fatal: The remote end hung up unexpectedly

We would be very grateful for your your help!


回答1:


looks like you dont have any internet access...



来源:https://stackoverflow.com/questions/15117564/git-github-connection-issue-on-vm-virtualbox

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!