Bug #108802 Initialize MySQL InnoDB Cluster for k8 with PVC backup using initDB not working

Submitted: 17 Oct 2022 15:49 Modified: 17 Oct 2022 19:58
Reporter: Pradeep Pant Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Operator Severity:S2 (Serious)
Version:8.0.30 OS:Red Hat (8.4)
Assigned to: CPU Architecture:Any
Tags: mysql innodb cluster

[17 Oct 2022 15:49] Pradeep Pant
Description:
I am trying to initialize a new MySQL InnoDB Cluster with a database dump created by MySQL Operator for Kubernetes. I see that restore through PVC is not supported but as per documentation it's mentioned that one can bootstrap a new instance of MySQL using the backup dump taken through MySQL Operator. I tried through helm on k8 master node and also by adding initDB section in values.yaml. 

Innodb pods are not coming up. 

How to repeat:
Re-create steps:
* Install MySQL Operator and MySQL InnoDB version 8.0.30 using helm on with a backup profile and backup schedule
* Check if backups are getting created in designated location (In our case we are using PVC Volume Claim)
* Uninstall MySQL Operator and MySQL InnoDB cluster
* Install a new instance of My SQL Operator and MySQL Innodb through helm by passing dump storage name and path. Below is an example command:

helm install mysqlapp ./mysql-innodbcluster --namespace testns --set credentials.root.password='password123' --set credentials.root.host='%' --set serverInstances=3 --set routerInstances=1 --set initDB.dump.name="dbbackup1-20221006-170829" --set initDB.dump.storage.persistentVolumeClaim.claimName="mysql-bck-pvc" --version 2.0.5

Expected result: MySQL Operator and MySQL InnoDB cluster should be installed and DB's from backup dump should be available in MySQL.

Issue: MySQL Innodb pods are not getting created. I see message like "AttributeError: 'InnoDBClusterSpec' object has no attribute 'clusterName'" while describing ic.

Suggested fix:
[17 Oct 2022 19:58] MySQL Verification Team
Hi,

Thank you for the report.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.048 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.