{"id":1076,"date":"2023-07-30T19:01:48","date_gmt":"2023-07-30T18:01:48","guid":{"rendered":"https:\/\/www.kolkataonweb.com\/code-bank\/?p=1076"},"modified":"2023-07-30T19:03:57","modified_gmt":"2023-07-30T18:03:57","slug":"self-hosted-gitlab-and-500-error","status":"publish","type":"post","link":"https:\/\/www.kolkataonweb.com\/code-bank\/miscellaneous\/self-hosted-gitlab-and-500-error\/","title":{"rendered":"Self hosted Gitlab and 500 error"},"content":{"rendered":"<p>In my case the 500 error started after migration to new server. Everything was done as per the official guide. The server started fine, the repositories, comments, issues also showed fine. The problem &#8211; on clicking a repository it showed 500 error.<\/p>\n<p>Checking the error logs (under \/var\/log\/gitlab\/) didn&#8217;t reveal the problem. The best way to check Gitlab logs is to use the command &#8211;<\/p>\n<pre class='wp-code-highlight prettyprint'><code class=\"lang-bash hljs language-bash\">gitlab-ctl <span class=\"hljs-built_in\">tail<\/span><\/code><\/pre>\n<p>Checking the logs with the above command revealed a permission issue in these folders<\/p>\n<pre class='wp-code-highlight prettyprint'>drwxr-sr-x 5 git git 4096 Jul 30 22:29 <span style=\"color: #0000ff;\">\/mnt\/repo_storage2\/git-data\/repositories\/+gitaly<\/span>\r\ndrwxr-s--- 250 git git 4096 Jul 5 16:20 <span style=\"color: #0000ff;\">\/mnt\/repo_storage2\/git-data\/repositories\/@hashed<\/span>\r\ndrwxr-sr-x 9 git git 4096 Jul 17 20:18 <span style=\"color: #0000ff;\">\/mnt\/repo_storage2\/git-data\/repositories\/@pools<\/span><\/pre>\n<p>Don&#8217;t know why\/how &#8220;<span style=\"color: #0000ff;\">git-redis<\/span>&#8221; became the owner of the subfolders. Changing the owner to &#8220;<span style=\"color: #0000ff;\">git<\/span>&#8221; solved the 500 error.<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In my case the 500 error started after migration to new server. Everything was done as per the official guide. The server started fine, the repositories, comments, issues also showed fine. The problem &#8211; on clicking a repository it showed 500 error. Checking the error logs (under \/var\/log\/gitlab\/) didn&#8217;t reveal the problem. The best way&hellip; <a class=\"more-link\" href=\"https:\/\/www.kolkataonweb.com\/code-bank\/miscellaneous\/self-hosted-gitlab-and-500-error\/\">Continue reading <span class=\"screen-reader-text\">Self hosted Gitlab and 500 error<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[377,409,379,380],"class_list":["post-1076","post","type-post","status-publish","format-standard","hentry","category-miscellaneous","tag-gitlab","tag-gitlab-500-error","tag-gitlab-community-edition","tag-gitlab-self-hosted","entry"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/posts\/1076","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/comments?post=1076"}],"version-history":[{"count":4,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/posts\/1076\/revisions"}],"predecessor-version":[{"id":1080,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/posts\/1076\/revisions\/1080"}],"wp:attachment":[{"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/media?parent=1076"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/categories?post=1076"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.kolkataonweb.com\/code-bank\/wp-json\/wp\/v2\/tags?post=1076"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}