2017-06-23 48 views
-1

我無法使用eclipse克隆Git存儲庫。我得到了以下錯誤:如何在Eclipse下處理「https://gxxxx.com/xxxxx/xxxx.git:無法打開git-upload-pack」?

https://gxxxx.com/xxxxx/xxxx.git : cannot open git-upload-pack"

堆棧跟蹤:

org.eclipse.jgit.api.errors.TransportException: https://gitlab.com/induction/trainingplan.git: cannot open git-upload-pack 
    at org.eclipse.jgit.api.LsRemoteCommand.call(LsRemoteCommand.java:196) 
    at org.eclipse.egit.core.op.ListRemoteOperation.run(ListRemoteOperation.java:99) 
    at org.eclipse.egit.ui.internal.clone.SourceBranchPage$8.run(SourceBranchPage.java:324) 
    at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) 
Caused by: org.eclipse.jgit.errors.TransportException: https://gitlab.com/induction/trainingplan.git: cannot open git-upload-pack 
    at org.eclipse.jgit.transport.TransportHttp.connect(TransportHttp.java:499) 
    at org.eclipse.jgit.transport.TransportHttp.openFetch(TransportHttp.java:308) 
    at org.eclipse.jgit.api.LsRemoteCommand.call(LsRemoteCommand.java:175) 
    ... 3 more 
Caused by: java.net.UnknownHostException: gitlab.com 
    at java.net.AbstractPlainSocketImpl.connect(Unknown Source) 
    at java.net.PlainSocketImpl.connect(Unknown Source) 
    at java.net.SocksSocketImpl.connect(Unknown Source) 
    at java.net.Socket.connect(Unknown Source) 
    at sun.security.ssl.SSLSocketImpl.connect(Unknown Source) 
    at sun.net.NetworkClient.doConnect(Unknown Source) 
    at sun.net.www.http.HttpClient.openServer(Unknown Source) 
    at sun.net.www.http.HttpClient.openServer(Unknown Source) 
    at sun.net.www.protocol.https.HttpsClient.<init>(Unknown Source) 
    at sun.net.www.protocol.https.HttpsClient.New(Unknown Source) 
    at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(Unknown Source) 
    at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(Unknown Source) 
    at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source) 
    at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source) 
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source) 
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source) 
    at java.net.HttpURLConnection.getResponseCode(Unknown Source) 
    at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(Unknown 

    Source) 

可以做些什麼治癒的情況呢?

回答

3

真正原因隱藏背後:

Caused by: java.net.UnknownHostException: gitlab.com

這是告訴你,你已經在當下下線了你試圖解決的gitlab.com或者您當地的互聯網的DNS(網關或DNS服務器)配置錯誤/無法正常工作。

重新連接到互聯網(或檢查代理設置),然後再次嘗試檢出所需的git存儲庫。

希望它有幫助。