Skip to content

Trying to view Merge Request gives Server Error 500

Summary

I had closed the issue previously because it started working again...but it came back. Can't access Merge Request; GET request returns 500 error. I should add that this was working last week. I hadn't changed anything and this stopped working seemingly over the weekend for some reason.

Steps to reproduce

On my installation, it happens every time I click on a specific merge request.

What is the current bug behavior?

When clicking on a Merge Request, I am taken to a 500 error status page.

Relevant logs and/or screenshots

Looking at the production logs, the issue is the following:

Started GET "/group/project-name/merge_requests/1" for 192.168.1.1 at 2019-08-19 15:33:40 -0400
Processing by Projects::MergeRequestsController#show as HTML
Parameters: {"namespace_id"=>"namespace", "project_id"=>"project", "id"=>"1"}

Completed 500 Internal Server Error in 60ms (ActiveRecord: 4.7ms)

Rugged::OSError (failed stat - '/var/opt/gitlab/git-data/repositories/repo/project.git/objects/bf/190ea342b4f601edfboeu58dd707e998db14' is locked: Permission denied):

Output of checks

Results of GitLab environment info

Expand for output related to the GitLab environment info check
System information
System:	Ubuntu 16.04
Current User:	git
Using RVM:	no
Ruby Version:	2.6.3p62
Gem Version:	2.7.9
Bundler Version:1.17.3
Rake Version:	12.3.2
Redis Version:	3.2.12
Git Version:	2.21.0
Sidekiq Version:5.2.7
Go Version:	unknown

GitLab information Version: 12.1.6 Revision: 4016bcac51d Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: PostgreSQL DB Version: 10.7 URL: http://gitlab.company.com HTTP Clone URL: http://gitlab.company.com/some-group/some-project.git SSH Clone URL: git@gitlab.company.com:some-group/some-project.git Using LDAP: no Using Omniauth: yes Omniauth Providers:

GitLab Shell Version: 9.3.0 Repository storage paths: - default: /var/opt/gitlab/git-data/repositories GitLab Shell path: /opt/gitlab/embedded/service/gitlab-shell Git: /opt/gitlab/embedded/bin/git

Results of GitLab application Check

Expand for output related to the GitLab application check
Checking GitLab subtasks ...

Checking GitLab Shell ...

GitLab Shell: ... GitLab Shell version >= 9.3.0 ? ... OK (9.3.0) Running /opt/gitlab/embedded/service/gitlab-shell/bin/check Check GitLab API access: OK Redis available via internal API: OK

Access to /var/opt/gitlab/.ssh/authorized_keys: OK gitlab-shell self-check successful

Checking GitLab Shell ... Finished

Checking Gitaly ...

Gitaly: ... default ... OK

Checking Gitaly ... Finished

Checking Sidekiq ...

Sidekiq: ... Running? ... yes Number of Sidekiq processes ... 1

Checking Sidekiq ... Finished

Checking Incoming Email ...

Incoming Email: ... Reply by email is disabled in config/gitlab.yml

Checking Incoming Email ... Finished

Checking LDAP ...

LDAP: ... LDAP is disabled in config/gitlab.yml

Checking LDAP ... Finished

Checking GitLab App ...

Git configured correctly? ... yes Database config exists? ... yes All migrations up? ... yes Database contains orphaned GroupMembers? ... no GitLab config exists? ... yes GitLab config up to date? ... yes Log directory writable? ... yes Tmp directory writable? ... yes Uploads directory exists? ... yes Uploads directory has correct permissions? ... yes Uploads directory tmp has correct permissions? ... yes Init script exists? ... skipped (omnibus-gitlab has no init script) Init script up-to-date? ... skipped (omnibus-gitlab has no init script) Projects have namespace: ... 3/1 ... yes 3/2 ... yes 3/3 ... yes 3/4 ... yes 3/5 ... yes 3/6 ... yes 3/7 ... yes 3/8 ... yes 3/9 ... yes 3/10 ... yes 3/11 ... yes 3/12 ... yes 3/15 ... yes 3/16 ... yes 3/17 ... yes 3/18 ... yes 3/19 ... yes 3/20 ... yes 3/21 ... yes 3/22 ... yes 9/23 ... yes 3/24 ... yes 3/25 ... yes 3/26 ... yes 3/27 ... yes 3/28 ... yes 3/29 ... yes 3/30 ... yes 3/31 ... yes 3/33 ... yes 3/34 ... yes 11/35 ... yes 3/36 ... yes 3/38 ... yes 3/39 ... yes 3/40 ... yes 11/41 ... yes 11/42 ... yes 11/43 ... yes 11/44 ... yes 11/45 ... yes 11/46 ... yes 3/47 ... yes 3/49 ... yes 3/50 ... yes 11/51 ... yes 3/52 ... yes 3/53 ... yes 11/54 ... yes 11/55 ... yes 3/56 ... yes 11/57 ... yes 11/58 ... yes 11/59 ... yes 11/60 ... yes 11/61 ... yes 3/62 ... yes 3/63 ... yes 3/64 ... yes 3/66 ... yes 3/67 ... yes 3/68 ... yes 3/69 ... yes 3/70 ... yes 3/71 ... yes 3/72 ... yes 3/73 ... yes 3/74 ... yes 3/75 ... yes 3/76 ... yes 3/77 ... yes 3/78 ... yes 3/79 ... yes 3/80 ... yes 11/81 ... yes 3/82 ... yes 20/83 ... yes 3/84 ... yes 11/85 ... yes 11/86 ... yes 11/87 ... yes 3/88 ... yes 11/89 ... yes 3/90 ... yes 15/91 ... yes 15/92 ... yes 15/93 ... yes 15/94 ... yes 3/95 ... yes 20/96 ... yes 15/97 ... yes 15/98 ... yes 3/99 ... yes 15/100 ... yes 3/101 ... yes 2/102 ... yes 3/103 ... yes 3/104 ... yes 11/105 ... yes 3/106 ... yes 3/107 ... yes 20/108 ... yes 11/109 ... yes 3/110 ... yes 15/111 ... yes 16/112 ... yes 3/114 ... yes 3/115 ... yes 18/116 ... yes 3/117 ... yes 3/118 ... yes 3/119 ... yes 11/120 ... yes 3/121 ... yes 3/122 ... yes 3/124 ... yes 3/125 ... yes 3/126 ... yes 3/127 ... yes 3/128 ... yes 3/129 ... yes 11/130 ... yes 13/131 ... yes 18/132 ... yes 3/133 ... yes 18/134 ... yes Redis version >= 2.8.0? ... yes Ruby version >= 2.5.3 ? ... yes (2.6.3) Git version >= 2.21.0 ? ... yes (2.21.0) Git user has default SSH configuration? ... yes Active users: ... 7

Checking GitLab App ... Finished

Checking GitLab subtasks ... Finished

Possible fixes

Seems like it occurs in: Projects::MergeRequestsController#show as HTML And the error seems to be: Rugged::OSError (failed stat - '/var/opt/gitlab/git-data/repositories/repo/project.git/objects/bf/sha1' is locked: Permission denied

gitlab-ce2278648 gitlab-ce9789536

Edited by Chris Leyva