Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates to recovery.md to address PE-39730 #526

Merged
merged 2 commits into from
Nov 14, 2024

Conversation

mtaggart13
Copy link
Contributor

##Summary

https://perforce.atlassian.net/browse/PE-39730 outlines some required changes to the procedure for replacing a missing or failed replica Puppet server. This draft attempts to address all issues raised in the ticket.

https://perforce.atlassian.net/browse/PE-39730 outlines some required changes to the procedure for replacing a missing or failed replica Puppet server. This draft aims to address all issues raised in the ticket.
@mtaggart13 mtaggart13 requested review from a team as code owners November 13, 2024 15:27
* _\<replacement-avail-group-letter\>_ - Either A or B; whichever of the two letter designations is appropriate for the server being replaced. It will be the opposite of the primary server.
* _\<old-replica-fqdn\>_ - The FQDN and certname of the old replica Puppet server that has failed or is missing
* _\<replacement-replica-fqdn\>_ - The FQDN and certname of the new replica Puppet server
* _\<failed-primary-server-fqdn\>_ - The FQDN and certname of the original primary server that the old replica had replaced
Copy link

@taikaa taikaa Nov 13, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggest removing failed-primary-server-fqdn from this section altogether because steps about replacing a replica should just be in this section

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Promote the replica (official docs)
  2. purge the failed primary server puppet node purge
  3. Replace missing replica server (same as Replace missing or failed replica Puppet server below)


3. Install the Puppet agent on the replacement replica.

**Note**: When designating the availability group of the replacement, use the opposite group (A or B) of the server being replaced. This means that, if the old replica server replaced the original primary server, the new replica is assigned the same availability group as the original primary.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggest deleting this line. It won't always be the opposite of the server being replaced but it should be opposite of whatever is the primary which is already stated in the former line 18. I suggest leaving that line there <replacement-avail-group-letter>_ - Either A or B; whichever of the two letter designations is appropriate for the server being replaced. It will be the opposite of the primary server.

puppet agent -t

3. On the PE-PostgreSQL server in the _\<replacement-avail-group-letter\>_ group
4. Sign the certificate on the new primary server.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change to 'Sign the certificate on the primary server.
puppetserver ca sign --certname '
(It is not always a new primary server if they did not promote a replica. They can be doing these steps to just replace a failed replica)


puppet resource service puppet ensure=stopped

3. Add the following two lines to /opt/puppetlabs/server/data/postgresql/14/data/pg\_ident.conf
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add the following two lines to /opt/puppetlabs/server/data/postgresql/<postgres_version>/data/pg_ident.conf
In the latest PE release 2023.8.0 the PostgreSQL version is 14 /opt/puppetlabs/server/data/postgresql/14/data/pg_ident.confhttps://www.puppet.com/docs/pe/latest/component_versions_in_recent_pe_releases.html

@@ -102,11 +128,11 @@ On _\<working-postgres-server-fqdn\>_:

systemctl stop puppet

2. Add this line to /opt/puppetlabs/server/data/postgresql/11/data/pg\_ident.conf
2. Add this line to /opt/puppetlabs/server/data/postgresql/14/data/pg\_ident.conf
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add this line to /opt/puppetlabs/server/data/postgresql/<postgres_version>/data/pg_ident.conf
In the latest PE release 2023.8.0the PostgreSQL version is 14 /opt/puppetlabs/server/data/postgresql/14/data/pg_ident.confhttps://www.puppet.com/docs/pe/latest/component_versions_in_recent_pe_releases.html

Updates to draft following engineer review
@mtaggart13 mtaggart13 merged commit 391b83d into main Nov 14, 2024
3 of 4 checks passed
@mtaggart13 mtaggart13 deleted the mtaggart13-patch-1-for-PE-39730 branch November 14, 2024 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants