排查因调用同步原语(synchronization primitives)导致阻塞操作
使用前需要先调用 runtime.SetMutexProfileFraction。
在程序中,除了锁的争用会导致阻塞之外,很多逻辑都会导致阻塞。
...Before you can duplicate a repository and push to your new copy, or mirror, of the repository, you must create the new repository on GitHub. In these examples, exampleuser/new-repository or exampleuser/mirrored are the mirrors.
Open Terminal.
Create a bare clone of the repository.
$ git clone --bare https://github.com/exampleuser/old-repository.git
Mirror-push to the new repository.
$ cd old-repository.git
$ git push --mirror https://github.com/exampleuser/new-repository.git
Remove the temporary local repository you created earlier.
$ cd ..
$ rm -rf old-repository.git