Skip to content

Conversation

@dragomirp
Copy link
Contributor

@dragomirp dragomirp commented Oct 31, 2025

pg_basebackup fails to run when replicating from a primary cluster during async replication with TLS.

Checklist

  • I have added or updated any relevant documentation.
  • I have cleaned any remaining cloud resources from my accounts.

@codecov
Copy link

codecov bot commented Oct 31, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 70.73%. Comparing base (7efe94a) to head (c40bccf).

Additional details and impacted files
@@           Coverage Diff            @@
##           16/edge    #1274   +/-   ##
========================================
  Coverage    70.73%   70.73%           
========================================
  Files           16       16           
  Lines         4043     4043           
  Branches       629      629           
========================================
  Hits          2860     2860           
  Misses         991      991           
  Partials       192      192           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@dragomirp dragomirp force-pushed the dpe-8781-spaced-async branch 2 times, most recently from 6cc3495 to a8e7d60 Compare October 31, 2025 12:25
@dragomirp dragomirp force-pushed the dpe-8781-spaced-async branch from a8e7d60 to 04c6609 Compare October 31, 2025 12:37
@dragomirp dragomirp force-pushed the dpe-8781-spaced-async branch 3 times, most recently from 7da79bd to 9be6425 Compare October 31, 2025 14:19
@dragomirp dragomirp force-pushed the dpe-8781-spaced-async branch from 9be6425 to c40bccf Compare October 31, 2025 15:10
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Switchover fixes were merged so we can test edge or stable.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Partial copy of the async test with spaces.

Comment on lines +46 to +50
model_2 = Juju(model=model_name)
model_2.cli("reload-spaces")
model_2.cli("add-space", "client", "10.0.0.1/24")
model_2.cli("add-space", "peers", "10.10.10.1/24")
model_2.cli("add-space", "isolated", "10.20.20.1/24")
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Add spaces for the second model.

Comment on lines +138 to +143
model_1.offer(f"{first_model}.self-signed-certificates", endpoint="send-ca-cert")
model_2.consume(f"{first_model}.self-signed-certificates", "send-ca-offer")
model_2.integrate(DB_APP_2, "send-ca-offer")
model_2.offer(f"{second_model}.self-signed-certificates", endpoint="send-ca-cert")
model_1.consume(f"{second_model}.self-signed-certificates", "send-ca-offer")
model_1.integrate(DB_APP_1, "send-ca-offer")
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Should we transfer CAs here or test without?

{%- if enable_tls %}
sslrootcert: {{ conf_path }}/ca.pem
{%- endif %}
sslrootcert: {{ conf_path }}/nonexistent_cert.pem
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Breaks base backup while syncing the standby leader from the primary cluster.

I think the root issue is that in the snap service $HOME is set to the snap revision directory and PG utilities cannot access .postgresql directory there.

@dragomirp dragomirp marked this pull request as ready for review November 1, 2025 10:32
@dragomirp dragomirp requested review from a team, marceloneppel and taurus-forever and removed request for a team November 1, 2025 10:32
@dragomirp dragomirp added the bug Something isn't working as expected label Nov 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working as expected Libraries: Out of sync

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants