gitlab 6.7.5 gollum wiki gives error 500 (with solution)
Gitlab 6.7.5 wiki page gives error 500 instead of wiki editing page.
The wiki page on the web gui gave error 500 every time I clicked it on the project page of Gitlab web gui (6.7.5). Whether the project was empty or not, didn't matter. I've found, based on the production.log, that there was an incorrect line in /home/git/gitlab/app/models/gollum_wiki.rb
, and modifying it solved the issue.
Line 44 of the file originaly contained:
rescue Grit::NoSuchPathError
I've changed it to:
rescue Gollum::NoSuchPathError
And now the wiki page works as it should.
production.log output of the error:
Started GET "/$username/$project/wikis/home" for $ip at $time
Processing by Projects::WikisController#show as HTML
Parameters: {"project_id"=>"$username/$project", "id"=>"home"}
Completed 500 Internal Server Error in 82ms
Gollum::NoSuchPathError (Gollum::NoSuchPathError):
app/models/gollum_wiki.rb:43:in `new'
app/models/gollum_wiki.rb:43:in `wiki'
app/controllers/projects/wikis_controller.rb:72:in `load_gollum_wiki'
app/controllers/application_controller.rb:58:in `set_current_user_for_thread'
System information
System: CentOS 6.5
Current User: git
Using RVM: yes
RVM Version: 1.25.22
Ruby Version: 2.1.1p76
Gem Version: 2.2.2
Bundler Version:1.6.2
Rake Version: 10.1.1
GitLab information
Version: 6.7.5
Revision: 00aa5c1
DB Adapter: mysql2
Using LDAP: no
Using Omniauth: no
GitLab Shell
Version: 1.9.3
I also use nginx, altough I don't think it's relevant.
Gitlab check:
Checking Environment ...
Git configured for git user? ... yes
Checking Environment ... Finished
Checking GitLab Shell ...
GitLab Shell version >= 1.9.1 ? ... OK (1.9.3)
Repo base directory exists? ... yes
Repo base directory is a symlink? ... no
Repo base owned by git:git? ... yes
Repo base access is drwxrws---? ... yes
update hook up-to-date? ... yes
update hooks in repos are links: ... yes
Running /home/git/gitlab-shell/bin/check
Check GitLab API access: OK
Check directories and files:
/home/git/repositories: OK
/home/git/.ssh/authorized_keys: OK
Test redis-cli executable: redis-cli 2.4.10
Send ping to redis server: PONG
gitlab-shell self-check successful
Checking GitLab Shell ... Finished
Checking Sidekiq ...
Running? ... yes
Number of Sidekiq processes ... 1
Checking Sidekiq ... Finished
Checking LDAP ...
LDAP is disabled in config/gitlab.yml
Checking LDAP ... Finished
Checking GitLab ...
Database config exists? ... yes
Database is SQLite ... no
All migrations up? ... yes
Database contains orphaned UsersGroups? ... no
GitLab config exists? ... yes
GitLab config outdated? ... no
Log directory writable? ... yes
Tmp directory writable? ... yes
Init script exists? ... yes
Init script up-to-date? ... yes
projects have namespace: ... yes
Projects have satellites? ... yes
Redis version >= 2.0.0? ... yes
Your git bin path is "/usr/bin/git"
Git version >= 1.7.10 ? ... yes (1.7.12)
Checking GitLab ... Finished
(I have removed a few lines from the check which included projectnames and usernames, but there were no errors in any of them)