3

I'm setting up a Gitlab on a Debian Server 6.4

When executing this:

root@Gitlab:/home/git/gitlab# sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production

Output

Checking Environment ...

Git configured for git user? ... yes
Has python2? ... yes
python2 is supported version? ... yes

Checking Environment ... Finished

Checking Gitlab Shell ...

GitLab Shell version? ... FAIL. Please update gitlab-shell to v1.1.0
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
post-receive hook up-to-date? ... yes
post-receive hooks in repos are links: ... rake aborted!
Mysql2::Error: Table 'gitlabhq_production.projects' doesn't exist: SHOW FULL FIELDS FROM `projects`
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:245:in `query'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:245:in `block in execute'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_adapter.rb:280:in `block in log'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_adapter.rb:275:in `log'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:245:in `execute'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/mysql2_adapter.rb:211:in `execute'
/home/git/gitlab/config/initializers/connection_fix.rb:22:in `execute'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:259:in `execute_and_free'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:426:in `columns'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/connection_adapters/schema_cache.rb:12:in `block in initialize'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/model_schema.rb:228:in `yield'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/model_schema.rb:228:in `default'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/model_schema.rb:228:in `columns'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/model_schema.rb:248:in `column_names'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/relation/calculations.rb:221:in `aggregate_column'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/relation/calculations.rb:242:in `execute_simple_calculation'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/relation/calculations.rb:216:in `perform_calculation'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/relation/calculations.rb:159:in `calculate'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/relation/calculations.rb:58:in `count'
/home/git/gitlab/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/querying.rb:12:in `count'
/home/git/gitlab/lib/tasks/gitlab/check.rake:489:in `check_repos_post_receive_hooks_is_link'
/home/git/gitlab/lib/tasks/gitlab/check.rake:357:in `block (3 levels) in '
Tasks: TOP => gitlab:check => gitlab:gitlab_shell:check
(See full trace by running task with --trace)

I'm stuck at this part: GitLab Shell version? ... FAIL. Please update gitlab-shell to v1.1.0

Version 1.2.0 is installed. Could anybody help how to fix this?

I am following this guide: https://github.com/gitlabhq/gitlabhq/blob/5-0-stable/doc/install/installation.md

0

2 Answers 2

1

Go to /home/git/gitlab-shell and change the version in the VERSION file to 1.1.0, it feels very wrong to me but it works.

I have seen that the version was updated only 3 days ago so it probably has not been fixed yet. Reckon there is code checked for explicit 1.1.0 version and the recent check in on gitlab-shell has broken this.

Hope this helps, but be on the look out for a gitlab update to support this as this fix is not ideal.

Thanks

1

I would not recommend changing the gitlab-shell version number as stated in @Noel King's answer (the correct version of gitlab-shell is 1.2.0).

Instead, you should update check.rake to look for the correct version of gitlab-shell.

To do this:

  1. Edit /home/git/gitlab/lib/tasks/gitlab/check.rake
  2. On line 640, change

    if gitlab_shell_version.strip == '1.1.0'

    to

    if gitlab_shell_version.strip == '1.2.0'
  3. You can also update lines 641 and 643 to reflect the correct versions in the success/error messages
  4. Re-run sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production to verify the issue is fixed

This issue has already been corrected in the main repo, but wasn't included in the 5.0 stable release.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.