{"id":17173,"date":"2022-05-10T06:20:55","date_gmt":"2022-05-10T04:20:55","guid":{"rendered":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/"},"modified":"2022-05-31T16:40:51","modified_gmt":"2022-05-31T14:40:51","slug":"installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator","status":"publish","type":"post","link":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/","title":{"rendered":"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator"},"content":{"rendered":"<p>During previous months, I&#8217;ve had some time to satisfy my curiosity about databases in containers and I started to test a little bit <a href=\"https:\/\/www.mysql.com\/\" target=\"_blank\" rel=\"noopener\">MySQL<\/a> in <a href=\"https:\/\/kubernetes.io\/\" target=\"_blank\" rel=\"noopener\">Kubernetes<\/a>.<br \/>\nThis is how it all began&#8230;<br \/>\n<!--more--><br \/>\nIn January I had the chance to be trained on Kubernetes attending the <a href=\"https:\/\/www.dbi-services.com\/trainings\/docker-kubernetes-essentials\/\" target=\"_blank\" rel=\"noopener\">Docker and Kubernetes essentials Workshop<\/a> of dbi services. So I decided to prepare a session on this topic at our internal <a href=\"https:\/\/www.dbi-services.com\/on-the-company-and-its-associates\/corporate-values-company-mission\/dbi-xchange\/\" target=\"_blank\" rel=\"noopener\">dbi xChange<\/a> event. And as if by magic, at the same time, a customer asked for our support to migrate a MySQL database to their Kubernetes cluster.<\/p>\n<p>In general, I would like to raise two points before going into the technical details:<br \/>\n1. Is it a good idea to move databases into containers? Here I would use a typical IT answer: &#8220;it depends&#8221;. I can suggest you to think about your needs and constraints, if you have small images to deploy, about storage and persistence, performances, &#8230;<br \/>\n2. There are various solutions for installing, orchestrating and administering MySQL in K8s: MySQL single instance vs MySQL InnoDB Cluster, using MySQL Operator for Kubernetes or Helm Charts, on-premise but also through Oracle Container Engine for Kubernetes on OCI, &#8230; I recommend you to think about which are (again) your needs and skills, if you are already working on Cloud technologies, whether you have already set up DevOps processes and which ones, &#8230;<\/p>\n<p>Here I will show you how to install a MySQL InnoDB Cluster in OKE using a MySQL Operator.<\/p>\n<p>First thing is to have an account on <a href=\"https:\/\/cloud.oracle.com\" target=\"_blank\" rel=\"noopener\">Oracle OCI<\/a> and have deployed an <a href=\"https:\/\/www.oracle.com\/cloud-native\/container-engine-kubernetes\/\" target=\"_blank\" rel=\"noopener\">Oracle Container Engine for Kubernetes<\/a> in your compartment. You can do it in an easy was using the Quick Create option under &#8220;Developer Services &gt; Containers &amp; Artifacts &gt; Kubernetes Clusters (OKE)&#8221;:<br \/>\n<a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png\" alt=\"\" width=\"300\" height=\"133\" class=\"alignnone size-medium wp-image-55581\" \/><\/a><br \/>\nIn this way all the resources you need (VCN, Internet and NAT gateways, a K8s cluster with workers nodes and node pool) are there in one click:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1,7]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl cluster-info\nKubernetes control plane is running at https:\/\/xxx.xx.xxx.xxx:6443\nCoreDNS is running at https:\/\/xxx.xx.xxx.xxx:6443\/api\/v1\/namespaces\/kube-system\/services\/kube-dns:dns\/proxy\n\nTo further debug and diagnose cluster problems, use 'kubectl cluster-info dump'.\n\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl get nodes -o wide\nNAME         STATUS   ROLES   AGE    VERSION   INTERNAL-IP   EXTERNAL-IP       OS-IMAGE                  KERNEL-VERSION                      CONTAINER-RUNTIME\n10.0.10.36   Ready    node    6m7s   v1.22.5   10.0.10.36    yyy.yyy.yyy.yyy   Oracle Linux Server 7.9   5.4.17-2136.304.4.1.el7uek.x86_64   cri-o:\/\/1.22.3-1.ci.el7\n10.0.10.37   Ready    node    6m1s   v1.22.5   10.0.10.37    kkk.kkk.kkk.kk    Oracle Linux Server 7.9   5.4.17-2136.304.4.1.el7uek.x86_64   cri-o:\/\/1.22.3-1.ci.el7\n10.0.10.42   Ready    node    6m     v1.22.5   10.0.10.42    jjj.jj.jjj.jj     Oracle Linux Server 7.9   5.4.17-2136.304.4.1.el7uek.x86_64   cri-o:\/\/1.22.3-1.ci.el7\n<\/pre>\n<p>As a second step, you can install the <a href=\"https:\/\/github.com\/mysql\/mysql-operator\" target=\"_blank\" rel=\"noopener\">MySQL Operator for Kubernetes<\/a> using kubectl:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1,6]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl apply -f https:\/\/raw.githubusercontent.com\/mysql\/mysql-operator\/trunk\/deploy\/deploy-crds.yaml\ncustomresourcedefinition.apiextensions.k8s.io\/innodbclusters.mysql.oracle.com created\ncustomresourcedefinition.apiextensions.k8s.io\/mysqlbackups.mysql.oracle.com created\ncustomresourcedefinition.apiextensions.k8s.io\/clusterkopfpeerings.zalando.org created\ncustomresourcedefinition.apiextensions.k8s.io\/kopfpeerings.zalando.org created\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl apply -f https:\/\/raw.githubusercontent.com\/mysql\/mysql-operator\/trunk\/deploy\/deploy-operator.yaml\nserviceaccount\/mysql-sidecar-sa created\nclusterrole.rbac.authorization.k8s.io\/mysql-operator created\nclusterrole.rbac.authorization.k8s.io\/mysql-sidecar created\nclusterrolebinding.rbac.authorization.k8s.io\/mysql-operator-rolebinding created\nclusterkopfpeering.zalando.org\/mysql-operator created\nnamespace\/mysql-operator created\nserviceaccount\/mysql-operator-sa created\ndeployment.apps\/mysql-operator created\n<\/pre>\n<p>You can check the health of the MySQL Operator:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1,4]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl get deployment -n mysql-operator mysql-operator\nNAME             READY   UP-TO-DATE   AVAILABLE   AGE\nmysql-operator   1\/1     1            1           24s\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl get pods --show-labels -n mysql-operator\nNAME                              READY   STATUS    RESTARTS   AGE    LABELS\nmysql-operator-869d4b4b8d-slr4t   1\/1     Running   0          113s   name=mysql-operator,pod-template-hash=869d4b4b8d\n<\/pre>\n<p>To isolate resources, you can create a dedicated namespace for the MySQL InnoDB Cluster:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl create namespace mysql-cluster\nnamespace\/mysql-cluster created\n<\/pre>\n<p>You should also create a Secret using kubectl to store MySQL user credentials that will be created and then required by pods to access to the MySQL server:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl create secret generic elisapwd --from-literal=rootUser=root --from-literal=rootHost=% --from-literal=rootPassword=\"pwd\" -n mysql-cluster\nsecret\/elisapwd created\n<\/pre>\n<p>You can check that the Secret was corrected created:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1,5]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl get secrets -n mysql-cluster\nNAME                  TYPE                                  DATA   AGE\ndefault-token-t2c47   kubernetes.io\/service-account-token   3      2m\nelisapwd              Opaque                                3      34s\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl describe secret\/elisapwd -n mysql-cluster\nName:         elisapwd\nNamespace:    mysql-cluster\nLabels:       \nAnnotations:  \n\nType:  Opaque\n\nData\n====\nrootHost:      1 bytes\nrootPassword:  7 bytes\nrootUser:      4 bytes\n<\/pre>\n<p>Now you have to write a .yaml configuration file to define how the MySQL InnoDB Cluster should be created. Here is a simple example: <\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1]\">\nelisa@cloudshell:~ (eu-zurich-1)$ vi InnoDBCluster_config.yaml\napiVersion: mysql.oracle.com\/v2alpha1\nkind: InnoDBCluster\nmetadata:\n  name: elisacluster\n  namespace: mysql-cluster \nspec:\n  secretName: elisapwd\n  instances: 3\n  router:\n    instances: 1\n<\/pre>\n<p>At this point you can run a MySQL InnoDB Cluster applying the configuration that you just created:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl apply -f InnoDBCluster_config.yaml\ninnodbcluster.mysql.oracle.com\/elisacluster created\n<\/pre>\n<p>You can finally check if the MySQL InnoDB Cluster has been successfully created:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1,11]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl get innodbcluster --watch --namespace mysql-cluster\nNAME           STATUS    ONLINE   INSTANCES   ROUTERS   AGE\nelisacluster   PENDING   0        3           1         12s\nelisacluster   PENDING   0        3           1         103s\nelisacluster   INITIALIZING   0        3           1         103s\nelisacluster   INITIALIZING   0        3           1         103s\nelisacluster   INITIALIZING   0        3           1         103s\nelisacluster   INITIALIZING   0        3           1         104s\nelisacluster   INITIALIZING   0        3           1         106s\nelisacluster   ONLINE         1        3           1         107s\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl get all -n mysql-cluster\nNAME                                       READY   STATUS    RESTARTS   AGE\npod\/elisacluster-0                         2\/2     Running   0          4h44m\npod\/elisacluster-1                         2\/2     Running   0          4h42m\npod\/elisacluster-2                         2\/2     Running   0          4h41m\npod\/elisacluster-router-7686457f5f-hwfcv   1\/1     Running   0          4h42m\n\nNAME                             TYPE        CLUSTER-IP    EXTERNAL-IP   PORT(S)                               AGE\nservice\/elisacluster             ClusterIP   10.96.9.203           6446\/TCP,6448\/TCP,6447\/TCP,6449\/TCP   4h44m\nservice\/elisacluster-instances   ClusterIP   None                  3306\/TCP,33060\/TCP,33061\/TCP          4h44m\n\nNAME                                  READY   UP-TO-DATE   AVAILABLE   AGE\ndeployment.apps\/elisacluster-router   1\/1     1            1           4h44m\n\nNAME                                             DESIRED   CURRENT   READY   AGE\nreplicaset.apps\/elisacluster-router-7686457f5f   1         1         1       4h44m\n\nNAME                            READY   AGE\nstatefulset.apps\/elisacluster   3\/3     4h44m\n<\/pre>\n<p>You can use port forwarding in the following way:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1]\">\nelisa@cloudshell:~ (eu-zurich-1)$ kubectl port-forward service\/elisacluster mysql --namespace=mysql-cluster\nForwarding from 127.0.0.1:6446 -&gt; 6446\n<\/pre>\n<p>to access your MySQL InnoDB Cluster on a second terminal in order to check its health: <\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1; highlight: [1,16,65,67,74]\">\nelisa@cloudshell:~ (eu-zurich-1)$ mysqlsh -h127.0.0.1 -P6446 -uroot -p\nPlease provide the password for 'root@127.0.0.1:6446': *******\nSave password for 'root@127.0.0.1:6446'? [Y]es\/[N]o\/Ne[v]er (default No): N\nMySQL Shell 8.0.28-commercial\n\nCopyright (c) 2016, 2022, Oracle and\/or its affiliates.\nOracle is a registered trademark of Oracle Corporation and\/or its affiliates.\nOther names may be trademarks of their respective owners.\n\nType 'help' or '?' for help; 'quit' to exit.\nCreating a session to 'root@127.0.0.1:6446'\nFetching schema names for autocompletion... Press ^C to stop.\nYour MySQL connection id is 36651\nServer version: 8.0.28 MySQL Community Server - GPL\nNo default schema selected; type use  to set one.\n MySQL  127.0.0.1:6446 ssl  JS &gt;  MySQL  127.0.0.1:6446 ssl  JS &gt; dba.getCluster().status();\n{\n    \"clusterName\": \"elisacluster\", \n    \"defaultReplicaSet\": {\n        \"name\": \"default\", \n        \"primary\": \"elisacluster-0.elisacluster-instances.mysql-cluster.svc.cluster.local:3306\", \n        \"ssl\": \"REQUIRED\", \n        \"status\": \"OK\", \n        \"statusText\": \"Cluster is ONLINE and can tolerate up to ONE failure.\", \n        \"topology\": {\n            \"elisacluster-0.elisacluster-instances.mysql-cluster.svc.cluster.local:3306\": {\n                \"address\": \"elisacluster-0.elisacluster-instances.mysql-cluster.svc.cluster.local:3306\", \n                \"memberRole\": \"PRIMARY\", \n                \"memberState\": \"(MISSING)\", \n                \"mode\": \"n\/a\", \n                \"readReplicas\": {}, \n                \"role\": \"HA\", \n                \"shellConnectError\": \"MySQL Error 2005: Could not open connection to 'elisacluster-0.elisacluster-instances.mysql-cluster.svc.cluster.local:3306': Unknown MySQL server host 'elisacluster-0.elisacluster-instances.mysql-cluster.svc.cluster.local' (-2)\", \n                \"status\": \"ONLINE\", \n                \"version\": \"8.0.28\"\n            }, \n            \"elisacluster-1.elisacluster-instances.mysql-cluster.svc.cluster.local:3306\": {\n                \"address\": \"elisacluster-1.elisacluster-instances.mysql-cluster.svc.cluster.local:3306\", \n                \"memberRole\": \"SECONDARY\", \n                \"memberState\": \"(MISSING)\", \n                \"mode\": \"n\/a\", \n                \"readReplicas\": {}, \n                \"role\": \"HA\", \n                \"shellConnectError\": \"MySQL Error 2005: Could not open connection to 'elisacluster-1.elisacluster-instances.mysql-cluster.svc.cluster.local:3306': Unknown MySQL server host 'elisacluster-1.elisacluster-instances.mysql-cluster.svc.cluster.local' (-2)\", \n                \"status\": \"ONLINE\", \n                \"version\": \"8.0.28\"\n            }, \n            \"elisacluster-2.elisacluster-instances.mysql-cluster.svc.cluster.local:3306\": {\n                \"address\": \"elisacluster-2.elisacluster-instances.mysql-cluster.svc.cluster.local:3306\", \n                \"memberRole\": \"SECONDARY\", \n                \"memberState\": \"(MISSING)\", \n                \"mode\": \"n\/a\", \n                \"readReplicas\": {}, \n                \"role\": \"HA\", \n                \"shellConnectError\": \"MySQL Error 2005: Could not open connection to 'elisacluster-2.elisacluster-instances.mysql-cluster.svc.cluster.local:3306': Unknown MySQL server host 'elisacluster-2.elisacluster-instances.mysql-cluster.svc.cluster.local' (-2)\", \n                \"status\": \"ONLINE\", \n                \"version\": \"8.0.28\"\n            }\n        }, \n        \"topologyMode\": \"Single-Primary\"\n    }, \n    \"groupInformationSourceMember\": \"elisacluster-0.elisacluster-instances.mysql-cluster.svc.cluster.local:3306\"\n}\n\n MySQL  127.0.0.1:6446 ssl  JS &gt; sql\nSwitching to SQL mode... Commands end with ;\n MySQL  127.0.0.1:6446 ssl  SQL &gt; select @@hostname;\n+----------------+\n| @@hostname     |\n+----------------+\n| elisacluster-0 |\n+----------------+\n1 row in set (0.0018 sec)\n MySQL  127.0.0.1:6446 ssl  SQL &gt; SELECT * FROM performance_schema.replication_group_members;\n+---------------------------+--------------------------------------+-----------------------------------------------------------------------+-------------+--------------+-------------+----------------+----------------------------+\n| CHANNEL_NAME              | MEMBER_ID                            | MEMBER_HOST                                                           | MEMBER_PORT | MEMBER_STATE | MEMBER_ROLE | MEMBER_VERSION | MEMBER_COMMUNICATION_STACK |\n+---------------------------+--------------------------------------+-----------------------------------------------------------------------+-------------+--------------+-------------+----------------+----------------------------+\n| group_replication_applier | 717dbe17-ba71-11ec-8a91-3665daa9c822 | elisacluster-0.elisacluster-instances.mysql-cluster.svc.cluster.local |        3306 | ONLINE       | PRIMARY     | 8.0.28         | XCom                       |\n| group_replication_applier | b02c3c9a-ba71-11ec-8b65-5a93db09dda5 | elisacluster-1.elisacluster-instances.mysql-cluster.svc.cluster.local |        3306 | ONLINE       | SECONDARY   | 8.0.28         | XCom                       |\n| group_replication_applier | eb06aadd-ba71-11ec-8aac-aa31e5d7e08b | elisacluster-2.elisacluster-instances.mysql-cluster.svc.cluster.local |        3306 | ONLINE       | SECONDARY   | 8.0.28         | XCom                       |\n+---------------------------+--------------------------------------+-----------------------------------------------------------------------+-------------+--------------+-------------+----------------+----------------------------+\n3 rows in set (0.0036 sec)\n<\/pre>\n<p>Easy, right?<br \/>\nYes, but databases containers is still a tricky subject. As we said above, many topics need to be addressed: deployment type, performances, backups, storage and persistence, &#8230; So stay tuned, more blog posts about MySQL on K8s will come soon&#8230; <\/p>\n<p>By <a href=\"https:\/\/www.linkedin.com\/in\/elisausai\/\" target=\"_blank\" rel=\"noopener\">Elisa Usai<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>During previous months, I&#8217;ve had some time to satisfy my curiosity about databases in containers and I started to test a little bit MySQL in Kubernetes. This is how it all began&#8230;<\/p>\n","protected":false},"author":42,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[955,229,1320,1522,1316,59],"tags":[135,762,2540,1365,89,144,2541,1375,96],"type_dbi":[],"class_list":["post-17173","post","type-post","status-publish","format-standard","hentry","category-cloud","category-database-administration-monitoring","category-devops","category-kubernetes","category-mysql","category-oracle","tag-cloud","tag-containers","tag-databases","tag-k8s","tag-kubernetes","tag-mysql","tag-mysql-innodb-cluster","tag-oci","tag-oracle"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.2) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Installing MySQL InnoDB Cluster in OKE using a MySQL Operator - dbi Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator\" \/>\n<meta property=\"og:description\" content=\"During previous months, I&#8217;ve had some time to satisfy my curiosity about databases in containers and I started to test a little bit MySQL in Kubernetes. This is how it all began&#8230;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/\" \/>\n<meta property=\"og:site_name\" content=\"dbi Blog\" \/>\n<meta property=\"article:published_time\" content=\"2022-05-10T04:20:55+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-05-31T14:40:51+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png\" \/>\n<meta name=\"author\" content=\"Elisa Usai\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Elisa Usai\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/\"},\"author\":{\"name\":\"Elisa Usai\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/ac5847ee8d7bad4196e72660c1377b1f\"},\"headline\":\"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator\",\"datePublished\":\"2022-05-10T04:20:55+00:00\",\"dateModified\":\"2022-05-31T14:40:51+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/\"},\"wordCount\":523,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png\",\"keywords\":[\"Cloud\",\"Containers\",\"databases\",\"k8s\",\"kubernetes\",\"MySQL\",\"MySQL InnoDB Cluster\",\"OCI\",\"Oracle\"],\"articleSection\":[\"Cloud\",\"Database Administration &amp; Monitoring\",\"DevOps\",\"Kubernetes\",\"MySQL\",\"Oracle\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/\",\"name\":\"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator - dbi Blog\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png\",\"datePublished\":\"2022-05-10T04:20:55+00:00\",\"dateModified\":\"2022-05-31T14:40:51+00:00\",\"author\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/ac5847ee8d7bad4196e72660c1377b1f\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#primaryimage\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png\",\"contentUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Accueil\",\"item\":\"https:\/\/www.dbi-services.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/\",\"name\":\"dbi Blog\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/ac5847ee8d7bad4196e72660c1377b1f\",\"name\":\"Elisa Usai\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/secure.gravatar.com\/avatar\/d41c7e94b7e4cd42bdcc5b82003c00562de8da0cf0a1081fbe832d47e3a828ff?s=96&d=mm&r=g\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/d41c7e94b7e4cd42bdcc5b82003c00562de8da0cf0a1081fbe832d47e3a828ff?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/d41c7e94b7e4cd42bdcc5b82003c00562de8da0cf0a1081fbe832d47e3a828ff?s=96&d=mm&r=g\",\"caption\":\"Elisa Usai\"},\"url\":\"https:\/\/www.dbi-services.com\/blog\/author\/elisa-usai\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator - dbi Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/","og_locale":"en_US","og_type":"article","og_title":"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator","og_description":"During previous months, I&#8217;ve had some time to satisfy my curiosity about databases in containers and I started to test a little bit MySQL in Kubernetes. This is how it all began&#8230;","og_url":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/","og_site_name":"dbi Blog","article_published_time":"2022-05-10T04:20:55+00:00","article_modified_time":"2022-05-31T14:40:51+00:00","og_image":[{"url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png","type":"","width":"","height":""}],"author":"Elisa Usai","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Elisa Usai","Est. reading time":"8 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#article","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/"},"author":{"name":"Elisa Usai","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/ac5847ee8d7bad4196e72660c1377b1f"},"headline":"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator","datePublished":"2022-05-10T04:20:55+00:00","dateModified":"2022-05-31T14:40:51+00:00","mainEntityOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/"},"wordCount":523,"commentCount":0,"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png","keywords":["Cloud","Containers","databases","k8s","kubernetes","MySQL","MySQL InnoDB Cluster","OCI","Oracle"],"articleSection":["Cloud","Database Administration &amp; Monitoring","DevOps","Kubernetes","MySQL","Oracle"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/","url":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/","name":"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator - dbi Blog","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#primaryimage"},"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png","datePublished":"2022-05-10T04:20:55+00:00","dateModified":"2022-05-31T14:40:51+00:00","author":{"@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/ac5847ee8d7bad4196e72660c1377b1f"},"breadcrumb":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#primaryimage","url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png","contentUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/05\/OKE0.png"},{"@type":"BreadcrumbList","@id":"https:\/\/www.dbi-services.com\/blog\/installing-mysql-innodb-cluster-in-oke-using-a-mysql-operator\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Accueil","item":"https:\/\/www.dbi-services.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Installing MySQL InnoDB Cluster in OKE using a MySQL Operator"}]},{"@type":"WebSite","@id":"https:\/\/www.dbi-services.com\/blog\/#website","url":"https:\/\/www.dbi-services.com\/blog\/","name":"dbi Blog","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/ac5847ee8d7bad4196e72660c1377b1f","name":"Elisa Usai","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/d41c7e94b7e4cd42bdcc5b82003c00562de8da0cf0a1081fbe832d47e3a828ff?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/d41c7e94b7e4cd42bdcc5b82003c00562de8da0cf0a1081fbe832d47e3a828ff?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/d41c7e94b7e4cd42bdcc5b82003c00562de8da0cf0a1081fbe832d47e3a828ff?s=96&d=mm&r=g","caption":"Elisa Usai"},"url":"https:\/\/www.dbi-services.com\/blog\/author\/elisa-usai\/"}]}},"_links":{"self":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/17173","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/users\/42"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/comments?post=17173"}],"version-history":[{"count":1,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/17173\/revisions"}],"predecessor-version":[{"id":17174,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/17173\/revisions\/17174"}],"wp:attachment":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media?parent=17173"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/categories?post=17173"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/tags?post=17173"},{"taxonomy":"type","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/type_dbi?post=17173"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}