SlideShare a Scribd company logo
Deploying MySQL InnoDB
Cluster on OCI with Terraform
Oracle Developer Live
Frédéric Descamps
Community Manager
MySQL
Who am I ?
about.me/lefred
Copyright @ 2020 Oracle and/or its affiliates.2
@lefred
MySQL Evangelist
Managing MySQL since
3.20
devops believer
living in Belgium
h ps://lefred.be
Frédéric Descamps
Copyright @ 2020 Oracle and/or its affiliates.3
Sign up
Oracle Cloud Free Trier
Copyright @ 2020 Oracle and/or its affiliates.4
Copyright @ 2020 Oracle and/or its affiliates.5
Breakout Lab Support
Today's Experts Standing By:
- Miguel - Dave
- Olivier - Ted
- Vi orio
Have a Question?
Direct your question via chat to one of our experts above or the instructor.
Breakout Rooms
If you are not able to get your question answered within the chat, we have
breakout rooms available for you.
We ask that if your question requires the use of a breakout room, that the time
within the breakout room remains brief to ensure experts can assist others in
need of help.
Copyright @ 2020 Oracle and/or its affiliates.6
use only Germany Central (Frankfurt) !!
and use the same email you used to register
to this session
Prerequisites
Please create your OCI free account following all the instructions from the Livelabs:
h ps://oracle.github.io/learning-library/oci-library/oci-hol/odl-mysql-idc-terraform-hol-
master/workshops/freetier/
Copyright @ 2020 Oracle and/or its affiliates.7
Free Trier: note on always free
To perform this lab, you need to use a new Free Trier account provided today. If you have
an old one, it might not work if you don't have the free credits.
If this is your case you won't be able to:
use more than 1 node in your cluster
use the NAT gateway and split the databases in a private subnet
And you will have to use VM.Standard.E2.1.Micro shape.
Copyright @ 2020 Oracle and/or its affiliates.8
Infrastructure as Code
What is Terraform ?
Copyright @ 2020 Oracle and/or its affiliates.9
What is Terraform ?
Terraform is a tool for building, changing, and versioning infrastructure safely and
e ciently. Terraform can manage existing and popular service providers as well as custom
in-house solutions.
Copyright @ 2020 Oracle and/or its affiliates.10
Terraform & OCI
Oracle Cloud Infrastructure is supported by Terraform.
We provide many OCI quickstarts in github: h ps://github.com/oracle-quickstart/.
Copyright @ 2020 Oracle and/or its affiliates.11
Terraform & OCI
Oracle Cloud Infrastructure is supported by Terraform.
We provide many OCI quickstarts in github: h ps://github.com/oracle-quickstart/.
Today we will use a contribution to the original MySQL one: h ps://github.com/lefred/oci-
mysql-idc.git
Copyright @ 2020 Oracle and/or its affiliates.11
Architecture
What will we deploy ?
Copyright @ 2020 Oracle and/or its affiliates.12
Architecture
MySQL 1
MySQL 3
VCN
10.0.0.0/16
Public Subnet
10.0.0.0/24
Private Subnet
10.0.1.0/24
Private Subnet
10.0.1.0/24
Group Replication
Fault Domain 1
Fault Domain2
Fault Domain3
MySQL 2
Bastion Host
Copyright @ 2020 Oracle and/or its affiliates.13
Get ready
Se ing up your environment
Copyright @ 2020 Oracle and/or its affiliates.14
an OCI account
Terraform
git
ssh client
on Windows, for git and ssh, you should use
h ps://github.com/git-for-windows/git/releases/latest
Se ing up your environment
You need:
Copyright @ 2020 Oracle and/or its affiliates.15
Prerequisites &
Introduction
Copyright @ 2020 Oracle and/or its affiliates.16
Prerequisites &
Introduction
ready ? update your feedback !
Copyright @ 2020 Oracle and/or its affiliates.16
Update your feedback
At the end of each LAB, please update your feedback in the participants list:
Copyright @ 2020 Oracle and/or its affiliates.17
Creating your API keys:
$ mkdir ~/.oci
$ openssl genrsa -out ~/.oci/oci_api_key.pem 2048
$ chmod go-rwx ~/.oci/oci_api_key.pem
$ openssl rsa -pubout -in ~/.oci/oci_api_key.pem -out ~/.oci/oci_api_key_public.pem
And for SSH don't provide passphrase:
$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/fred/.ssh/id_rsa): id_rsa_oci
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in id_rsa_oci
Your public key has been saved in id_rsa_oci.pub
Prepare your OCI environment
Copyright @ 2020 Oracle and/or its affiliates.18
Prepare your OCI environment (2)
Example for our Windows user friends:
Copyright @ 2020 Oracle and/or its affiliates.19
Prepare your OCI environment (3)
Example for our Windows user friends - API keys:
Copyright @ 2020 Oracle and/or its affiliates.20
Prepare your OCI environment (4)
Example for our Windows user friends - SSH keys:
Copyright @ 2020 Oracle and/or its affiliates.21
In our example, the key is
~/.oci/oci_api_key_public.pem
Prepare your OCI environment - deploy your API key
You need to deploy your public API key on OCI:
Copyright @ 2020 Oracle and/or its affiliates.22
LAB 1
Copyright @ 2020 Oracle and/or its affiliates.23
LAB 1
ready ? update your feedback !
Copyright @ 2020 Oracle and/or its affiliates.23
Terraform is a unique binary you can download from
h ps://www.terraform.io/downloads.html
$ cd ~bin
$ wget 
https://releases.hashicorp.com/terraform/0.13.4/terraform_0.13.4_linux_amd64.zip
$ unzip terraform_0.13.4_linux_amd64.zip
Archive: terraform_0.13.4_linux_amd64.zip
inflating: terraform
$ terraform --version
Terraform v0.13.4
Installing Terraform
Copyright @ 2020 Oracle and/or its affiliates.24
Installing Terraform (2)
Example for our Windows user friends:
Copyright @ 2020 Oracle and/or its affiliates.25
$ git clone https://github.com/lefred/oci-mysql-idc.git
Ge ing the git repo
Copyright @ 2020 Oracle and/or its affiliates.26
$ git clone https://github.com/lefred/oci-mysql-idc.git
Ge ing the git repo
Now we need to copy terraform.tfvars.template to edit it:
$ cd oci-mysql-idc
$ cp terraform.tfvars.template terraform.tfvars
Copyright @ 2020 Oracle and/or its affiliates.26
$ git clone https://github.com/lefred/oci-mysql-idc.git
Ge ing the git repo
Now we need to copy terraform.tfvars.template to edit it:
$ cd oci-mysql-idc
$ cp terraform.tfvars.template terraform.tfvars
This is maybe the most complex task of the deployment ;-)
Copyright @ 2020 Oracle and/or its affiliates.26
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.27
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.28
tenancy_oid
Copyright @ 2020 Oracle and/or its affiliates.29
tenancy_oid (2)
Copyright @ 2020 Oracle and/or its affiliates.30
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.31
user_ocid
Copyright @ 2020 Oracle and/or its affiliates.32
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.33
Key & Fingerprint
The private_key_path value is the path of oci_api_key.pem:
private_key_path = "/home/fred/.oci/oci_api_key.pem"
Copyright @ 2020 Oracle and/or its affiliates.34
Key & Fingerprint
The private_key_path value is the path of oci_api_key.pem:
private_key_path = "/home/fred/.oci/oci_api_key.pem"
And to get the Fingerprint:
Copyright @ 2020 Oracle and/or its affiliates.34
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.35
us-gov-ashburn-1
us-gov-chicago-1
us-gov-phoenix-1
us-langley-1
us-luke-1
us-phoenix-1
us-sanjose-1
eu-amsterdam-1
eu-frankfurt-1
eu-zurich-1
me-jeddah-1
sa-saopaulo-1
uk-london-1
us-ashburn-1
ap-chuncheon-1
ap-hyderabad-1
ap-melbourne-1
ap-mumbai-1
ap-osaka-1
ap-seoul-1
ap-sydney-1
ap-tokyo-1
ca-montreal-1
ca-toronto-1
Region
The di erent regions (not all accessible) as on September 2020 are:
Copyright @ 2020 Oracle and/or its affiliates.36
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.37
compartment_ocid
You may or not have setup di erent compartments. I usually use a sandbox for example.
Copyright @ 2020 Oracle and/or its affiliates.38
compartment_ocid (2)
Copyright @ 2020 Oracle and/or its affiliates.39
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.40
SSH Keys
You need to specify keys to connect in ssh to the compute instances (only via the bastion
host to the MySQL InnoDB Cluster nodes).
Copyright @ 2020 Oracle and/or its affiliates.41
SSH Keys
You need to specify keys to connect in ssh to the compute instances (only via the bastion
host to the MySQL InnoDB Cluster nodes).
Pay a ention to provide the full path and to verify that the private keys are those without
.pub !
Copyright @ 2020 Oracle and/or its affiliates.41
SSH Keys
You need to specify keys to connect in ssh to the compute instances (only via the bastion
host to the MySQL InnoDB Cluster nodes).
Pay a ention to provide the full path and to verify that the private keys are those without
.pub !
ssh_authorized_keys_path = "/home/fred/.ssh/id_rsa_oci.pub"
ssh_private_key_path = "/home/fred/.ssh/id_rsa_oci"
Copyright @ 2020 Oracle and/or its affiliates.41
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.42
Cluster information
The dedicated user that we create is called clusteradmin and you can specify its password.
You can also specify and name for the cluster.
clusteradmin_password = "MyB1gPassw0rd!"
cluster_name = "MyClusterInOCI"
Copyright @ 2020 Oracle and/or its affiliates.43
Cluster information
The dedicated user that we create is called clusteradmin and you can specify its password.
You can also specify and name for the cluster.
clusteradmin_password = "MyB1gPassw0rd!"
cluster_name = "MyClusterInOCI"
You can also specify the number of nodes that needs to be deployed in your cluster. 3 is
the recommended amount but for testing purpose when you develop your Terraform
recipes, you can reduce it.
number_of_nodes = "2"
Copyright @ 2020 Oracle and/or its affiliates.43
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
Copyright @ 2020 Oracle and/or its affiliates.44
More info on
h ps://docs.cloud.oracle.com/en-
us/iaas/Content/Compute/References/compute
Node Shape
This speci es the Compute Instance's Shape. Of course it depends on your limits.
You can nd the di erent shapes on OCI Dashboard:
Copyright @ 2020 Oracle and/or its affiliates.45
Node Shape (2)
Using the Free Trier provided today, the node shape should be VM.Standard.E2.1
Copyright @ 2020 Oracle and/or its affiliates.46
terraform.tvars
tenancy_ocid = "<REPLACE_ME>"
user_ocid = "<REPLACE_ME>"
fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX"
private_key_path = "<REPLACE_ME>.pem"
region = "<REPLACE_ME>"
compartment_ocid = "<REPLACE_ME>"
ssh_authorized_keys_path = "<REPLACE_ME>"
ssh_private_key_path = "<REPLACE_ME>"
clusteradmin_password = "<REPLACE_ME>"
cluster_name = "MyClusterInOCI"
number_of_nodes = "3"
node_shape = "VM.Standard.E2.1"
node_image_id="ocid1.image..."
Copyright @ 2020 Oracle and/or its affiliates.47
Oracle Linux 8.2-2020.07.28-0 is for example:
eu-
frankfurt-
1
ocid1.image.oc1.eu-frankfurt-
1.aaaaaaaau6ypymprt22fhkenua6fbz2mhy62kdbn6zskrv3fy7fdrq c4ka
us-
ashburn-
1
ocid1.image.oc1.iad.aaaaaaaa7loygdwzmew3hud3bqjyzamzqnz3krpiuhjb3z3u5s3hmmtar6mq
node_image_id - (optional)
This is the ocid of the compute instance you will use. For this demo, we will use the same
on all nodes. The image depends of your region.
You can nd the list of images on h ps://docs.cloud.oracle.com/en-us/iaas/images/
Copyright @ 2020 Oracle and/or its affiliates.48
Oracle Linux 8.2-2020.07.28-0 is for example:
eu-
frankfurt-
1
ocid1.image.oc1.eu-frankfurt-
1.aaaaaaaau6ypymprt22fhkenua6fbz2mhy62kdbn6zskrv3fy7fdrq c4ka
us-
ashburn-
1
ocid1.image.oc1.iad.aaaaaaaa7loygdwzmew3hud3bqjyzamzqnz3krpiuhjb3z3u5s3hmmtar6mq
node_image_id - (optional)
This is the ocid of the compute instance you will use. For this demo, we will use the same
on all nodes. The image depends of your region.
You can nd the list of images on h ps://docs.cloud.oracle.com/en-us/iaas/images/
If you don't specify any, Oracle Linux 8 images in your region
will be used.
Copyright @ 2020 Oracle and/or its affiliates.48
LAB 2
Copyright @ 2020 Oracle and/or its affiliates.49
LAB 2
ready ? update your feedback !
Copyright @ 2020 Oracle and/or its affiliates.49
Terraform in action
It's time to deploy !
Copyright @ 2020 Oracle and/or its affiliates.50
Terraform
Now that everything is setup, we need to init our environment:
$ terraform init
Copyright @ 2020 Oracle and/or its affiliates.51
Terraform
Now that everything is setup, we need to init our environment:
$ terraform init
Copyright @ 2020 Oracle and/or its affiliates.51
Terraform - plan
Let's see if everything is correct and what the system will deploy in OCI using the plan
command:
$ terraform plan
Copyright @ 2020 Oracle and/or its affiliates.52
Terraform - plan
Let's see if everything is correct and what the system will deploy in OCI using the plan
command:
$ terraform plan
Copyright @ 2020 Oracle and/or its affiliates.52
Terraform - deployment
Let's deploy our infrastructure with apply:
$ terraform apply
Copyright @ 2020 Oracle and/or its affiliates.53
Terraform - deployment
Let's deploy our infrastructure with apply:
$ terraform apply
Copyright @ 2020 Oracle and/or its affiliates.53
Terraform - deployment (2)
While the deployment is happening, you can verify in OCI Dashboard, the creation of the
compute instances:
Copyright @ 2020 Oracle and/or its affiliates.54
Terraform - deployment (3)
Copyright @ 2020 Oracle and/or its affiliates.55
LAB 3
Copyright @ 2020 Oracle and/or its affiliates.56
LAB 3
ready ? update your feedback !
Copyright @ 2020 Oracle and/or its affiliates.56
Let's verify
MySQL InnoDB Cluster
Copyright @ 2020 Oracle and/or its affiliates.57
Connection to the Bastion Host
To connect to the bastion host, we use ssh with the user opc on the public IP (use yours!)
and the ssh key we created:
Copyright @ 2020 Oracle and/or its affiliates.58
MySQL InnoDB Cluster
Let's connect to the cluster using MySQL Shell
Copyright @ 2020 Oracle and/or its affiliates.59
MySQL InnoDB Cluster - Status
Copyright @ 2020 Oracle and/or its affiliates.60
MySQL InnoDB Cluster - Router
Copyright @ 2020 Oracle and/or its affiliates.61
MySQL InnoDB Cluster - Router
For security reason, we didn't open the MySQL Router ports on the public IP.
Copyright @ 2020 Oracle and/or its affiliates.61
LAB 4
Copyright @ 2020 Oracle and/or its affiliates.62
LAB 4
ready ? update your feedback !
Copyright @ 2020 Oracle and/or its affiliates.62
House keeping, you only pay what you
consume !
Cleaning up !
Copyright @ 2020 Oracle and/or its affiliates.63
Terraform - terminating our environment
It's also very easy to terminate everything using the destroy command:
$ terraform destroy
Copyright @ 2020 Oracle and/or its affiliates.64
Terraform - terminating our environment
It's also very easy to terminate everything using the destroy command:
$ terraform destroy
Copyright @ 2020 Oracle and/or its affiliates.64
Terraform - terminating our environment
It's also very easy to terminate everything using the destroy command:
$ terraform destroy
Copyright @ 2020 Oracle and/or its affiliates.64
LAB 5
Copyright @ 2020 Oracle and/or its affiliates.65
LAB 5
ready ? update your feedback !
Copyright @ 2020 Oracle and/or its affiliates.65
OCI Resource Manager
... and now for smart & lazy people ;-)
Copyright @ 2020 Oracle and/or its affiliates.66
OCI Resource Manager
It's also possible to deploy without pain, the same architecture using OCI Resource and
Stacks !
Copyright @ 2020 Oracle and/or its affiliates.67
OCI Resource Manager - stack creation
Let's create our stack:
Copyright @ 2020 Oracle and/or its affiliates.68
OCI Resource Manager - stack creation (2)
Now we can download the stack package on h ps://github.com/lefred/oci-mysql-
idc/releases/tag/1.1.0
Copyright @ 2020 Oracle and/or its affiliates.69
OCI Resource Manager - stack creation (3)
Just drop the zip le here:
Copyright @ 2020 Oracle and/or its affiliates.70
OCI Resource Manager - stack creation (5)
Fill some variables:
Copyright @ 2020 Oracle and/or its affiliates.71
OCI Resource Manager - stack creation (6)
Let's start with only 1 MySQL InnoDB Cluster node:
Copyright @ 2020 Oracle and/or its affiliates.72
OCI Resource Manager - stack creation review
We can review the variables and create it:
Copyright @ 2020 Oracle and/or its affiliates.73
OCI Resource Manager - jobs
The rst job we will run it the plan to see what will be the required modi cations:
Copyright @ 2020 Oracle and/or its affiliates.74
OCI Resource Manager - jobs (2)
If all went well, we will see it as succeeded:
Copyright @ 2020 Oracle and/or its affiliates.75
OCI Resource Manager - apply job
As the plan succeeded, we can apply our code for this infrastructure:
Copyright @ 2020 Oracle and/or its affiliates.76
OCI Resource Manager - apply job (2)
It's possible to follow the process in "real time" in the logs:
Copyright @ 2020 Oracle and/or its affiliates.77
The Terraform output
is a bit di erent as
everything was
handled by the stack.
All required SSH keys
were also created:
OCI Resource Manager - apply job (3)
Copyright @ 2020 Oracle and/or its affiliates.78
OCI Resource Manager - compute instances
Of course the compute instances were created:
Copyright @ 2020 Oracle and/or its affiliates.79
Connection
We need to copy the SSH private key from the jobs output in a le if we want to connect to
the bastion host. We also need to change the ownership of it:
$ vi priv.key
<-- paste the content in the file and save it -->
$ chmod 600 priv.key
$ ssh -i priv.key opc@130.61.xx.xx
[opc@mysqlshellbastion ~]$
Copyright @ 2020 Oracle and/or its affiliates.80
LAB 6
Copyright @ 2020 Oracle and/or its affiliates.81
LAB 6
ready ? update your feedback !
Copyright @ 2020 Oracle and/or its affiliates.81
Oracle Developer Live: Deploying MySQL InnoDB Cluster on OCI with Terraform
Thank you !
Copyright @ 2020 Oracle and/or its affiliates.83
Q&A
Copyright @ 2020 Oracle and/or its affiliates.84
Only for HOL
Oracle Developer Live: Deploying MySQL InnoDB Cluster on OCI with Terraform
Ad

Recommended

the State of the Dolphin - October 2020
the State of the Dolphin - October 2020
Frederic Descamps
 
Les nouveautés de MySQL 8.0
Les nouveautés de MySQL 8.0
Frederic Descamps
 
MySQL Database Service Webinar: Upgrading from on-premise MySQL to MDS
MySQL Database Service Webinar: Upgrading from on-premise MySQL to MDS
Frederic Descamps
 
MySQL Database Service Webinar: Installing Drupal in oci with mds
MySQL Database Service Webinar: Installing Drupal in oci with mds
Frederic Descamps
 
Deploying Magento on OCI with MDS
Deploying Magento on OCI with MDS
Frederic Descamps
 
Cloud native - Why to use MySQL 8.0 and how to use it on oci with MDS
Cloud native - Why to use MySQL 8.0 and how to use it on oci with MDS
Frederic Descamps
 
MySQL Router REST API
MySQL Router REST API
Frederic Descamps
 
MySQL Tech Café #8: MySQL 8.0 for Python Developers
MySQL Tech Café #8: MySQL 8.0 for Python Developers
Frederic Descamps
 
MySQL Shell for DBAs
MySQL Shell for DBAs
Frederic Descamps
 
Les nouveautés de MySQL 8.0
Les nouveautés de MySQL 8.0
Frederic Descamps
 
State of The Dolphin - May 2021
State of The Dolphin - May 2021
Frederic Descamps
 
From single MySQL instance to High Availability: the journey to MySQL InnoDB ...
From single MySQL instance to High Availability: the journey to MySQL InnoDB ...
Frederic Descamps
 
FOSDEM 2022 MySQL Devroom: MySQL 8.0 - Logical Backups, Snapshots and Point-...
FOSDEM 2022 MySQL Devroom: MySQL 8.0 - Logical Backups, Snapshots and Point-...
Frederic Descamps
 
MySQL Group Replication: Handling Network Glitches - Best Practices
MySQL Group Replication: Handling Network Glitches - Best Practices
Frederic Descamps
 
Open Source 101 2022 - MySQL Indexes and Histograms
Open Source 101 2022 - MySQL Indexes and Histograms
Frederic Descamps
 
MySQL 8.0 Document Store - Discovery of a New World
MySQL 8.0 Document Store - Discovery of a New World
Frederic Descamps
 
Pi Day 2022 - from IoT to MySQL HeatWave Database Service
Pi Day 2022 - from IoT to MySQL HeatWave Database Service
Frederic Descamps
 
MySQL Day Virtual: Best Practices Tips - Upgrading to MySQL 8.0
MySQL Day Virtual: Best Practices Tips - Upgrading to MySQL 8.0
Frederic Descamps
 
UAE MySQL Users Group Meet-up : MySQL Shell Document Store & more...
UAE MySQL Users Group Meet-up : MySQL Shell Document Store & more...
Frederic Descamps
 
MySQL Shell - the best DBA tool !
MySQL Shell - the best DBA tool !
Frederic Descamps
 
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
Frederic Descamps
 
MySQL Database Service Webinar - Installing WordPress in OCI with MDS
MySQL Database Service Webinar - Installing WordPress in OCI with MDS
Frederic Descamps
 
Another MySQL HA Solution for ProxySQL Users, Easy and All Integrated: MySQL ...
Another MySQL HA Solution for ProxySQL Users, Easy and All Integrated: MySQL ...
Frederic Descamps
 
MySQL InnoDB Cluster - Advanced Configuration & Operations
MySQL InnoDB Cluster - Advanced Configuration & Operations
Frederic Descamps
 
Oracle Open World Middle East - MySQL 8 a Giant Leap for SQL
Oracle Open World Middle East - MySQL 8 a Giant Leap for SQL
Frederic Descamps
 
Mysql Fun
Mysql Fun
SHC
 
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
Frederic Descamps
 
MySQL InnoDB Cluster and Group Replication in a Nutshell
MySQL InnoDB Cluster and Group Replication in a Nutshell
Frederic Descamps
 
Mastering Terraform and the Provider for OCI
Mastering Terraform and the Provider for OCI
Gregory GUILLOU
 
Oracle Cloud deployment with Terraform
Oracle Cloud deployment with Terraform
Stefan Oehrli
 

More Related Content

What's hot (20)

MySQL Shell for DBAs
MySQL Shell for DBAs
Frederic Descamps
 
Les nouveautés de MySQL 8.0
Les nouveautés de MySQL 8.0
Frederic Descamps
 
State of The Dolphin - May 2021
State of The Dolphin - May 2021
Frederic Descamps
 
From single MySQL instance to High Availability: the journey to MySQL InnoDB ...
From single MySQL instance to High Availability: the journey to MySQL InnoDB ...
Frederic Descamps
 
FOSDEM 2022 MySQL Devroom: MySQL 8.0 - Logical Backups, Snapshots and Point-...
FOSDEM 2022 MySQL Devroom: MySQL 8.0 - Logical Backups, Snapshots and Point-...
Frederic Descamps
 
MySQL Group Replication: Handling Network Glitches - Best Practices
MySQL Group Replication: Handling Network Glitches - Best Practices
Frederic Descamps
 
Open Source 101 2022 - MySQL Indexes and Histograms
Open Source 101 2022 - MySQL Indexes and Histograms
Frederic Descamps
 
MySQL 8.0 Document Store - Discovery of a New World
MySQL 8.0 Document Store - Discovery of a New World
Frederic Descamps
 
Pi Day 2022 - from IoT to MySQL HeatWave Database Service
Pi Day 2022 - from IoT to MySQL HeatWave Database Service
Frederic Descamps
 
MySQL Day Virtual: Best Practices Tips - Upgrading to MySQL 8.0
MySQL Day Virtual: Best Practices Tips - Upgrading to MySQL 8.0
Frederic Descamps
 
UAE MySQL Users Group Meet-up : MySQL Shell Document Store & more...
UAE MySQL Users Group Meet-up : MySQL Shell Document Store & more...
Frederic Descamps
 
MySQL Shell - the best DBA tool !
MySQL Shell - the best DBA tool !
Frederic Descamps
 
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
Frederic Descamps
 
MySQL Database Service Webinar - Installing WordPress in OCI with MDS
MySQL Database Service Webinar - Installing WordPress in OCI with MDS
Frederic Descamps
 
Another MySQL HA Solution for ProxySQL Users, Easy and All Integrated: MySQL ...
Another MySQL HA Solution for ProxySQL Users, Easy and All Integrated: MySQL ...
Frederic Descamps
 
MySQL InnoDB Cluster - Advanced Configuration & Operations
MySQL InnoDB Cluster - Advanced Configuration & Operations
Frederic Descamps
 
Oracle Open World Middle East - MySQL 8 a Giant Leap for SQL
Oracle Open World Middle East - MySQL 8 a Giant Leap for SQL
Frederic Descamps
 
Mysql Fun
Mysql Fun
SHC
 
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
Frederic Descamps
 
MySQL InnoDB Cluster and Group Replication in a Nutshell
MySQL InnoDB Cluster and Group Replication in a Nutshell
Frederic Descamps
 
Les nouveautés de MySQL 8.0
Les nouveautés de MySQL 8.0
Frederic Descamps
 
State of The Dolphin - May 2021
State of The Dolphin - May 2021
Frederic Descamps
 
From single MySQL instance to High Availability: the journey to MySQL InnoDB ...
From single MySQL instance to High Availability: the journey to MySQL InnoDB ...
Frederic Descamps
 
FOSDEM 2022 MySQL Devroom: MySQL 8.0 - Logical Backups, Snapshots and Point-...
FOSDEM 2022 MySQL Devroom: MySQL 8.0 - Logical Backups, Snapshots and Point-...
Frederic Descamps
 
MySQL Group Replication: Handling Network Glitches - Best Practices
MySQL Group Replication: Handling Network Glitches - Best Practices
Frederic Descamps
 
Open Source 101 2022 - MySQL Indexes and Histograms
Open Source 101 2022 - MySQL Indexes and Histograms
Frederic Descamps
 
MySQL 8.0 Document Store - Discovery of a New World
MySQL 8.0 Document Store - Discovery of a New World
Frederic Descamps
 
Pi Day 2022 - from IoT to MySQL HeatWave Database Service
Pi Day 2022 - from IoT to MySQL HeatWave Database Service
Frederic Descamps
 
MySQL Day Virtual: Best Practices Tips - Upgrading to MySQL 8.0
MySQL Day Virtual: Best Practices Tips - Upgrading to MySQL 8.0
Frederic Descamps
 
UAE MySQL Users Group Meet-up : MySQL Shell Document Store & more...
UAE MySQL Users Group Meet-up : MySQL Shell Document Store & more...
Frederic Descamps
 
MySQL Shell - the best DBA tool !
MySQL Shell - the best DBA tool !
Frederic Descamps
 
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
Frederic Descamps
 
MySQL Database Service Webinar - Installing WordPress in OCI with MDS
MySQL Database Service Webinar - Installing WordPress in OCI with MDS
Frederic Descamps
 
Another MySQL HA Solution for ProxySQL Users, Easy and All Integrated: MySQL ...
Another MySQL HA Solution for ProxySQL Users, Easy and All Integrated: MySQL ...
Frederic Descamps
 
MySQL InnoDB Cluster - Advanced Configuration & Operations
MySQL InnoDB Cluster - Advanced Configuration & Operations
Frederic Descamps
 
Oracle Open World Middle East - MySQL 8 a Giant Leap for SQL
Oracle Open World Middle East - MySQL 8 a Giant Leap for SQL
Frederic Descamps
 
Mysql Fun
Mysql Fun
SHC
 
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
Frederic Descamps
 
MySQL InnoDB Cluster and Group Replication in a Nutshell
MySQL InnoDB Cluster and Group Replication in a Nutshell
Frederic Descamps
 

Similar to Oracle Developer Live: Deploying MySQL InnoDB Cluster on OCI with Terraform (20)

Mastering Terraform and the Provider for OCI
Mastering Terraform and the Provider for OCI
Gregory GUILLOU
 
Oracle Cloud deployment with Terraform
Oracle Cloud deployment with Terraform
Stefan Oehrli
 
Getting Started with Terraform
Getting Started with Terraform
Revelation Technologies
 
Terraform & Oracle Cloud Infrastructure
Terraform & Oracle Cloud Infrastructure
Bobby Curtis
 
Automate your oracle cloud infrastructure operations v2.0 - OOW19
Automate your oracle cloud infrastructure operations v2.0 - OOW19
Nelson Calero
 
OCI Oracle Functions Deployment
OCI Oracle Functions Deployment
Toni Epple
 
OracleBeer_Terraform_soe.pdf
OracleBeer_Terraform_soe.pdf
Stefan Oehrli
 
Oracle Cloud Infrastructure Foundations Associate_Hand-On.pdf
Oracle Cloud Infrastructure Foundations Associate_Hand-On.pdf
Ilidio Mimiel
 
Terraform introduction
Terraform introduction
Jason Vance
 
Oracle Cloud - Infrastruktura jako kód
Oracle Cloud - Infrastruktura jako kód
MarketingArrowECS_CZ
 
Part 5 of the REAL Webinars on Oracle Cloud Native Application Development - ...
Part 5 of the REAL Webinars on Oracle Cloud Native Application Development - ...
Lucas Jellema
 
Automate the operation of your Oracle Cloud infrastructure v2.0
Automate the operation of your Oracle Cloud infrastructure v2.0
Nelson Calero
 
Better Practices when Using Terraform to Manage Oracle Cloud Infrastructure
Better Practices when Using Terraform to Manage Oracle Cloud Infrastructure
Simon Haslam
 
ECO 2022 - OCI and HashiCorp Terraform
ECO 2022 - OCI and HashiCorp Terraform
Bobby Curtis
 
Part 1 of the REAL Webinars on Oracle Cloud Native Application Development
Part 1 of the REAL Webinars on Oracle Cloud Native Application Development
Lucas Jellema
 
How to get started with Oracle Cloud Infrastructure
How to get started with Oracle Cloud Infrastructure
Simo Vilmunen
 
Final terraform
Final terraform
Gourav Varma
 
Terraform
Terraform
Phil Wilkins
 
Terraform with OCI
Terraform with OCI
JeSam Kim
 
Discovering OpenBSD on AWS
Discovering OpenBSD on AWS
Laurent Bernaille
 
Mastering Terraform and the Provider for OCI
Mastering Terraform and the Provider for OCI
Gregory GUILLOU
 
Oracle Cloud deployment with Terraform
Oracle Cloud deployment with Terraform
Stefan Oehrli
 
Terraform & Oracle Cloud Infrastructure
Terraform & Oracle Cloud Infrastructure
Bobby Curtis
 
Automate your oracle cloud infrastructure operations v2.0 - OOW19
Automate your oracle cloud infrastructure operations v2.0 - OOW19
Nelson Calero
 
OCI Oracle Functions Deployment
OCI Oracle Functions Deployment
Toni Epple
 
OracleBeer_Terraform_soe.pdf
OracleBeer_Terraform_soe.pdf
Stefan Oehrli
 
Oracle Cloud Infrastructure Foundations Associate_Hand-On.pdf
Oracle Cloud Infrastructure Foundations Associate_Hand-On.pdf
Ilidio Mimiel
 
Terraform introduction
Terraform introduction
Jason Vance
 
Oracle Cloud - Infrastruktura jako kód
Oracle Cloud - Infrastruktura jako kód
MarketingArrowECS_CZ
 
Part 5 of the REAL Webinars on Oracle Cloud Native Application Development - ...
Part 5 of the REAL Webinars on Oracle Cloud Native Application Development - ...
Lucas Jellema
 
Automate the operation of your Oracle Cloud infrastructure v2.0
Automate the operation of your Oracle Cloud infrastructure v2.0
Nelson Calero
 
Better Practices when Using Terraform to Manage Oracle Cloud Infrastructure
Better Practices when Using Terraform to Manage Oracle Cloud Infrastructure
Simon Haslam
 
ECO 2022 - OCI and HashiCorp Terraform
ECO 2022 - OCI and HashiCorp Terraform
Bobby Curtis
 
Part 1 of the REAL Webinars on Oracle Cloud Native Application Development
Part 1 of the REAL Webinars on Oracle Cloud Native Application Development
Lucas Jellema
 
How to get started with Oracle Cloud Infrastructure
How to get started with Oracle Cloud Infrastructure
Simo Vilmunen
 
Terraform with OCI
Terraform with OCI
JeSam Kim
 
Ad

More from Frederic Descamps (12)

MySQL Innovation & Cloud Day - Document Store avec MySQL HeatWave Database Se...
MySQL Innovation & Cloud Day - Document Store avec MySQL HeatWave Database Se...
Frederic Descamps
 
MySQL Day Roma - MySQL Shell and Visual Studio Code Extension
MySQL Day Roma - MySQL Shell and Visual Studio Code Extension
Frederic Descamps
 
RivieraJUG - MySQL Indexes and Histograms
RivieraJUG - MySQL Indexes and Histograms
Frederic Descamps
 
RivieraJUG - MySQL 8.0 - What's new for developers.pdf
RivieraJUG - MySQL 8.0 - What's new for developers.pdf
Frederic Descamps
 
MySQL User Group NL - MySQL 8
MySQL User Group NL - MySQL 8
Frederic Descamps
 
State of the Dolphin - May 2022
State of the Dolphin - May 2022
Frederic Descamps
 
Percona Live 2022 - MySQL Shell for Visual Studio Code
Percona Live 2022 - MySQL Shell for Visual Studio Code
Frederic Descamps
 
Percona Live 2022 - The Evolution of a MySQL Database System
Percona Live 2022 - The Evolution of a MySQL Database System
Frederic Descamps
 
Percona Live 2022 - MySQL Architectures
Percona Live 2022 - MySQL Architectures
Frederic Descamps
 
LinuxFest Northwest 2022 - The Evolution of a MySQL Database System
LinuxFest Northwest 2022 - The Evolution of a MySQL Database System
Frederic Descamps
 
Confoo 2022 - le cycle d'une instance MySQL
Confoo 2022 - le cycle d'une instance MySQL
Frederic Descamps
 
OpenExpo Virtual Experience 2020: MySQL 8.0 Document Store - Discovery of a n...
OpenExpo Virtual Experience 2020: MySQL 8.0 Document Store - Discovery of a n...
Frederic Descamps
 
MySQL Innovation & Cloud Day - Document Store avec MySQL HeatWave Database Se...
MySQL Innovation & Cloud Day - Document Store avec MySQL HeatWave Database Se...
Frederic Descamps
 
MySQL Day Roma - MySQL Shell and Visual Studio Code Extension
MySQL Day Roma - MySQL Shell and Visual Studio Code Extension
Frederic Descamps
 
RivieraJUG - MySQL Indexes and Histograms
RivieraJUG - MySQL Indexes and Histograms
Frederic Descamps
 
RivieraJUG - MySQL 8.0 - What's new for developers.pdf
RivieraJUG - MySQL 8.0 - What's new for developers.pdf
Frederic Descamps
 
MySQL User Group NL - MySQL 8
MySQL User Group NL - MySQL 8
Frederic Descamps
 
State of the Dolphin - May 2022
State of the Dolphin - May 2022
Frederic Descamps
 
Percona Live 2022 - MySQL Shell for Visual Studio Code
Percona Live 2022 - MySQL Shell for Visual Studio Code
Frederic Descamps
 
Percona Live 2022 - The Evolution of a MySQL Database System
Percona Live 2022 - The Evolution of a MySQL Database System
Frederic Descamps
 
Percona Live 2022 - MySQL Architectures
Percona Live 2022 - MySQL Architectures
Frederic Descamps
 
LinuxFest Northwest 2022 - The Evolution of a MySQL Database System
LinuxFest Northwest 2022 - The Evolution of a MySQL Database System
Frederic Descamps
 
Confoo 2022 - le cycle d'une instance MySQL
Confoo 2022 - le cycle d'une instance MySQL
Frederic Descamps
 
OpenExpo Virtual Experience 2020: MySQL 8.0 Document Store - Discovery of a n...
OpenExpo Virtual Experience 2020: MySQL 8.0 Document Store - Discovery of a n...
Frederic Descamps
 
Ad

Recently uploaded (20)

vertical-cnc-processing-centers-drillteq-v-200-en.pdf
vertical-cnc-processing-centers-drillteq-v-200-en.pdf
AmirStern2
 
AI vs Human Writing: Can You Tell the Difference?
AI vs Human Writing: Can You Tell the Difference?
Shashi Sathyanarayana, Ph.D
 
ENERGY CONSUMPTION CALCULATION IN ENERGY-EFFICIENT AIR CONDITIONER.pdf
ENERGY CONSUMPTION CALCULATION IN ENERGY-EFFICIENT AIR CONDITIONER.pdf
Muhammad Rizwan Akram
 
Integration of Utility Data into 3D BIM Models Using a 3D Solids Modeling Wor...
Integration of Utility Data into 3D BIM Models Using a 3D Solids Modeling Wor...
Safe Software
 
OpenACC and Open Hackathons Monthly Highlights June 2025
OpenACC and Open Hackathons Monthly Highlights June 2025
OpenACC
 
Floods in Valencia: Two FME-Powered Stories of Data Resilience
Floods in Valencia: Two FME-Powered Stories of Data Resilience
Safe Software
 
TrustArc Webinar - 2025 Global Privacy Survey
TrustArc Webinar - 2025 Global Privacy Survey
TrustArc
 
No-Code Workflows for CAD & 3D Data: Scaling AI-Driven Infrastructure
No-Code Workflows for CAD & 3D Data: Scaling AI-Driven Infrastructure
Safe Software
 
OWASP Barcelona 2025 Threat Model Library
OWASP Barcelona 2025 Threat Model Library
PetraVukmirovic
 
“From Enterprise to Makers: Driving Vision AI Innovation at the Extreme Edge,...
“From Enterprise to Makers: Driving Vision AI Innovation at the Extreme Edge,...
Edge AI and Vision Alliance
 
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Alliance
 
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik
 
Viral>Wondershare Filmora 14.5.18.12900 Crack Free Download
Viral>Wondershare Filmora 14.5.18.12900 Crack Free Download
Puppy jhon
 
MuleSoft for AgentForce : Topic Center and API Catalog
MuleSoft for AgentForce : Topic Center and API Catalog
shyamraj55
 
FIDO Alliance Seminar State of Passkeys.pptx
FIDO Alliance Seminar State of Passkeys.pptx
FIDO Alliance
 
The State of Web3 Industry- Industry Report
The State of Web3 Industry- Industry Report
Liveplex
 
Crypto Super 500 - 14th Report - June2025.pdf
Crypto Super 500 - 14th Report - June2025.pdf
Stephen Perrenod
 
Providing an OGC API Processes REST Interface for FME Flow
Providing an OGC API Processes REST Interface for FME Flow
Safe Software
 
Kubernetes Security Act Now Before It’s Too Late
Kubernetes Security Act Now Before It’s Too Late
Michael Furman
 
Mastering AI Workflows with FME - Peak of Data & AI 2025
Mastering AI Workflows with FME - Peak of Data & AI 2025
Safe Software
 
vertical-cnc-processing-centers-drillteq-v-200-en.pdf
vertical-cnc-processing-centers-drillteq-v-200-en.pdf
AmirStern2
 
AI vs Human Writing: Can You Tell the Difference?
AI vs Human Writing: Can You Tell the Difference?
Shashi Sathyanarayana, Ph.D
 
ENERGY CONSUMPTION CALCULATION IN ENERGY-EFFICIENT AIR CONDITIONER.pdf
ENERGY CONSUMPTION CALCULATION IN ENERGY-EFFICIENT AIR CONDITIONER.pdf
Muhammad Rizwan Akram
 
Integration of Utility Data into 3D BIM Models Using a 3D Solids Modeling Wor...
Integration of Utility Data into 3D BIM Models Using a 3D Solids Modeling Wor...
Safe Software
 
OpenACC and Open Hackathons Monthly Highlights June 2025
OpenACC and Open Hackathons Monthly Highlights June 2025
OpenACC
 
Floods in Valencia: Two FME-Powered Stories of Data Resilience
Floods in Valencia: Two FME-Powered Stories of Data Resilience
Safe Software
 
TrustArc Webinar - 2025 Global Privacy Survey
TrustArc Webinar - 2025 Global Privacy Survey
TrustArc
 
No-Code Workflows for CAD & 3D Data: Scaling AI-Driven Infrastructure
No-Code Workflows for CAD & 3D Data: Scaling AI-Driven Infrastructure
Safe Software
 
OWASP Barcelona 2025 Threat Model Library
OWASP Barcelona 2025 Threat Model Library
PetraVukmirovic
 
“From Enterprise to Makers: Driving Vision AI Innovation at the Extreme Edge,...
“From Enterprise to Makers: Driving Vision AI Innovation at the Extreme Edge,...
Edge AI and Vision Alliance
 
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Seminar: Perspectives on Passkeys & Consumer Adoption.pptx
FIDO Alliance
 
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik - Passionate Tech Enthusiast
Raman Bhaumik
 
Viral>Wondershare Filmora 14.5.18.12900 Crack Free Download
Viral>Wondershare Filmora 14.5.18.12900 Crack Free Download
Puppy jhon
 
MuleSoft for AgentForce : Topic Center and API Catalog
MuleSoft for AgentForce : Topic Center and API Catalog
shyamraj55
 
FIDO Alliance Seminar State of Passkeys.pptx
FIDO Alliance Seminar State of Passkeys.pptx
FIDO Alliance
 
The State of Web3 Industry- Industry Report
The State of Web3 Industry- Industry Report
Liveplex
 
Crypto Super 500 - 14th Report - June2025.pdf
Crypto Super 500 - 14th Report - June2025.pdf
Stephen Perrenod
 
Providing an OGC API Processes REST Interface for FME Flow
Providing an OGC API Processes REST Interface for FME Flow
Safe Software
 
Kubernetes Security Act Now Before It’s Too Late
Kubernetes Security Act Now Before It’s Too Late
Michael Furman
 
Mastering AI Workflows with FME - Peak of Data & AI 2025
Mastering AI Workflows with FME - Peak of Data & AI 2025
Safe Software
 

Oracle Developer Live: Deploying MySQL InnoDB Cluster on OCI with Terraform

  • 1. Deploying MySQL InnoDB Cluster on OCI with Terraform Oracle Developer Live Frédéric Descamps Community Manager MySQL
  • 2. Who am I ? about.me/lefred Copyright @ 2020 Oracle and/or its affiliates.2
  • 3. @lefred MySQL Evangelist Managing MySQL since 3.20 devops believer living in Belgium h ps://lefred.be Frédéric Descamps Copyright @ 2020 Oracle and/or its affiliates.3
  • 4. Sign up Oracle Cloud Free Trier Copyright @ 2020 Oracle and/or its affiliates.4
  • 5. Copyright @ 2020 Oracle and/or its affiliates.5
  • 6. Breakout Lab Support Today's Experts Standing By: - Miguel - Dave - Olivier - Ted - Vi orio Have a Question? Direct your question via chat to one of our experts above or the instructor. Breakout Rooms If you are not able to get your question answered within the chat, we have breakout rooms available for you. We ask that if your question requires the use of a breakout room, that the time within the breakout room remains brief to ensure experts can assist others in need of help. Copyright @ 2020 Oracle and/or its affiliates.6
  • 7. use only Germany Central (Frankfurt) !! and use the same email you used to register to this session Prerequisites Please create your OCI free account following all the instructions from the Livelabs: h ps://oracle.github.io/learning-library/oci-library/oci-hol/odl-mysql-idc-terraform-hol- master/workshops/freetier/ Copyright @ 2020 Oracle and/or its affiliates.7
  • 8. Free Trier: note on always free To perform this lab, you need to use a new Free Trier account provided today. If you have an old one, it might not work if you don't have the free credits. If this is your case you won't be able to: use more than 1 node in your cluster use the NAT gateway and split the databases in a private subnet And you will have to use VM.Standard.E2.1.Micro shape. Copyright @ 2020 Oracle and/or its affiliates.8
  • 9. Infrastructure as Code What is Terraform ? Copyright @ 2020 Oracle and/or its affiliates.9
  • 10. What is Terraform ? Terraform is a tool for building, changing, and versioning infrastructure safely and e ciently. Terraform can manage existing and popular service providers as well as custom in-house solutions. Copyright @ 2020 Oracle and/or its affiliates.10
  • 11. Terraform & OCI Oracle Cloud Infrastructure is supported by Terraform. We provide many OCI quickstarts in github: h ps://github.com/oracle-quickstart/. Copyright @ 2020 Oracle and/or its affiliates.11
  • 12. Terraform & OCI Oracle Cloud Infrastructure is supported by Terraform. We provide many OCI quickstarts in github: h ps://github.com/oracle-quickstart/. Today we will use a contribution to the original MySQL one: h ps://github.com/lefred/oci- mysql-idc.git Copyright @ 2020 Oracle and/or its affiliates.11
  • 13. Architecture What will we deploy ? Copyright @ 2020 Oracle and/or its affiliates.12
  • 14. Architecture MySQL 1 MySQL 3 VCN 10.0.0.0/16 Public Subnet 10.0.0.0/24 Private Subnet 10.0.1.0/24 Private Subnet 10.0.1.0/24 Group Replication Fault Domain 1 Fault Domain2 Fault Domain3 MySQL 2 Bastion Host Copyright @ 2020 Oracle and/or its affiliates.13
  • 15. Get ready Se ing up your environment Copyright @ 2020 Oracle and/or its affiliates.14
  • 16. an OCI account Terraform git ssh client on Windows, for git and ssh, you should use h ps://github.com/git-for-windows/git/releases/latest Se ing up your environment You need: Copyright @ 2020 Oracle and/or its affiliates.15
  • 17. Prerequisites & Introduction Copyright @ 2020 Oracle and/or its affiliates.16
  • 18. Prerequisites & Introduction ready ? update your feedback ! Copyright @ 2020 Oracle and/or its affiliates.16
  • 19. Update your feedback At the end of each LAB, please update your feedback in the participants list: Copyright @ 2020 Oracle and/or its affiliates.17
  • 20. Creating your API keys: $ mkdir ~/.oci $ openssl genrsa -out ~/.oci/oci_api_key.pem 2048 $ chmod go-rwx ~/.oci/oci_api_key.pem $ openssl rsa -pubout -in ~/.oci/oci_api_key.pem -out ~/.oci/oci_api_key_public.pem And for SSH don't provide passphrase: $ ssh-keygen -t rsa Generating public/private rsa key pair. Enter file in which to save the key (/home/fred/.ssh/id_rsa): id_rsa_oci Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in id_rsa_oci Your public key has been saved in id_rsa_oci.pub Prepare your OCI environment Copyright @ 2020 Oracle and/or its affiliates.18
  • 21. Prepare your OCI environment (2) Example for our Windows user friends: Copyright @ 2020 Oracle and/or its affiliates.19
  • 22. Prepare your OCI environment (3) Example for our Windows user friends - API keys: Copyright @ 2020 Oracle and/or its affiliates.20
  • 23. Prepare your OCI environment (4) Example for our Windows user friends - SSH keys: Copyright @ 2020 Oracle and/or its affiliates.21
  • 24. In our example, the key is ~/.oci/oci_api_key_public.pem Prepare your OCI environment - deploy your API key You need to deploy your public API key on OCI: Copyright @ 2020 Oracle and/or its affiliates.22
  • 25. LAB 1 Copyright @ 2020 Oracle and/or its affiliates.23
  • 26. LAB 1 ready ? update your feedback ! Copyright @ 2020 Oracle and/or its affiliates.23
  • 27. Terraform is a unique binary you can download from h ps://www.terraform.io/downloads.html $ cd ~bin $ wget https://releases.hashicorp.com/terraform/0.13.4/terraform_0.13.4_linux_amd64.zip $ unzip terraform_0.13.4_linux_amd64.zip Archive: terraform_0.13.4_linux_amd64.zip inflating: terraform $ terraform --version Terraform v0.13.4 Installing Terraform Copyright @ 2020 Oracle and/or its affiliates.24
  • 28. Installing Terraform (2) Example for our Windows user friends: Copyright @ 2020 Oracle and/or its affiliates.25
  • 29. $ git clone https://github.com/lefred/oci-mysql-idc.git Ge ing the git repo Copyright @ 2020 Oracle and/or its affiliates.26
  • 30. $ git clone https://github.com/lefred/oci-mysql-idc.git Ge ing the git repo Now we need to copy terraform.tfvars.template to edit it: $ cd oci-mysql-idc $ cp terraform.tfvars.template terraform.tfvars Copyright @ 2020 Oracle and/or its affiliates.26
  • 31. $ git clone https://github.com/lefred/oci-mysql-idc.git Ge ing the git repo Now we need to copy terraform.tfvars.template to edit it: $ cd oci-mysql-idc $ cp terraform.tfvars.template terraform.tfvars This is maybe the most complex task of the deployment ;-) Copyright @ 2020 Oracle and/or its affiliates.26
  • 32. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.27
  • 33. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.28
  • 34. tenancy_oid Copyright @ 2020 Oracle and/or its affiliates.29
  • 35. tenancy_oid (2) Copyright @ 2020 Oracle and/or its affiliates.30
  • 36. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.31
  • 37. user_ocid Copyright @ 2020 Oracle and/or its affiliates.32
  • 38. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.33
  • 39. Key & Fingerprint The private_key_path value is the path of oci_api_key.pem: private_key_path = "/home/fred/.oci/oci_api_key.pem" Copyright @ 2020 Oracle and/or its affiliates.34
  • 40. Key & Fingerprint The private_key_path value is the path of oci_api_key.pem: private_key_path = "/home/fred/.oci/oci_api_key.pem" And to get the Fingerprint: Copyright @ 2020 Oracle and/or its affiliates.34
  • 41. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.35
  • 43. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.37
  • 44. compartment_ocid You may or not have setup di erent compartments. I usually use a sandbox for example. Copyright @ 2020 Oracle and/or its affiliates.38
  • 45. compartment_ocid (2) Copyright @ 2020 Oracle and/or its affiliates.39
  • 46. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.40
  • 47. SSH Keys You need to specify keys to connect in ssh to the compute instances (only via the bastion host to the MySQL InnoDB Cluster nodes). Copyright @ 2020 Oracle and/or its affiliates.41
  • 48. SSH Keys You need to specify keys to connect in ssh to the compute instances (only via the bastion host to the MySQL InnoDB Cluster nodes). Pay a ention to provide the full path and to verify that the private keys are those without .pub ! Copyright @ 2020 Oracle and/or its affiliates.41
  • 49. SSH Keys You need to specify keys to connect in ssh to the compute instances (only via the bastion host to the MySQL InnoDB Cluster nodes). Pay a ention to provide the full path and to verify that the private keys are those without .pub ! ssh_authorized_keys_path = "/home/fred/.ssh/id_rsa_oci.pub" ssh_private_key_path = "/home/fred/.ssh/id_rsa_oci" Copyright @ 2020 Oracle and/or its affiliates.41
  • 50. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.42
  • 51. Cluster information The dedicated user that we create is called clusteradmin and you can specify its password. You can also specify and name for the cluster. clusteradmin_password = "MyB1gPassw0rd!" cluster_name = "MyClusterInOCI" Copyright @ 2020 Oracle and/or its affiliates.43
  • 52. Cluster information The dedicated user that we create is called clusteradmin and you can specify its password. You can also specify and name for the cluster. clusteradmin_password = "MyB1gPassw0rd!" cluster_name = "MyClusterInOCI" You can also specify the number of nodes that needs to be deployed in your cluster. 3 is the recommended amount but for testing purpose when you develop your Terraform recipes, you can reduce it. number_of_nodes = "2" Copyright @ 2020 Oracle and/or its affiliates.43
  • 53. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" Copyright @ 2020 Oracle and/or its affiliates.44
  • 54. More info on h ps://docs.cloud.oracle.com/en- us/iaas/Content/Compute/References/compute Node Shape This speci es the Compute Instance's Shape. Of course it depends on your limits. You can nd the di erent shapes on OCI Dashboard: Copyright @ 2020 Oracle and/or its affiliates.45
  • 55. Node Shape (2) Using the Free Trier provided today, the node shape should be VM.Standard.E2.1 Copyright @ 2020 Oracle and/or its affiliates.46
  • 56. terraform.tvars tenancy_ocid = "<REPLACE_ME>" user_ocid = "<REPLACE_ME>" fingerprint= "RE:PL:AC:E_:ME:__:RE:PL:AC:E_:ME:__:XX:XX:XX:XX" private_key_path = "<REPLACE_ME>.pem" region = "<REPLACE_ME>" compartment_ocid = "<REPLACE_ME>" ssh_authorized_keys_path = "<REPLACE_ME>" ssh_private_key_path = "<REPLACE_ME>" clusteradmin_password = "<REPLACE_ME>" cluster_name = "MyClusterInOCI" number_of_nodes = "3" node_shape = "VM.Standard.E2.1" node_image_id="ocid1.image..." Copyright @ 2020 Oracle and/or its affiliates.47
  • 57. Oracle Linux 8.2-2020.07.28-0 is for example: eu- frankfurt- 1 ocid1.image.oc1.eu-frankfurt- 1.aaaaaaaau6ypymprt22fhkenua6fbz2mhy62kdbn6zskrv3fy7fdrq c4ka us- ashburn- 1 ocid1.image.oc1.iad.aaaaaaaa7loygdwzmew3hud3bqjyzamzqnz3krpiuhjb3z3u5s3hmmtar6mq node_image_id - (optional) This is the ocid of the compute instance you will use. For this demo, we will use the same on all nodes. The image depends of your region. You can nd the list of images on h ps://docs.cloud.oracle.com/en-us/iaas/images/ Copyright @ 2020 Oracle and/or its affiliates.48
  • 58. Oracle Linux 8.2-2020.07.28-0 is for example: eu- frankfurt- 1 ocid1.image.oc1.eu-frankfurt- 1.aaaaaaaau6ypymprt22fhkenua6fbz2mhy62kdbn6zskrv3fy7fdrq c4ka us- ashburn- 1 ocid1.image.oc1.iad.aaaaaaaa7loygdwzmew3hud3bqjyzamzqnz3krpiuhjb3z3u5s3hmmtar6mq node_image_id - (optional) This is the ocid of the compute instance you will use. For this demo, we will use the same on all nodes. The image depends of your region. You can nd the list of images on h ps://docs.cloud.oracle.com/en-us/iaas/images/ If you don't specify any, Oracle Linux 8 images in your region will be used. Copyright @ 2020 Oracle and/or its affiliates.48
  • 59. LAB 2 Copyright @ 2020 Oracle and/or its affiliates.49
  • 60. LAB 2 ready ? update your feedback ! Copyright @ 2020 Oracle and/or its affiliates.49
  • 61. Terraform in action It's time to deploy ! Copyright @ 2020 Oracle and/or its affiliates.50
  • 62. Terraform Now that everything is setup, we need to init our environment: $ terraform init Copyright @ 2020 Oracle and/or its affiliates.51
  • 63. Terraform Now that everything is setup, we need to init our environment: $ terraform init Copyright @ 2020 Oracle and/or its affiliates.51
  • 64. Terraform - plan Let's see if everything is correct and what the system will deploy in OCI using the plan command: $ terraform plan Copyright @ 2020 Oracle and/or its affiliates.52
  • 65. Terraform - plan Let's see if everything is correct and what the system will deploy in OCI using the plan command: $ terraform plan Copyright @ 2020 Oracle and/or its affiliates.52
  • 66. Terraform - deployment Let's deploy our infrastructure with apply: $ terraform apply Copyright @ 2020 Oracle and/or its affiliates.53
  • 67. Terraform - deployment Let's deploy our infrastructure with apply: $ terraform apply Copyright @ 2020 Oracle and/or its affiliates.53
  • 68. Terraform - deployment (2) While the deployment is happening, you can verify in OCI Dashboard, the creation of the compute instances: Copyright @ 2020 Oracle and/or its affiliates.54
  • 69. Terraform - deployment (3) Copyright @ 2020 Oracle and/or its affiliates.55
  • 70. LAB 3 Copyright @ 2020 Oracle and/or its affiliates.56
  • 71. LAB 3 ready ? update your feedback ! Copyright @ 2020 Oracle and/or its affiliates.56
  • 72. Let's verify MySQL InnoDB Cluster Copyright @ 2020 Oracle and/or its affiliates.57
  • 73. Connection to the Bastion Host To connect to the bastion host, we use ssh with the user opc on the public IP (use yours!) and the ssh key we created: Copyright @ 2020 Oracle and/or its affiliates.58
  • 74. MySQL InnoDB Cluster Let's connect to the cluster using MySQL Shell Copyright @ 2020 Oracle and/or its affiliates.59
  • 75. MySQL InnoDB Cluster - Status Copyright @ 2020 Oracle and/or its affiliates.60
  • 76. MySQL InnoDB Cluster - Router Copyright @ 2020 Oracle and/or its affiliates.61
  • 77. MySQL InnoDB Cluster - Router For security reason, we didn't open the MySQL Router ports on the public IP. Copyright @ 2020 Oracle and/or its affiliates.61
  • 78. LAB 4 Copyright @ 2020 Oracle and/or its affiliates.62
  • 79. LAB 4 ready ? update your feedback ! Copyright @ 2020 Oracle and/or its affiliates.62
  • 80. House keeping, you only pay what you consume ! Cleaning up ! Copyright @ 2020 Oracle and/or its affiliates.63
  • 81. Terraform - terminating our environment It's also very easy to terminate everything using the destroy command: $ terraform destroy Copyright @ 2020 Oracle and/or its affiliates.64
  • 82. Terraform - terminating our environment It's also very easy to terminate everything using the destroy command: $ terraform destroy Copyright @ 2020 Oracle and/or its affiliates.64
  • 83. Terraform - terminating our environment It's also very easy to terminate everything using the destroy command: $ terraform destroy Copyright @ 2020 Oracle and/or its affiliates.64
  • 84. LAB 5 Copyright @ 2020 Oracle and/or its affiliates.65
  • 85. LAB 5 ready ? update your feedback ! Copyright @ 2020 Oracle and/or its affiliates.65
  • 86. OCI Resource Manager ... and now for smart & lazy people ;-) Copyright @ 2020 Oracle and/or its affiliates.66
  • 87. OCI Resource Manager It's also possible to deploy without pain, the same architecture using OCI Resource and Stacks ! Copyright @ 2020 Oracle and/or its affiliates.67
  • 88. OCI Resource Manager - stack creation Let's create our stack: Copyright @ 2020 Oracle and/or its affiliates.68
  • 89. OCI Resource Manager - stack creation (2) Now we can download the stack package on h ps://github.com/lefred/oci-mysql- idc/releases/tag/1.1.0 Copyright @ 2020 Oracle and/or its affiliates.69
  • 90. OCI Resource Manager - stack creation (3) Just drop the zip le here: Copyright @ 2020 Oracle and/or its affiliates.70
  • 91. OCI Resource Manager - stack creation (5) Fill some variables: Copyright @ 2020 Oracle and/or its affiliates.71
  • 92. OCI Resource Manager - stack creation (6) Let's start with only 1 MySQL InnoDB Cluster node: Copyright @ 2020 Oracle and/or its affiliates.72
  • 93. OCI Resource Manager - stack creation review We can review the variables and create it: Copyright @ 2020 Oracle and/or its affiliates.73
  • 94. OCI Resource Manager - jobs The rst job we will run it the plan to see what will be the required modi cations: Copyright @ 2020 Oracle and/or its affiliates.74
  • 95. OCI Resource Manager - jobs (2) If all went well, we will see it as succeeded: Copyright @ 2020 Oracle and/or its affiliates.75
  • 96. OCI Resource Manager - apply job As the plan succeeded, we can apply our code for this infrastructure: Copyright @ 2020 Oracle and/or its affiliates.76
  • 97. OCI Resource Manager - apply job (2) It's possible to follow the process in "real time" in the logs: Copyright @ 2020 Oracle and/or its affiliates.77
  • 98. The Terraform output is a bit di erent as everything was handled by the stack. All required SSH keys were also created: OCI Resource Manager - apply job (3) Copyright @ 2020 Oracle and/or its affiliates.78
  • 99. OCI Resource Manager - compute instances Of course the compute instances were created: Copyright @ 2020 Oracle and/or its affiliates.79
  • 100. Connection We need to copy the SSH private key from the jobs output in a le if we want to connect to the bastion host. We also need to change the ownership of it: $ vi priv.key <-- paste the content in the file and save it --> $ chmod 600 priv.key $ ssh -i priv.key [email protected] [opc@mysqlshellbastion ~]$ Copyright @ 2020 Oracle and/or its affiliates.80
  • 101. LAB 6 Copyright @ 2020 Oracle and/or its affiliates.81
  • 102. LAB 6 ready ? update your feedback ! Copyright @ 2020 Oracle and/or its affiliates.81
  • 104. Thank you ! Copyright @ 2020 Oracle and/or its affiliates.83
  • 105. Q&A Copyright @ 2020 Oracle and/or its affiliates.84