在Windows Server 2012从机上运行Jenkins,任务成功从Bitbucket获取数据,该仓库位于防火墙内部。其最后一个任务是在刚检查出来的更改上执行“git rev-list”命令。这个命令需要大约8分钟才能完成。这是可重复的;这是一个相对较新的环境,我没有历史记录来查看是否是刚开始的问题。
在我们的生产环境中,Jenkins本身在Windows上运行而没有从机(已经有2年了),同样的rev-list命令只需要3秒钟就能完成。
我已经看到了几个关于“git fetch挂起”的参考资料,但对我来说不是fetch挂起 - 鉴于项目的大小,它在合理的时间内完成了。
时间戳日志如下。
在我们的生产环境中,Jenkins本身在Windows上运行而没有从机(已经有2年了),同样的rev-list命令只需要3秒钟就能完成。
我已经看到了几个关于“git fetch挂起”的参考资料,但对我来说不是fetch挂起 - 鉴于项目的大小,它在合理的时间内完成了。
时间戳日志如下。
00:00:00.001 Started by user #####
00:00:00.002 Building remotely on JS-W-01 (msvs ishield win) in workspace c:\jenkins\workspace\MyProject\2.7.11_nightly@2
00:00:00.015 [TemplateProject] Using SCM from: MyProject � 2.7.11_Template
00:00:00.044 Cloning the remote Git repository
00:00:00.049 Cloning repository ssh://vdn-bitbucket:7999/myprojectcore.git
00:00:00.052 > git init c:\jenkins\workspace\MyProject\2.7.11_nightly@2 # timeout=10
00:00:00.153 Fetching upstream changes from ssh://vdn-bitbucket:7999/myprojectcore.git
00:00:00.154 > git --version # timeout=10
00:00:00.200 using GIT_SSH to set credentials Jenkins Builder vdnbuild-bb SSH access key
00:00:00.210 > git fetch --tags --progress ssh://vdn-bitbucket:7999/myprojectcore.git +refs/heads/*:refs/remotes/origin/*
00:00:22.857 > git config remote.origin.url ssh://vdn-bitbucket:7999/myprojectcore.git # timeout=10
00:00:22.911 > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
00:00:22.967 > git config remote.origin.url ssh://vdn-bitbucket:7999/myprojectcore.git # timeout=10
00:00:23.023 Fetching upstream changes from ssh://vdn-bitbucket:7999/myprojectcore.git
00:00:23.023 using GIT_SSH to set credentials Jenkins Builder vdnbuild-bb SSH access key
00:00:23.028 > git fetch --tags --progress ssh://vdn-bitbucket:7999/myprojectcore.git +refs/heads/*:refs/remotes/origin/*
00:00:23.641 > git rev-parse "refs/remotes/origin/release/2.7.11^{commit}" # timeout=10
00:00:23.697 > git rev-parse "refs/remotes/origin/origin/release/2.7.11^{commit}" # timeout=10
00:00:23.748 Checking out Revision fb773fc64875f5d457bc255088fcec4df3028216 (refs/remotes/origin/release/2.7.11)
00:00:23.752 > git config core.sparsecheckout # timeout=10
00:00:23.799 > git checkout -f fb773fc64875f5d457bc255088fcec4df3028216
00:02:21.725 Commit message: "Merge pull request #30 in MYPROJECT/core from bugfix/MYPROJECT-19 to release/2.7.11"
00:02:21.730 > git rev-list fb773fc64875f5d457bc255088fcec4df3028216 # timeout=10
00:10:50.813 [TemplateProject] Starting builders from: MyProject � 2.7.11_Template
00:10:50.827 [2.7.11_nightly@2] $ cmd /c call C:\Windows\TEMP\jenkins7743297501210902154.bat
00:10:50.853
执行环境:
Jenkins 2.86 运行在 Centos 7 上;Git 插件版本为 3.6.2(也出现在3.6.0)
从机运行于 Windows Server 2012 R2 Standard,slave.jar 版本为 3.7。
Git 版本为 2.14.3(也出现在 2.10.0)