markdown git挂起疑难解答代码段

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了markdown git挂起疑难解答代码段相关的知识,希望对你有一定的参考价值。

My git seems to be hanging on fetch, pull, push -- whenever I have to contact the server.

Here are some debugging commands:

`GIT_TRACE=true git <git_command>`   
ex: `GIT_TRACE=true git pull`


`ssh -p <port_number> <ssh_server_address> -vvv`
ex: `ssh -p 2222 codeserver.dev.3045b28f-3744-4318-97bf-66726e6b63ac@codeserver.dev.3045b28f-3744-4318-97bf-66726e6b63ac.drush.in -vvv`


```bash
$ GIT_TRACE=true git pull
11:38:49.761048 git.c:415               trace: built-in: git pull
11:38:49.943156 run-command.c:637       trace: run_command: git fetch --update-head-ok
11:38:49.949872 git.c:415               trace: built-in: git fetch --update-head-ok
11:38:49.951192 run-command.c:637       trace: run_command: unset GIT_PREFIX; ssh -p 2222 codeserver.dev.3045b28f-3744-4318-97bf-66726e6b63ac@codeserver.dev.3045b28f-3744-4318-97bf-66726e6b63ac.drush.in 'git-upload-pack '\''~/repository.git'\'''
^C
```

It hangs there indefinitely. Looks as though something might be wrong with my ssh connection? So try to ssh into the server in verbose mode:

```bash
 ssh -p 2222 codeserver.dev.3045b28f-3744-4318-97bf-66726e6b63ac@codeserver.dev.3045b28f-3744-4318-97bf-66726e6b63ac.drush.in -vvv
OpenSSH_7.7p1, LibreSSL 2.7.3
debug1: Reading configuration data /Users/noxlady/.ssh/config
debug1: /Users/noxlady/.ssh/config line 10: Applying options for *
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 48: Applying options for *
debug2: ssh_connect_direct: needpriv 0
debug1: Connecting to codeserver.dev.3045b28f-3744-4318-97bf-66726e6b63ac.drush.in port 2222.
^C
```
Yeah, it hangs there. At first the only thing I could do was restart!!! But then I realized that activating my VPN fixed the problem :)

以上是关于markdown git挂起疑难解答代码段的主要内容,如果未能解决你的问题,请参考以下文章

markdown Git代码片段

基与SVN和GIT的各大代码托管服务站点分析与比较

markdown 在macOS Mojave上,rbenv install 2.6.1挂起“使用来自homebrew的realline”

markdown 奇怪的是“git没有干净地退出(退出代码1)”

Git疑难解决

UI 挂起,直到完成所有提取