Skip to content
Snippets Groups Projects
Commit 0cdbc747 authored by Balasankar "Balu" C's avatar Balasankar "Balu" C
Browse files

Skip auto-restart of PG during reconfigure as part of pg-upgrade


In nodes where Geo PG runs along with regular PG, during the PG upgrade
process of regular PG, a reconfigure is initiated. This reconfigure will
update the `VERSION` file in Geo PG's directory also with the new
verison information and trigger a restart of the Geo PG. However,
because Geo PG's data is still of the old version but the binaries have
already been updated to point to the new version, this restart will fail
due to mismatch.

Because PG upgrade anyways causes the DB to be stopped and started, we
can safely skip the automatic restart as part of reconfigure and avoid
this failure.

Changelog: fixed
Signed-off-by: default avatarBalasankar "Balu" C <balasankar@gitlab.com>
parent f746dc53
No related branches found
No related tags found
2 merge requests!76heptapod#711: 0.34 is the new stable,!73Sync up to upstream Omnibus GitLab 15.1
......@@ -33,7 +33,7 @@
command "mkdir -p #{install_dir}/embedded/cookbooks"
sync './', "#{install_dir}/embedded/cookbooks/"
solo_recipes = %w(dna postgresql-bin postgresql-config)
solo_recipes = %w(dna postgresql-bin postgresql-config pg-upgrade-config)
# If EE package, use a different master cookbook
if EE
......
{
"run_list": [ "recipe[<%= master_cookbook %>]" ],
"package": {
"public_attributes": true
},
"postgresql": {
"auto_restart_on_version_change": false
},
"gitlab": {
"geo-postgresql": {
"auto_restart_on_version_change": false
}
}
}
......@@ -535,7 +535,9 @@
def run_reconfigure
unless GitlabCtl::Util.progress_message('Running reconfigure') do
run_chef("#{base_path}/embedded/cookbooks/dna.json").success?
# Disable automatic restart as part of reconfigure to avoid other PGs than
# the one being currently upgraded getting restarted unnecessarily.
run_chef("#{base_path}/embedded/cookbooks/pg-upgrade-config.json").success?
end
die 'Something went wrong during final reconfiguration, please check the output'
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment