Hi,
I’ve recently started exploring XtraDB to replace a MySQL RDS instance. I’ve deployed the Percona Operator to my Kubernetes cluster and deployed an pxc cluster. The next requirement is to configure cross site replication to improve availability. I have a single Kubernetes cluster deployed in different DCs/Locations and I’m using taints and tolerations to schedule where my workload should run.
Using the operator, I’ve configure my primary pxc cluster replication:
pxc:
size: 3
image:
repository: percona/percona-xtradb-cluster
tag: 8.0.32-24.2
autoRecovery: true
expose:
enabled: true
type: ClusterIP
replicationChannels:
- name: cluster1_to_cluster2
isSource: true
I then configured my secondary/standby pxc cluster:
pxc:
size: 3
image:
repository: percona/percona-xtradb-cluster
tag: 8.0.32-24.2
autoRecovery: true
replicationChannels:
- name: cluster1_to_cluster2
isSource: false
configuration:
sourceRetryCount: 3
sourceConnectRetry: 60
ssl: true
sslSkipVerify: true
ca: '/etc/mysql/ssl/ca.crt'
sourcesList:
- host: cluster1-pxc-0
port: 3306
weight: 100
- host: cluster1-pxc-1
port: 3306
weight: 90
- host: cluster1-pxc-2
port: 3306
weight: 80
However, I’m not able to get the replication to work and always seeing certificate verify failed messages even though “sslSkipVerify” is set to true.
Certificates on the cluster is generated by cert-manager. Both clusters have their own CA. So this make sense that cluster2 will not be able to use its CA to verify the certificate from Cluster1.
{"log":"2023-11-13T11:56:30.759345Z 32 [ERROR] [MY-010584] [Repl] Slave I/O for channel 'cluster1_to_cluster2': error connecting to master 'replication@cluster1-pxc-1:3306' - retry-time: 60 retries: 1 message: SSL connection error: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed, Error_code: MY-002026\n","file":"/var/lib/mysql/mysqld-error.log"}
{"log":"2023-11-13T11:57:30.819491Z 32 [ERROR] [MY-010584] [Repl] Slave I/O for channel 'cluster1_to_cluster2': error connecting to master 'replication@cluster1-pxc-1:3306' - retry-time: 60 retries: 2 message: SSL connection error: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed, Error_code: MY-002026\n","file":"/var/lib/mysql/mysqld-error.log"}
{"log":"2023-11-13T11:58:30.882113Z 32 [ERROR] [MY-010584] [Repl] Slave I/O for channel 'cluster1_to_cluster2': error connecting to master 'replication@cluster1-pxc-1:3306' - retry-time: 60 retries: 3 message: SSL connection error: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed, Error_code: MY-002026\n","file":"/var/lib/mysql/mysqld-error.log"}
My questions are:
- Why is “sslSkipVerify: true” not working?
- Can I get both clusters to use the same CA?
- Any additional guidance on how to configure cross site replication?