简体   繁体   English

为什么没有使用git协议来克隆项目的响应?

[英]Why there is no response using git protocol to clone project?

I try to clone a Linux branch from git://git.kernel.org to local machine: 我尝试将一个Linux分支从git://git.kernel.org到本地机器:

# git clone git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux -b perf/core
Cloning into 'linux'...

But there is no response. 但是没有回应。 Use the tcpdump and Wireshark to check the captured packets: 使用tcpdumpWireshark检查捕获的数据包:
在此输入图像描述 We can see the TCP connection was established. 我们可以看到TCP连接已建立。 But after client sent request using git smart protocol , there was no any response. 但是在客户端使用git smart protocol发送请求后,没有任何响应。

Could anyone give some clues? 谁能提供一些线索?

Update: 更新:
(1) According to @MariaInesParnisari suggestion, using --verbose flag, but it doesn't show more information: (1)根据@MariaInesParnisari的建议,使用--verbose标志,但它没有显示更多信息:

# git clone git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux -b perf/core --verbose
Cloning into 'linux'...
Looking up git.kernel.org ... done.
Connecting to git.kernel.org (port 9418) ... 147.75.110.187 done.

(2) Change to https protocol, it worked: (2)改为https协议,它有效:

# git clone https://git.kernel.org/pub/scm/linux/kernel/git/acme/linux -b perf/core --verbose
Cloning into 'linux'...
POST git-upload-pack (gzip 25015 to 12570 bytes)
remote: Counting objects: 5287534, done.
remote: Compressing objects: 100% (807310/807310), done.

I never managed to clone from work using the git protocol: it uses the special port 9418, which is always blocked. 我从未设法使用git协议克隆工作:它使用特殊端口9418,它始终被阻止。

Only https is working/allowed, git and ssh are usually blocked (for outbound connections, since ssh is allowed for servers within the intranet) 只有https正在工作/允许,git和ssh通常被阻止(对于出站连接,因为内部网中的服务器允许ssh)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM