mariadb_copy: wait for connectivity to TripleO Galera before sync check - #1446
Conversation
Commit 824d9ed replaced sleep-based BGP workarounds with a retry loop that checks connectivity to the podified MariaDB, but did not add an equivalent check for the source TripleO Galera nodes. With BGP, the route to the mariadb-copy-data pod may take a few seconds to be advertised, causing the subsequent WSREP sync check to fail with "ERROR 2002 (HY000): Can't connect to MySQL server" (EINPROGRESS). Add a retry-loop task that verifies TCP connectivity to every TripleO Galera member via 'select 1;' before running the non-retrying WSREP sync check. Also update the documentation procedure to include this new connectivity check step and fix the BGP note wording to correctly describe route advertisement direction. Assisted-By: Claude (claude-opus-4.6)
jistr
left a comment
There was a problem hiding this comment.
/lgtm
This issue is what i was wondering about in my comment here but i didn't express myself clearly 😀 : #1361 (comment)
Yes, you were right. My fault I didn't realize about that. So BGP routes are required for the traffic that is routed through the mariadb-copy-data pod's internalapi interface (net1), but not for the traffic routed through ovn-k8s (eth0): Hence, without this PR, the pod can't connect to tripleo databases: More accurately, the problem is that it takes some time to advertise via BGP the mariadb-copy-data pod IP. |
|
Fixes a CI job, approving. |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: jistr The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
46194f4
into
openstack-k8s-operators:main
Commit 824d9ed replaced sleep-based BGP workarounds with a retry loop that checks connectivity to the podified MariaDB, but did not add an equivalent check for the source TripleO Galera nodes. With BGP, the route to the mariadb-copy-data pod may take a few seconds to be advertised, causing the subsequent WSREP sync check to fail with "ERROR 2002 (HY000): Can't connect to MySQL server" (EINPROGRESS).
Add a retry-loop task that verifies TCP connectivity to every TripleO Galera member via 'select 1;' before running the non-retrying WSREP sync check. Also update the documentation procedure to include this new connectivity check step and fix the BGP note wording to correctly describe route advertisement direction.
Assisted-By: Claude (claude-opus-4.6)