Geo: upgrade from 10.5.x to nightly build breaks geo-postgresql socket
I tried a clean 10.5.4-ee install with Geo enabled, upgrading to a https://dev.gitlab.org/gitlab/omnibus-gitlab/-/jobs/2311309 (from !2331 (merged))
During upgrade I got this:
Recipe: gitlab-ee::geo-secondary [922/9893]
* templatesymlink[Create a database_geo.yml and create a symlink to Rails root] action create
* template[/var/opt/gitlab/gitlab-rails/etc/database_geo.yml] action create
- update content in file /var/opt/gitlab/gitlab-rails/etc/database_geo.yml from dc8c49 to cf0fd2
--- /var/opt/gitlab/gitlab-rails/etc/database_geo.yml 2018-03-16 02:54:27.650574798 +0000
+++ /var/opt/gitlab/gitlab-rails/etc/.chef-database_geo20180316-5830-v9kwcn.yml 2018-03-16 03:05:56.280942912 +0000
@@ -19,5 +19,5 @@
load_balancing: {"hosts":[]}
prepared_statements:
statements_limit:
- fdw:
+ fdw: true
* template[/var/opt/gitlab/gitlab-rails/etc/database_geo.yml] action nothing (skipped due to action :nothing)
* link[Link /opt/gitlab/embedded/service/gitlab-rails/config/database_geo.yml to /var/opt/gitlab/gitlab-rails/etc/database_geo.yml] action create (up to date)
* file[/opt/gitlab/embedded/service/gitlab-rails/ee/db/geo/schema.rb] action create
- change owner from 'root' to 'git'
Recipe: gitlab-ee::geo_database_migrations
* bash[migrate gitlab-geo tracking database] action run
[execute] rake aborted!
PG::ConnectionBad: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/var/opt/gitlab/geo-postgresql/.s.PGSQL.5431"?
/opt/gitlab/embedded/service/gitlab-rails/ee/lib/gitlab/geo/database_tasks.rb:12:in `public_send'
/opt/gitlab/embedded/service/gitlab-rails/ee/lib/gitlab/geo/database_tasks.rb:12:in `block in method_missing'
/opt/gitlab/embedded/service/gitlab-rails/ee/lib/gitlab/geo/database_tasks.rb:169:in `with_geo_db'
/opt/gitlab/embedded/service/gitlab-rails/ee/lib/gitlab/geo/database_tasks.rb:11:in `method_missing'
/opt/gitlab/embedded/service/gitlab-rails/ee/lib/tasks/geo.rake:27:in `block (3 levels) in <top (required)>'
/opt/gitlab/embedded/bin/bundle:23:in `load'
/opt/gitlab/embedded/bin/bundle:23:in `<main>'
Tasks: TOP => geo:db:migrate
(See full trace by running task with --trace)
Workaround was to
gitlab-ctl restart
gitlab-ctl reconfigure
Edited by Gabriel Mazetto