"Can't save project. Please try again later" Centos 5.10 -- logs included below
Closed
"Can't save project. Please try again later" Centos 5.10 -- logs included below
Created by: xEtherealx
I get the message "Can't save project. Please try again later" when trying to create a project (as administrator) on Centos 5.10. I know, crusty distro... are there other logs and/or debug steps that I can look into?
Here's my info/log dump:
bundle exec rake gitlab:env:info RAILS_ENV=production
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /opt/gitlab-6.4.0.pre2-0/apps/gitlab/htdocs/Rakefile:7)
System information
System: CentOS 5.10
Current User: git
Using RVM: no
Ruby Version: 1.9.3p484
Gem Version: 1.8.24
Bundler Version:1.3.5
Rake Version: 10.1.0
GitLab information
Version: 6.4.0.pre
Revision: 16916fb
Directory: /opt/gitlab-6.4.0.pre2-0/apps/gitlab/htdocs
DB Adapter: mysql2
URL: http://127.0.0.1
HTTP Clone URL: http://127.0.0.1/some-project.git
SSH Clone URL: git@127.0.0.1:some-project.git
Using LDAP: no
Using Omniauth: no
GitLab Shell
Version: 1.8.0
Repositories: /opt/gitlab-6.4.0.pre2-0/apps/gitlab/repositories/
Hooks: /opt/gitlab-6.4.0.pre2-0/apps/gitlab/gitlab-shell/hooks/
Git: /opt/gitlab-6.4.0.pre2-0/git/bin/git
application.log:
December 16, 2013 16:11: Administrator created a new project "Administrator / dsfsadf"
production.log:
Started POST "/projects" for xxxx at 2013-12-16 16:11:12 -0500
Processing by ProjectsController#create as JS
Parameters: {"utf8"=>"\u2713", "authenticity_token"=>"xxxxx", "project"=>{"name"=>"dsfsadf", "path"=>"", "namespace_id"=>"1", "import_url"=>"", "description"=>"asdfsadf", "visibility_level"=>"0"}, "commit"=>"Create project"}
Rendered projects/_errors.html.haml (2.1ms)
Rendered projects/create.js.haml (12.1ms)
Completed 200 OK in 675.9ms (Views: 33.9ms | ActiveRecord: 16.2ms)
sidekiq,log:
Reinitialized existing Git repository in /home/git/repositories/rbrennan/dsfsadf.git/
2013-12-16T21:11:13Z 1641 TID-4huoms GitlabShellWorker JID-09d59b40ff3b0d64e0994412 INFO: done: 0.119 sec
mysql.log:
2 Query INSERT INTO `projects` (`created_at`, `creator_id`, `description`, `import_url`, `imported`, `issues_enabled`, `issues_tracker`, `issues_tracker_id`, `last_activity_at`, `merge_requests_enabled`, `name`, `namespace_id`, `path`, `snippets_enabled`, `updated_at`, `visibility_level`, `wall_enabled`, `wiki_enabled`) VALUES ('2013-12-16 21:15:49', 1, 'asdfsadf', '', 0, 1, 'gitlab', NULL, NULL, 1, 'dsfsadf', 1, 'dsfsadf', 0, '2013-12-16 21:15:49', 0, 0, 1)
2 Query UPDATE `projects` SET `last_activity_at` = '2013-12-16 21:15:49' WHERE `projects`.`id` = 1
2 Query SELECT `forked_project_links`.* FROM `forked_project_links` WHERE `forked_project_links`.`forked_to_project_id` = 1 LIMIT 1
2 Query SELECT `namespaces`.* FROM `namespaces` WHERE `namespaces`.`type` IN ('Group') AND `namespaces`.`id` = 1 AND (type = 'Group') LIMIT 1
2 Query SELECT `users`.* FROM `users` WHERE `users`.`id` = 1 LIMIT 1
131216 16:15:50 2 Query ROLLBACK
131216 16:15:51 1 Query SELECT `runners`.* FROM `runners` WHERE `runners`.`token` = 'bfc1b6eb5a41ee62e534d0b20d9def' LIMIT 1
1 Query BEGIN
1 Query SELECT `runner_projects`.* FROM `runner_projects` WHERE `runner_projects`.`runner_id` = 1
1 Query SELECT `builds`.* FROM `builds` WHERE `builds`.`status` = 'pending' AND `builds`.`runner_id` IS NULL ORDER BY created_at ASC LIMIT 1
1 Query COMMIT
131216 16:15:56 1 Query SELECT `runners`.* FROM `runners` WHERE `runners`.`token` = 'bfc1b6eb5a41ee62e534d0b20d9def' LIMIT 1
1 Query BEGIN
1 Query SELECT `runner_projects`.* FROM `runner_projects` WHERE `runner_projects`.`runner_id` = 1
1 Query SELECT `builds`.* FROM `builds` WHERE `builds`.`status` = 'pending' AND `builds`.`runner_id` IS NULL ORDER BY created_at ASC LIMIT 1
1 Query COMMIT
Created by: xEtherealx
Surely:
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /opt/gitlab-6.4.0.pre2-0/apps/gitlab/htdocs/Rakefile:7) 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 >= 1.7.9 ? ... OK (1.8.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 update hook up-to-date? ... yes update hooks in repos are links: ... can't check, you have no projects 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 GitLab ...
Database config exists? ... yes Database is SQLite ... no All migrations up? ... DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /opt/gitlab-6.4.0.pre2-0/apps/gitlab/htdocs/Rakefile:7) yes 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? ... no Try fixing it: Redownload the init script For more information see: doc/install/installation.md in section "Install Init Script" Please fix the error above and rerun the checks. projects have namespace: ... can't check, you have no projects Projects have satellites? ... can't check, you have no projects Redis version >= 2.0.0? ... yes Your git bin path is "/opt/gitlab-6.4.0.pre2-0/git/bin/git" Git version >= 1.7.10 ? ... yes (1.8.3)
Checking GitLab ... Finished
By Administrator on 2013-12-17T17:39:39 (imported from GitLab project)
Created by: dblessing
I think the issue is that GitLab sees 2 different repository locations - "/home/git/repositories/" and "/opt/gitlab-6.4.0.pre2-0/apps/gitlab/repositories/". You can see the first in the sidekiq.log and the latter in the gitlab info output. Will you please make sure that gitlab and gitlab-shell configuration have matching
repos_path
values?By Administrator on 2013-12-18T18:21:29 (imported from GitLab project)
Created by: xEtherealx
via grep:
./apps/gitlab/gitlab-shell/config.yml:repos_path: "/opt/gitlab-6.4.0.pre2-0/apps/gitlab/repositories" ./apps/gitlab/htdocs/config/gitlab.yml: repos_path: /opt/gitlab-6.4.0.pre2-0/apps/gitlab/repositories/
BUT
I see what you are saying and I think you are right. The default is "home/git/repositories" and I think that at some point the default is being selected as if repos_path is not set up. The spots where I see this could happen are:
./gitlab-shell/lib/gitlab_config.rb: @config['repos_path'] ||= "/home/git/repositories" ./htdocs/config/initializers/1_settings.rb:Settings.gitlab_shell['repos_path'] ||= Settings.gitlab['user_home'] + '/repositories/'
By Administrator on 2013-12-18T20:45:37 (imported from GitLab project)
Created by: dblessing
I think you're right. I don't immediately see where but somewhere.I'm firing up a development VM to see if I can track this down.As a side note, I see you installed GitLab in an "htdocs" directory. You're not exposing this all via some webserver like Apache, right? :) That would be a bad idea.
By Administrator on 2013-12-18T22:01:34 (imported from GitLab project)
Created by: dblessing
After looking at code and not finding any evidence of an issue I tested this in the development VM. I set the Gitlab config and Gitlab shell config repos_path to something other than /home/git/repositories and tested project creation. My project was successfully created in the alternate repositories directory as expected.
This was on 6.4 beta. You might wait until 6.4 comes out and test this to see if it was something solved recently or if you're experiencing some sort of configuration issue.
By Administrator on 2013-12-18T22:00:01 (imported from GitLab project)
Created by: xEtherealx
I'm using a bitnami "installer" https://bitnami.com/stack/gitlab which set up the entire directory structure as a self-contained module including all dependencies.
I did figure out the issue though, and it is sort of related to the bitnami stuff; I had to install a newer gitlab-shell after the bitnami install finished because I was getting an errors in gitlab:check.
I cloned gitlab-shell and I'm not sure how but apparently pointed the bitnami stack at it. Once I changed the proper config as you suggested I am indeed able to create projects! Thanks much for the help.
By Administrator on 2013-12-18T22:11:38 (imported from GitLab project)