这是我的第一个问题,所以我让GitLab在我的一台服务器上工作,但是最近我无法访问我的gitlab,因为502错误说“花太多时间来回应”。
我的gitlab上有大约50个用户。当我的一个用户访问他的最后两次提交时,独角兽开始使用100%的CPU并且不允许其他任何人工作,因此gitlab停止工作。其他一切都在发挥作用。每个人都可以看到他们的提交,但是当访问这个提交时,我需要重新启动gitlab以使其再次运行。
Gitlab安装在具有10GB空间的分区上,仅剩500MB,2GB内存和1GB交换。 1vCPU(AWS实例)
我的配置是:
System information
System: CentOS 6.7
Current User: git
Using RVM: no
Ruby Version: 2.1.8p440
Gem Version: 2.5.1
Bundler Version:1.11.2
Rake Version: 10.5.0
Sidekiq Version:4.0.1
GitLab information
Version: 8.4.3
Revision: eb6f691
Directory: /opt/gitlab/embedded/service/gitlab-rails
DB Adapter: postgresql
URL: http://git.mydomain.lol
HTTP Clone URL: http://git.mydomain.lol/some-group/some-project.git
SSH Clone URL: [email protected]:some-group/some-project.git
Using LDAP: no
Using Omniauth: no
GitLab Shell Version: 2.6.10
Repositories: /projects/git-data/repositories
Hooks: /opt/gitlab/embedded/service/gitlab-shell/hooks/
Git: /opt/gitlab/embedded/bin/git
日志中没有任何东西,除了独角兽杀手超过内存限制的独角兽。
所以,如果您需要更多细节,请随时问我会为您提供什么,
感谢帮助 !
我同意升级到最新的稳定版本是一个很好的起点。我遇到了同样的问题 - 持续的sidekiq作业导致100%的CPU消耗。我让GitLab运行8GB RAM和4个CPU。对于我的16位用户来说,这应该已经足够了。从9.1升级到9.2(源代码安装)之后,sidekiq进程停止占用我所有的RAM和CPU,一切都很好。我认为这是因为你清理了旧宝石并清除了Ruby缓存作为更新过程的一部分。
如需更深入的故障排除,请查看GitLab's recommended tools。