SlideShare a Scribd company logo
1 of 81
Download to read offline
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Miguel Araújo
Senior Software Developer
MySQL Middleware and Clients
pre-FOSDEM’19 MySQL Day - February 01, 2019
MySQL Shell
A DevOps-engineer day with MySQL’s
development and administration tool
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Safe Harbor Statement
The following is intended to outline our general product direction. It is intended for
information purposes only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied upon
in making purchasing decisions. The development, release, timing, and pricing of any
features or functionality described for Oracle’s products may change and remains at the
sole discretion of Oracle Corporation.
2
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 3
Who am I?
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
whoami
Miguel Araújo
• MySQL Senior Software Developer
• Lead developer for the AdminAPI at the
MySQL Shell team
• MySQL InnoDB Cluster evangelist
• Living in Portugal
• http://about.me/miguel-araujo
4
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 5
DevOps: What is it?
As simple as:
 Engineers (developers) and operations working together to:
Automate and monitor processes
 Share knowledge and collaborate
Get things done faster
Deliver faster!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
DevOps-Engineer: …and that is?
6
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
DevOps-Engineer: …and that is?
¯_(ツ)_/¯
7
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
DevOps-Engineer: …and that is?
8
OK, actually it’s someone that can:
 Do system administration (sysadmin)
 Code
 Understand testing
 Automate processes
 Talk! (bridge between devs and ops)
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
MySQL Shell: Introduction
• Interactive multi-language console interface that supports development and
administration for the MySQL Server
• Can be used to perform data queries or updates, and administration operations:
 Interactively or through batch operations
 With scriptable “DevOps” APIs
 Unified Interface for MySQL Developers and DBAs: one tool!
• Intuitive, flexible, powerful and easy to use!
9
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
MySQL Shell: Features (Dev)
• Multi-language support
– JavaScript, Python and SQL
– Both interactive and batch operations (scripting)
10
MySQL
Development
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
MySQL Shell: Features (Dev)
• Multi-language support
– JavaScript, Python and SQL
– Both interactive and batch operations (scripting)
• Document and relational model
– Supports the classic relational model
– Modern fluent API for the MySQL Document Store
• CRUD and Relational
11
MySQL
Development
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 12
MySQL Shell: Features (Dev)
• Scripting
– Execute scripts from:
• Interactive REPL interface
• Directly from the cmdline
• From Python, JS, or SQL script files
– Import any installed module (in Python)
MySQL
Development
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 13
MySQL Shell: Features (Dev/Ops)
• APIs
 MySQL DBs
– ‘mysql’ object
– Interaction with MySQL Server using the relational model
 Document Store
– ‘mysqlx’ object
– Interact with MySQL Server using the X DevAPI
MySQL
Development
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 14
MySQL Shell: Features (Dev/Ops)
• APIs
 ShellAPI
– ‘shell’ object
– General purpose functions and properties
 AdminAPI
– ‘dba’ object
– Set up and management of InnoDB clusters
 Shell utilities
– ‘util’ object
– Upgrade checker
– Import JSON documents
MySQL
Administration
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 15
A common use-case
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Company X starts a new business unit
16
• A DBMS is needed
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Company X starts a new business unit
17
• A DBMS is needed
• The infraestructure must be prepared
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Company X starts a new business unit
18
• A DBMS is needed
• The infraestructure must be prepared
• The DBMS must be deployed and managed
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Company X starts a new business unit
19
• A DBMS is needed
• The infraestructure must be prepared
• The DBMS must be deployed and managed
• The world’s most popular open-source database is suggested
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Company X starts a new business unit
20
• A DBMS is needed
• The infraestructure must be prepared
• The DBMS must be deployed and managed
• The world’s most popular open-source database is suggested
 MySQL is approved!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Company X starts a new business unit
21
• A DBMS is needed
• The infraestructure must be prepared
• The DBMS must be deployed and managed
• The world’s most popular open-source database is suggested
 MySQL is approved!
Call the devOps-engineer!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Meet Bill
The devOps-engineer
22
This is Bill.
Bill is a MySQL user.
Bill knows the Shell is the devOps tool for MySQL.
Bill uses the Shell to make his life easier.
Bill is smart.
Be like Bill.
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Prepare the DBMS
23
1. Package installation
2. Directories management
3. Set up security
4. Configure server settings
5. Create accounts with the right permissions
6. ...
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Prepare the DBMS
24
• Bill writes a JS script that can be used by others or even automated
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Prepare the DBMS
25
• Interacts with the database through the session object
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Prepare the DBMS
26
• Connect to localhost:3310
• Execute create_account.js with or without extra arguments forwarded to
the script (sys.argv[])
• Rely on the Shell prompt utility
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Upgrade the DBMS
27
• A major new MySQL version (8.0) is released with many improvements and
features
• Bill needs to upgrade the whole setup but is afraid it gets broken...
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Upgrade the DBMS
28
• A major new MySQL version (8.0) is released with many improvements and
features
• Bill needs to upgrade the whole setup but is afraid it gets broken...
Shell to the rescue!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
MySQL Shell: Features (Ops)
• Upgrade checker
– Verify whether instances are ready or not
for upgrading to MySQL 8
– Available through the util object
29
mysql-js> util.checkForServerUpgrade(“root@localhost:3306”);
MySQL
Administration
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Upgrade the DBMS
30
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
MySQL Shell: Features (Ops)
• API Command line integration
– cmdline syntax to invoke built-in Shell commands
– Requires minimal extra typing, quoting and escaping
– Supported objects: dba, cluster, shell, shell.options
and util
Syntax: mysqlsh [OPTIONS] [URI] -- <object_name> <method_name> [argument_list]
31
$ mysqlsh root@myserver:33060 –- util check-for-server-upgrade
MySQL
Administration
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Upgrade the DBMS
32
• Bill is smart
• Bill is a devOps-engineer
• Bill automates processes, by using continuous automation frameworks
• How could Bill ensure that the MySQL Servers deployments are always
using the latest available version?
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Shell meets continuous automation
33
• Let’s use as an example:
service { ‘mysql’:
ensure => latest,
enable => true,
require => Package[‘mysql-server-community’],
}
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Shell meets continuous automation
34
What if current is 5.7 and latest is 8.0? Will it break everything?
service { ‘mysql’:
ensure => latest,
enable => true,
require => Package[‘mysql-server-community’],
}
!
• Let’s use as an example:
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Shell meets continuous automation
35
service { ‘mysql’:
ensure => latest,
enable => true,
require => Package[‘mysql-server-community’],
before => Exec [‘upgrade checker’]
}
exec { “upgrade checker”:
command => “mysqlsh -- util check-for-server-upgrade { --user=root --
host=localhost --port=3306} --password=‘myPwd’”
require => Service[“mysqlsh”]
}
• Use MySQL Shell upgrade checker
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
• Customizable prompts
– Display context information
– Custom/dynamic tags that react to context
• Eg. export PRODUCTION_SERVERS=192.168.42.16
MySQL Shell: The DBA toolbox
Other features and tweaks
36
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
• Secure credential manager
• Passwords queried from a secure password store (uses OS native APIs)
• Optional auto-save for typed passwords (default will prompt)
• History
• Typed command history
• Pager
• Pass SQL results through an external screen paging program
MySQL Shell: The DBA toolbox
Other features and tweaks
37
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
• Built-in help
– Documentation for included APIs, shell commands, SQL, etc.
MySQL Shell: The DBA toolbox
Other features and tweaks
38
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 2
The business unit is growing
39
• The systems are vulnerable to downtime
• Downtime causes high losses...
• Critical data can’t be lost and must ”always” be available!
• High Availability becomes mandatory
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 2
The business unit is growing
40
• The systems are vulnerable to downtime
• Downtime causes high losses...
• Critical data can’t be lost and must ”always” be available!
• High Availability becomes mandatory
Bill wonders what kind of HA support MySQL has...
?
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 41
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 42
InnoDB cluster
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 43
InnoDB cluster
 MySQL Servers running Group
Replication
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 44
InnoDB cluster
 MySQL Servers running Group
Replication
 App Servers with MySQL Router
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 45
InnoDB cluster
 MySQL Servers running Group
Replication
 App Servers with MySQL Router
 MySQL Shell
 Set up, Manage, Orchestrate IDC
Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 46
InnoDB cluster
 MySQL Servers running Group
Replication
 App Servers with MySQL Router
 MySQL Shell
 Set up, Manage, Orchestrate IDC
 Clients / Applications
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
MySQL Shell: Features (Ops)
• Administration API: AdminAPI
– Creation and Management of InnoDB Clusters
– Hides the complexity of:
• Configuration
• Provisioning
• Orchestration
– Simple and straight-forward
– Doesn’t require MySQL expertise
– Flexible, powerful and secure
– Available in both JavaScript and Python
47
MySQL
Administration
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 2
The business unit is growing
48
• Bill needs to set up an HA deployment for the company needs
• Using the Shell and the AdminAPI he can achieve that very easily!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 2
The business unit is growing
49
• Bill needs to set up an HA deployment for the company needs
• Using the Shell and the AdminAPI he can achieve that very easily!
$ mysqlsh
mysql-js> dba.configureInstance(“root@host1:3306”, {clusterAdmin: “bill”})
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 2
The business unit is growing
50
• Bill needs to set up an HA deployment for the company needs
• Using the Shell and the AdminAPI he can achieve that very easily!
$ mysqlsh
mysql-js> dba.configureInstance(“root@host1:3306”, {clusterAdmin: “bill”})
mysql-js> var cluster = dba.createCluster(“Cluster1”)
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 2
The business unit is growing
51
• Bill needs to set up an HA deployment for the company needs
• Using the Shell and the AdminAPI he can achieve that very easily!
$ mysqlsh
mysql-js> dba.configureInstance(“root@host1:3306”, {clusterAdmin: “bill”})
mysql-js> var cluster = dba.createCluster(“Cluster1”)
mysql-js> cluster.addInstance(“bill@host2:3306”)
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 2
HA in 5 minutes!
52
 JSON object describing the structure of
the Cluster
 Includes general cluster information
 Topology:
 ReplicaSets
 Instance members
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 2
HA in 5 minutes!
53
 JSON object describing the status of the
Cluster
 Includes general cluster status
 Status information about each ReplicaSet
member
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
The requirements change
54
• A strange behaviour was seen in the application leading to user complaints
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
The requirements change
55
• A strange behaviour was seen in the application leading to user complaints
• Ops traced down the issue to the database... And found possible
inconsistent reads
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
The requirements change
56
• A strange behaviour was seen in the application leading to user complaints
• Ops traced down the issue to the database... And found possible
inconsistent reads
• Finally someone noticed that whenever a primary failover happens, stale
data was being read from the newly elected primary causing the strange
“inconsistencies”
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
The requirements change
57
• A strange behaviour was seen in the application leading to user complaints
• Ops traced down the issue to the database... And found possible
inconsistent reads
• Finally someone noticed that whenever a primary failover happens, stale
data was being read from the newly elected primary causing the strange
“inconsistencies”
• Direction asks for a solution even if it compromises performance!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
Checking the cluster options
58
 Verify the current cluster settings
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
Checking the cluster options
59
 Verify the current cluster settings
 JSON object listing configuration options
of the Cluster
 Includes global cluster options
 Includes configuration options of each cluster
member
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
Failover consistency
60
The failover consistency option can have 2 values:
• EVENTUAL (default)
 Read queries allowed in the new primary (even if backlog is being applied)
 Writes are blocked
 Possible stale reads
• BEFORE_ON_PRIMARY_FAILOVER
 Read and write queries blocked in the new primary (meanwhile backlog is being applied)
 “read your writes”
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
Change the failover consistency
61
The AdminAPI allows changing a configuration option:
1) For the whole cluster
 <Cluster.>setOption(option, value)
2) In a cluster member
 <Cluster.>setInstanceOption(instance, option, value)
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 3
Change the failover consistency
62
The AdminAPI allows changing a configuration option:
1) For the whole cluster
 <Cluster.>setOption(option, value)
2) In a cluster member
 <Cluster.>setInstanceOption(instance, option, value)
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 4
Maintenance
63
• Maintenance tasks on servers are common...
• Bill needs to perform a maintenance task on the current primary instance
• Which implies some sort of disruption...
• Idealy, Bill would rather manually elect a new primary to avoid any
disruption
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 4
Maintenance
64
• Maintenance tasks on servers are common...
• Bill needs to perform a maintenance task on the current primary instance
• Which implies some sort of disruption...
• Idealy, Bill would rather manually elect a new primary to avoid any
disruption
But... How?
?
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 4
Elect a new primary
65
 <Cluster.>setPrimaryInstance(instance)
By using the Shell and the AdminAPI!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 5
The requirements change... again
66
• Analysis of the dataset and its usage, concluded that the workload could be
spread accross the cluster members:
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 5
The requirements change... again
67
• Analysis of the dataset and its usage, concluded that the workload could be
spread accross the cluster members:
– No concurrent DDL ops in the same object
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 5
The requirements change... again
68
• Analysis of the dataset and its usage, concluded that the workload could be
spread accross the cluster members:
– No concurrent DDL ops in the same object
– No foreign key constraints
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 5
The requirements change... again
69
• Analysis of the dataset and its usage, concluded that the workload could be
spread accross the cluster members:
– No concurrent DDL ops in the same object
– No foreign key constraints
– No large transactions, etc.
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 5
The requirements change... again
70
• Analysis of the dataset and its usage, concluded that the workload could be
spread accross the cluster members:
– No concurrent DDL ops in the same object
– No foreign key constraints
– No large transactions, etc.
• Decision to use Multi-Primary mode, even if not recommended, is taken.
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 5
The requirements change... again
71
• Analysis of the dataset and its usage, concluded that the workload could be
spread accross the cluster members:
– No concurrent DDL ops in the same object
– No foreign key constraints
– No large transactions, etc.
• Decision to use Multi-Primary mode, even if not recommended, is taken.
But that implies the downtime of re-creating the whole cluster!
!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
 <Cluster.>switchToMultiPrimaryMode()
A common use-case: part 5
Switch to Multi-Primary mode
72
No restarts nor downtime!
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case: part 5
Switch to Multi-Primary mode
73
• All cluster members become
writable (R/W)
 Note:
Switch to single-primary mode available with:
 <Cluster.>switchToSinglePrimaryMode()
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
• Suddently somes instances are expelled from the cluster
• ... even though ops report that the network is OK!
• But further investigation concludes the network is actually flaky
• Some members are being expelled due to very small network cuts of 2
minutes
A common use-case: part 6
Troubleshooting
74
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
• Suddently somes instances are expelled from the cluster
• ... even though ops report that the network is OK!
• But further investigation concludes the network is actually flaky
• Some members are being expelled due to very small network cuts of 2
minutes
What can be done?
A common use-case: part 6
Troubleshooting
75
?
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
• Group Replication’s failure detector window is configurable
• Allows delays of suspensions of previously active cluster members
• Configurable using the AdminAPI!
A common use-case: part 6
Defining the expel timeout
76
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
A common use-case
Other useful features
77
• Define the next primary instance “in line”
• memberWeight = x
– Integer: [0, 100]
• Define the behaviour of an instance whenever it drops out of the cluster
• exitStateAction = y
– ABORT_SERVER
– READ_ONLY
• Extended Cluster.status()
• extended: true
• queryMembers: true
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Summary
• MySQL Shell brings together developers and DBAs
• Unified interface: one tool!
• Development and Administration APIs and features
• MySQL InnoDB Cluster is THE built-in HA solution for MySQL:
• Full-stack: High Availability out-of-the-box
• Easy to use: usability as a top concern
• Full control of the Cluster using the AdminAPI
78
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Resources
• MySQL Shell Userguide:
– https://dev.mysql.com/doc/refman/en/mysql-shell.html
• MySQL InnoDB Cluster Userguide:
– http://dev.mysql.com/doc/refman/en/mysql-innodb-cluster-userguide.html
• APIs Reference manuals
– JavaScript: https://dev.mysql.com/doc/dev/mysqlsh-api-javascript/
– Python: https://dev.mysql.com/doc/dev/mysqlsh-api-python/
• Blogging
– http://mysqlserverteam.com/category/high-availability
79
Copyright © 2019, Oracle and/or its affiliates. All rights reserved.
Thank you!
Any questions?
80
MySQL Shell - A DevOps-engineer day with MySQL’s development and administration tool

More Related Content

What's hot

MySQL 8 High Availability with InnoDB Clusters
MySQL 8 High Availability with InnoDB ClustersMySQL 8 High Availability with InnoDB Clusters
MySQL 8 High Availability with InnoDB ClustersMiguel Araújo
 
MySQL 5.7 InnoDB Cluster (Jan 2018)
MySQL 5.7 InnoDB Cluster (Jan 2018)MySQL 5.7 InnoDB Cluster (Jan 2018)
MySQL 5.7 InnoDB Cluster (Jan 2018)Olivier DASINI
 
MySQL Proxy. A powerful, flexible MySQL toolbox.
MySQL Proxy. A powerful, flexible MySQL toolbox.MySQL Proxy. A powerful, flexible MySQL toolbox.
MySQL Proxy. A powerful, flexible MySQL toolbox.Miguel Araújo
 
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017Ivan Ma
 
Why MySQL High Availability Matters
Why MySQL High Availability MattersWhy MySQL High Availability Matters
Why MySQL High Availability MattersMatt Lord
 
Oracle OpenWorld 2013 - HOL9737 MySQL Replication Best Practices
Oracle OpenWorld 2013 - HOL9737 MySQL Replication Best PracticesOracle OpenWorld 2013 - HOL9737 MySQL Replication Best Practices
Oracle OpenWorld 2013 - HOL9737 MySQL Replication Best PracticesSven Sandberg
 
MySQL InnoDB Cluster - A complete High Availability solution for MySQL
MySQL InnoDB Cluster - A complete High Availability solution for MySQLMySQL InnoDB Cluster - A complete High Availability solution for MySQL
MySQL InnoDB Cluster - A complete High Availability solution for MySQLOlivier DASINI
 
MySQL Shell : the best DBA tool ?
MySQL Shell : the best DBA tool ?MySQL Shell : the best DBA tool ?
MySQL Shell : the best DBA tool ?Frederic Descamps
 
MySQL InnoDB Cluster and Group Replication in a nutshell hands-on tutorial
MySQL InnoDB Cluster and Group Replication in a nutshell  hands-on tutorialMySQL InnoDB Cluster and Group Replication in a nutshell  hands-on tutorial
MySQL InnoDB Cluster and Group Replication in a nutshell hands-on tutorialFrederic Descamps
 
MySQL 8.0 Released Update
MySQL 8.0 Released UpdateMySQL 8.0 Released Update
MySQL 8.0 Released UpdateKeith Hollman
 
MySQL Replication Performance in the Cloud
MySQL Replication Performance in the CloudMySQL Replication Performance in the Cloud
MySQL Replication Performance in the CloudVitor Oliveira
 
replic8 - Replication in MySQL 8
replic8 - Replication in MySQL 8replic8 - Replication in MySQL 8
replic8 - Replication in MySQL 8Sven Sandberg
 
MySQL Group Replication - HandsOn Tutorial
MySQL Group Replication - HandsOn TutorialMySQL Group Replication - HandsOn Tutorial
MySQL Group Replication - HandsOn TutorialKenny Gryp
 
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.20State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20Frederic Descamps
 
Using MySQL Containers
Using MySQL ContainersUsing MySQL Containers
Using MySQL ContainersMatt Lord
 
MySQL 5.7: Focus on Replication
MySQL 5.7: Focus on ReplicationMySQL 5.7: Focus on Replication
MySQL 5.7: Focus on ReplicationMario Beck
 
MySQL for Software-as-a-Service (SaaS)
MySQL for Software-as-a-Service (SaaS)MySQL for Software-as-a-Service (SaaS)
MySQL for Software-as-a-Service (SaaS)Mario Beck
 
Conference slides: MySQL Cluster Performance Tuning
Conference slides: MySQL Cluster Performance TuningConference slides: MySQL Cluster Performance Tuning
Conference slides: MySQL Cluster Performance TuningSeveralnines
 
MySQL InnoDB Cluster - Group Replication
MySQL InnoDB Cluster - Group ReplicationMySQL InnoDB Cluster - Group Replication
MySQL InnoDB Cluster - Group ReplicationFrederic Descamps
 

What's hot (20)

MySQL 8 High Availability with InnoDB Clusters
MySQL 8 High Availability with InnoDB ClustersMySQL 8 High Availability with InnoDB Clusters
MySQL 8 High Availability with InnoDB Clusters
 
MySQL 5.7 InnoDB Cluster (Jan 2018)
MySQL 5.7 InnoDB Cluster (Jan 2018)MySQL 5.7 InnoDB Cluster (Jan 2018)
MySQL 5.7 InnoDB Cluster (Jan 2018)
 
MySQL Proxy. A powerful, flexible MySQL toolbox.
MySQL Proxy. A powerful, flexible MySQL toolbox.MySQL Proxy. A powerful, flexible MySQL toolbox.
MySQL Proxy. A powerful, flexible MySQL toolbox.
 
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017
 
Why MySQL High Availability Matters
Why MySQL High Availability MattersWhy MySQL High Availability Matters
Why MySQL High Availability Matters
 
Oracle OpenWorld 2013 - HOL9737 MySQL Replication Best Practices
Oracle OpenWorld 2013 - HOL9737 MySQL Replication Best PracticesOracle OpenWorld 2013 - HOL9737 MySQL Replication Best Practices
Oracle OpenWorld 2013 - HOL9737 MySQL Replication Best Practices
 
MySQL InnoDB Cluster - A complete High Availability solution for MySQL
MySQL InnoDB Cluster - A complete High Availability solution for MySQLMySQL InnoDB Cluster - A complete High Availability solution for MySQL
MySQL InnoDB Cluster - A complete High Availability solution for MySQL
 
MySQL Shell : the best DBA tool ?
MySQL Shell : the best DBA tool ?MySQL Shell : the best DBA tool ?
MySQL Shell : the best DBA tool ?
 
MySQL InnoDB Cluster and Group Replication in a nutshell hands-on tutorial
MySQL InnoDB Cluster and Group Replication in a nutshell  hands-on tutorialMySQL InnoDB Cluster and Group Replication in a nutshell  hands-on tutorial
MySQL InnoDB Cluster and Group Replication in a nutshell hands-on tutorial
 
MySQL 8.0 Released Update
MySQL 8.0 Released UpdateMySQL 8.0 Released Update
MySQL 8.0 Released Update
 
MySQL Replication Performance in the Cloud
MySQL Replication Performance in the CloudMySQL Replication Performance in the Cloud
MySQL Replication Performance in the Cloud
 
replic8 - Replication in MySQL 8
replic8 - Replication in MySQL 8replic8 - Replication in MySQL 8
replic8 - Replication in MySQL 8
 
MySQL Group Replication - HandsOn Tutorial
MySQL Group Replication - HandsOn TutorialMySQL Group Replication - HandsOn Tutorial
MySQL Group Replication - HandsOn Tutorial
 
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.20State 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
 
Using MySQL Containers
Using MySQL ContainersUsing MySQL Containers
Using MySQL Containers
 
MySQL 5.7: Focus on Replication
MySQL 5.7: Focus on ReplicationMySQL 5.7: Focus on Replication
MySQL 5.7: Focus on Replication
 
Sunshine php my sql 8.0 v2
Sunshine php my sql 8.0 v2Sunshine php my sql 8.0 v2
Sunshine php my sql 8.0 v2
 
MySQL for Software-as-a-Service (SaaS)
MySQL for Software-as-a-Service (SaaS)MySQL for Software-as-a-Service (SaaS)
MySQL for Software-as-a-Service (SaaS)
 
Conference slides: MySQL Cluster Performance Tuning
Conference slides: MySQL Cluster Performance TuningConference slides: MySQL Cluster Performance Tuning
Conference slides: MySQL Cluster Performance Tuning
 
MySQL InnoDB Cluster - Group Replication
MySQL InnoDB Cluster - Group ReplicationMySQL InnoDB Cluster - Group Replication
MySQL InnoDB Cluster - Group Replication
 

Similar to MySQL Shell - A DevOps-engineer day with MySQL’s development and administration tool

MySQL Technology Overview
MySQL Technology OverviewMySQL Technology Overview
MySQL Technology OverviewKeith Hollman
 
Docker Compose Setup for MySQL InnoDB Cluster
Docker Compose Setup for MySQL InnoDB ClusterDocker Compose Setup for MySQL InnoDB Cluster
Docker Compose Setup for MySQL InnoDB ClusterBalasubramanian Kandasamy
 
Confoo 202 - MySQL Group Replication and ReplicaSet
Confoo 202 - MySQL Group Replication and ReplicaSetConfoo 202 - MySQL Group Replication and ReplicaSet
Confoo 202 - MySQL Group Replication and ReplicaSetDave Stokes
 
MySQL 8.0, what's new ? - Forum PHP 2018
MySQL 8.0, what's new ? - Forum PHP 2018MySQL 8.0, what's new ? - Forum PHP 2018
MySQL 8.0, what's new ? - Forum PHP 2018Olivier DASINI
 
MySQL en el mundo real. Evolución desde la compra por Oracle
MySQL en el mundo real. Evolución desde la compra por OracleMySQL en el mundo real. Evolución desde la compra por Oracle
MySQL en el mundo real. Evolución desde la compra por OracleLibreCon
 
20200613 my sql-ha-deployment
20200613 my sql-ha-deployment20200613 my sql-ha-deployment
20200613 my sql-ha-deploymentIvan Ma
 
MySQL 8.0 - What's New ?
MySQL 8.0 - What's New ?MySQL 8.0 - What's New ?
MySQL 8.0 - What's New ?Olivier DASINI
 
TechEvent 2019: Create a Private Database Cloud in the Public Cloud using the...
TechEvent 2019: Create a Private Database Cloud in the Public Cloud using the...TechEvent 2019: Create a Private Database Cloud in the Public Cloud using the...
TechEvent 2019: Create a Private Database Cloud in the Public Cloud using the...Trivadis
 
How to operate MySQL InnoDB Cluster with MySQL Shell
How to operate MySQL InnoDB Cluster with MySQL ShellHow to operate MySQL InnoDB Cluster with MySQL Shell
How to operate MySQL InnoDB Cluster with MySQL ShellFrederic Descamps
 
MySQL Shell: the daily tool for devs and admins. By Vittorio Cioe.
MySQL Shell: the daily tool for devs and admins. By Vittorio Cioe.MySQL Shell: the daily tool for devs and admins. By Vittorio Cioe.
MySQL Shell: the daily tool for devs and admins. By Vittorio Cioe.Cloud Native Day Tel Aviv
 
Oracle Database 19c - poslední z rodiny 12.2 a co přináší nového
Oracle Database 19c - poslední z rodiny 12.2 a co přináší novéhoOracle Database 19c - poslední z rodiny 12.2 a co přináší nového
Oracle Database 19c - poslední z rodiny 12.2 a co přináší novéhoMarketingArrowECS_CZ
 
Oracle Enterprise Manager for MySQL
Oracle Enterprise Manager for MySQLOracle Enterprise Manager for MySQL
Oracle Enterprise Manager for MySQLMario Beck
 
A Step by Step Introduction to the MySQL Document Store
A Step by Step Introduction to the MySQL Document StoreA Step by Step Introduction to the MySQL Document Store
A Step by Step Introduction to the MySQL Document StoreDave Stokes
 
MySQL Connector/J in the Making of Modern Applications
MySQL Connector/J in the Making of Modern ApplicationsMySQL Connector/J in the Making of Modern Applications
MySQL Connector/J in the Making of Modern ApplicationsFilipe Silva
 
MySQL Enterprise Edition - Complete Guide (2019)
MySQL Enterprise Edition - Complete Guide (2019)MySQL Enterprise Edition - Complete Guide (2019)
MySQL Enterprise Edition - Complete Guide (2019)Keith Hollman
 
MySQL Day Paris 2018 - What’s New in MySQL 8.0 ?
MySQL Day Paris 2018 - What’s New in MySQL 8.0 ?MySQL Day Paris 2018 - What’s New in MySQL 8.0 ?
MySQL Day Paris 2018 - What’s New in MySQL 8.0 ?Olivier DASINI
 
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
MySQL 8.0 InnoDB Cluster - Easiest TutorialMySQL 8.0 InnoDB Cluster - Easiest Tutorial
MySQL 8.0 InnoDB Cluster - Easiest TutorialFrederic Descamps
 
Unlocking Big Data Insights with MySQL
Unlocking Big Data Insights with MySQLUnlocking Big Data Insights with MySQL
Unlocking Big Data Insights with MySQLMatt Lord
 
Netherlands Tech Tour 03 - MySQL Cluster
Netherlands Tech Tour 03 -   MySQL ClusterNetherlands Tech Tour 03 -   MySQL Cluster
Netherlands Tech Tour 03 - MySQL ClusterMark Swarbrick
 

Similar to MySQL Shell - A DevOps-engineer day with MySQL’s development and administration tool (20)

MySQL Technology Overview
MySQL Technology OverviewMySQL Technology Overview
MySQL Technology Overview
 
Docker Compose Setup for MySQL InnoDB Cluster
Docker Compose Setup for MySQL InnoDB ClusterDocker Compose Setup for MySQL InnoDB Cluster
Docker Compose Setup for MySQL InnoDB Cluster
 
Confoo 202 - MySQL Group Replication and ReplicaSet
Confoo 202 - MySQL Group Replication and ReplicaSetConfoo 202 - MySQL Group Replication and ReplicaSet
Confoo 202 - MySQL Group Replication and ReplicaSet
 
MySQL 8.0, what's new ? - Forum PHP 2018
MySQL 8.0, what's new ? - Forum PHP 2018MySQL 8.0, what's new ? - Forum PHP 2018
MySQL 8.0, what's new ? - Forum PHP 2018
 
My sql8 innodb_cluster
My sql8 innodb_clusterMy sql8 innodb_cluster
My sql8 innodb_cluster
 
MySQL en el mundo real. Evolución desde la compra por Oracle
MySQL en el mundo real. Evolución desde la compra por OracleMySQL en el mundo real. Evolución desde la compra por Oracle
MySQL en el mundo real. Evolución desde la compra por Oracle
 
20200613 my sql-ha-deployment
20200613 my sql-ha-deployment20200613 my sql-ha-deployment
20200613 my sql-ha-deployment
 
MySQL 8.0 - What's New ?
MySQL 8.0 - What's New ?MySQL 8.0 - What's New ?
MySQL 8.0 - What's New ?
 
TechEvent 2019: Create a Private Database Cloud in the Public Cloud using the...
TechEvent 2019: Create a Private Database Cloud in the Public Cloud using the...TechEvent 2019: Create a Private Database Cloud in the Public Cloud using the...
TechEvent 2019: Create a Private Database Cloud in the Public Cloud using the...
 
How to operate MySQL InnoDB Cluster with MySQL Shell
How to operate MySQL InnoDB Cluster with MySQL ShellHow to operate MySQL InnoDB Cluster with MySQL Shell
How to operate MySQL InnoDB Cluster with MySQL Shell
 
MySQL Shell: the daily tool for devs and admins. By Vittorio Cioe.
MySQL Shell: the daily tool for devs and admins. By Vittorio Cioe.MySQL Shell: the daily tool for devs and admins. By Vittorio Cioe.
MySQL Shell: the daily tool for devs and admins. By Vittorio Cioe.
 
Oracle Database 19c - poslední z rodiny 12.2 a co přináší nového
Oracle Database 19c - poslední z rodiny 12.2 a co přináší novéhoOracle Database 19c - poslední z rodiny 12.2 a co přináší nového
Oracle Database 19c - poslední z rodiny 12.2 a co přináší nového
 
Oracle Enterprise Manager for MySQL
Oracle Enterprise Manager for MySQLOracle Enterprise Manager for MySQL
Oracle Enterprise Manager for MySQL
 
A Step by Step Introduction to the MySQL Document Store
A Step by Step Introduction to the MySQL Document StoreA Step by Step Introduction to the MySQL Document Store
A Step by Step Introduction to the MySQL Document Store
 
MySQL Connector/J in the Making of Modern Applications
MySQL Connector/J in the Making of Modern ApplicationsMySQL Connector/J in the Making of Modern Applications
MySQL Connector/J in the Making of Modern Applications
 
MySQL Enterprise Edition - Complete Guide (2019)
MySQL Enterprise Edition - Complete Guide (2019)MySQL Enterprise Edition - Complete Guide (2019)
MySQL Enterprise Edition - Complete Guide (2019)
 
MySQL Day Paris 2018 - What’s New in MySQL 8.0 ?
MySQL Day Paris 2018 - What’s New in MySQL 8.0 ?MySQL Day Paris 2018 - What’s New in MySQL 8.0 ?
MySQL Day Paris 2018 - What’s New in MySQL 8.0 ?
 
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
MySQL 8.0 InnoDB Cluster - Easiest TutorialMySQL 8.0 InnoDB Cluster - Easiest Tutorial
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
 
Unlocking Big Data Insights with MySQL
Unlocking Big Data Insights with MySQLUnlocking Big Data Insights with MySQL
Unlocking Big Data Insights with MySQL
 
Netherlands Tech Tour 03 - MySQL Cluster
Netherlands Tech Tour 03 -   MySQL ClusterNetherlands Tech Tour 03 -   MySQL Cluster
Netherlands Tech Tour 03 - MySQL Cluster
 

More from Miguel Araújo

Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
MySQL Router - Explore The Secrets (MySQL Belgian Days 2024)
MySQL Router - Explore The Secrets (MySQL Belgian Days 2024)MySQL Router - Explore The Secrets (MySQL Belgian Days 2024)
MySQL Router - Explore The Secrets (MySQL Belgian Days 2024)Miguel Araújo
 
MySQL Shell/AdminAPI - MySQL Architectures Made Easy For All!
MySQL Shell/AdminAPI - MySQL Architectures Made Easy For All!MySQL Shell/AdminAPI - MySQL Architectures Made Easy For All!
MySQL Shell/AdminAPI - MySQL Architectures Made Easy For All!Miguel Araújo
 
Deep Dive into MySQL InnoDB Cluster Read Scale-out Capabilities.pdf
Deep Dive into MySQL InnoDB Cluster Read Scale-out Capabilities.pdfDeep Dive into MySQL InnoDB Cluster Read Scale-out Capabilities.pdf
Deep Dive into MySQL InnoDB Cluster Read Scale-out Capabilities.pdfMiguel Araújo
 
MySQL Database Architectures - High Availability and Disaster Recovery Solution
MySQL Database Architectures - High Availability and Disaster Recovery SolutionMySQL Database Architectures - High Availability and Disaster Recovery Solution
MySQL Database Architectures - High Availability and Disaster Recovery SolutionMiguel Araújo
 
MySQL InnoDB Cluster / ReplicaSet - Tutorial
MySQL InnoDB Cluster / ReplicaSet - TutorialMySQL InnoDB Cluster / ReplicaSet - Tutorial
MySQL InnoDB Cluster / ReplicaSet - TutorialMiguel Araújo
 
FOSDEM'18: MySQL InnoDB Cluster - MySQL HA Made Easy!
FOSDEM'18: MySQL InnoDB Cluster - MySQL HA Made Easy!FOSDEM'18: MySQL InnoDB Cluster - MySQL HA Made Easy!
FOSDEM'18: MySQL InnoDB Cluster - MySQL HA Made Easy!Miguel Araújo
 
SLQ vs NOSQL - friends or foes
SLQ vs NOSQL - friends or foesSLQ vs NOSQL - friends or foes
SLQ vs NOSQL - friends or foesMiguel Araújo
 
Asynchronous Replication of Databases
Asynchronous Replication of DatabasesAsynchronous Replication of Databases
Asynchronous Replication of DatabasesMiguel Araújo
 
Evaluating Data Freshness in Large Scale Replicated Databases
Evaluating Data Freshness in Large Scale Replicated DatabasesEvaluating Data Freshness in Large Scale Replicated Databases
Evaluating Data Freshness in Large Scale Replicated DatabasesMiguel Araújo
 

More from Miguel Araújo (10)

Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
MySQL Router - Explore The Secrets (MySQL Belgian Days 2024)
MySQL Router - Explore The Secrets (MySQL Belgian Days 2024)MySQL Router - Explore The Secrets (MySQL Belgian Days 2024)
MySQL Router - Explore The Secrets (MySQL Belgian Days 2024)
 
MySQL Shell/AdminAPI - MySQL Architectures Made Easy For All!
MySQL Shell/AdminAPI - MySQL Architectures Made Easy For All!MySQL Shell/AdminAPI - MySQL Architectures Made Easy For All!
MySQL Shell/AdminAPI - MySQL Architectures Made Easy For All!
 
Deep Dive into MySQL InnoDB Cluster Read Scale-out Capabilities.pdf
Deep Dive into MySQL InnoDB Cluster Read Scale-out Capabilities.pdfDeep Dive into MySQL InnoDB Cluster Read Scale-out Capabilities.pdf
Deep Dive into MySQL InnoDB Cluster Read Scale-out Capabilities.pdf
 
MySQL Database Architectures - High Availability and Disaster Recovery Solution
MySQL Database Architectures - High Availability and Disaster Recovery SolutionMySQL Database Architectures - High Availability and Disaster Recovery Solution
MySQL Database Architectures - High Availability and Disaster Recovery Solution
 
MySQL InnoDB Cluster / ReplicaSet - Tutorial
MySQL InnoDB Cluster / ReplicaSet - TutorialMySQL InnoDB Cluster / ReplicaSet - Tutorial
MySQL InnoDB Cluster / ReplicaSet - Tutorial
 
FOSDEM'18: MySQL InnoDB Cluster - MySQL HA Made Easy!
FOSDEM'18: MySQL InnoDB Cluster - MySQL HA Made Easy!FOSDEM'18: MySQL InnoDB Cluster - MySQL HA Made Easy!
FOSDEM'18: MySQL InnoDB Cluster - MySQL HA Made Easy!
 
SLQ vs NOSQL - friends or foes
SLQ vs NOSQL - friends or foesSLQ vs NOSQL - friends or foes
SLQ vs NOSQL - friends or foes
 
Asynchronous Replication of Databases
Asynchronous Replication of DatabasesAsynchronous Replication of Databases
Asynchronous Replication of Databases
 
Evaluating Data Freshness in Large Scale Replicated Databases
Evaluating Data Freshness in Large Scale Replicated DatabasesEvaluating Data Freshness in Large Scale Replicated Databases
Evaluating Data Freshness in Large Scale Replicated Databases
 

Recently uploaded

Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionSolGuruz
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...OnePlan Solutions
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsJhone kinadey
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024Mind IT Systems
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdfPearlKirahMaeRagusta1
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxComplianceQuest1
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...panagenda
 
How to Choose the Right Laravel Development Partner in New York City_compress...
How to Choose the Right Laravel Development Partner in New York City_compress...How to Choose the Right Laravel Development Partner in New York City_compress...
How to Choose the Right Laravel Development Partner in New York City_compress...software pro Development
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionOnePlan Solutions
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...kalichargn70th171
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Steffen Staab
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️Delhi Call girls
 

Recently uploaded (20)

Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docx
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
 
How to Choose the Right Laravel Development Partner in New York City_compress...
How to Choose the Right Laravel Development Partner in New York City_compress...How to Choose the Right Laravel Development Partner in New York City_compress...
How to Choose the Right Laravel Development Partner in New York City_compress...
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 

MySQL Shell - A DevOps-engineer day with MySQL’s development and administration tool

  • 1. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Miguel Araújo Senior Software Developer MySQL Middleware and Clients pre-FOSDEM’19 MySQL Day - February 01, 2019 MySQL Shell A DevOps-engineer day with MySQL’s development and administration tool
  • 2. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Safe Harbor Statement The following is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, timing, and pricing of any features or functionality described for Oracle’s products may change and remains at the sole discretion of Oracle Corporation. 2
  • 3. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 3 Who am I?
  • 4. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. whoami Miguel Araújo • MySQL Senior Software Developer • Lead developer for the AdminAPI at the MySQL Shell team • MySQL InnoDB Cluster evangelist • Living in Portugal • http://about.me/miguel-araujo 4
  • 5. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 5 DevOps: What is it? As simple as:  Engineers (developers) and operations working together to: Automate and monitor processes  Share knowledge and collaborate Get things done faster Deliver faster!
  • 6. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. DevOps-Engineer: …and that is? 6
  • 7. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. DevOps-Engineer: …and that is? ¯_(ツ)_/¯ 7
  • 8. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. DevOps-Engineer: …and that is? 8 OK, actually it’s someone that can:  Do system administration (sysadmin)  Code  Understand testing  Automate processes  Talk! (bridge between devs and ops)
  • 9. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. MySQL Shell: Introduction • Interactive multi-language console interface that supports development and administration for the MySQL Server • Can be used to perform data queries or updates, and administration operations:  Interactively or through batch operations  With scriptable “DevOps” APIs  Unified Interface for MySQL Developers and DBAs: one tool! • Intuitive, flexible, powerful and easy to use! 9
  • 10. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. MySQL Shell: Features (Dev) • Multi-language support – JavaScript, Python and SQL – Both interactive and batch operations (scripting) 10 MySQL Development
  • 11. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. MySQL Shell: Features (Dev) • Multi-language support – JavaScript, Python and SQL – Both interactive and batch operations (scripting) • Document and relational model – Supports the classic relational model – Modern fluent API for the MySQL Document Store • CRUD and Relational 11 MySQL Development
  • 12. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 12 MySQL Shell: Features (Dev) • Scripting – Execute scripts from: • Interactive REPL interface • Directly from the cmdline • From Python, JS, or SQL script files – Import any installed module (in Python) MySQL Development
  • 13. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 13 MySQL Shell: Features (Dev/Ops) • APIs  MySQL DBs – ‘mysql’ object – Interaction with MySQL Server using the relational model  Document Store – ‘mysqlx’ object – Interact with MySQL Server using the X DevAPI MySQL Development
  • 14. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 14 MySQL Shell: Features (Dev/Ops) • APIs  ShellAPI – ‘shell’ object – General purpose functions and properties  AdminAPI – ‘dba’ object – Set up and management of InnoDB clusters  Shell utilities – ‘util’ object – Upgrade checker – Import JSON documents MySQL Administration
  • 15. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 15 A common use-case
  • 16. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Company X starts a new business unit 16 • A DBMS is needed
  • 17. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Company X starts a new business unit 17 • A DBMS is needed • The infraestructure must be prepared
  • 18. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Company X starts a new business unit 18 • A DBMS is needed • The infraestructure must be prepared • The DBMS must be deployed and managed
  • 19. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Company X starts a new business unit 19 • A DBMS is needed • The infraestructure must be prepared • The DBMS must be deployed and managed • The world’s most popular open-source database is suggested
  • 20. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Company X starts a new business unit 20 • A DBMS is needed • The infraestructure must be prepared • The DBMS must be deployed and managed • The world’s most popular open-source database is suggested  MySQL is approved!
  • 21. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Company X starts a new business unit 21 • A DBMS is needed • The infraestructure must be prepared • The DBMS must be deployed and managed • The world’s most popular open-source database is suggested  MySQL is approved! Call the devOps-engineer!
  • 22. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Meet Bill The devOps-engineer 22 This is Bill. Bill is a MySQL user. Bill knows the Shell is the devOps tool for MySQL. Bill uses the Shell to make his life easier. Bill is smart. Be like Bill.
  • 23. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Prepare the DBMS 23 1. Package installation 2. Directories management 3. Set up security 4. Configure server settings 5. Create accounts with the right permissions 6. ...
  • 24. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Prepare the DBMS 24 • Bill writes a JS script that can be used by others or even automated
  • 25. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Prepare the DBMS 25 • Interacts with the database through the session object
  • 26. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Prepare the DBMS 26 • Connect to localhost:3310 • Execute create_account.js with or without extra arguments forwarded to the script (sys.argv[]) • Rely on the Shell prompt utility
  • 27. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Upgrade the DBMS 27 • A major new MySQL version (8.0) is released with many improvements and features • Bill needs to upgrade the whole setup but is afraid it gets broken...
  • 28. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Upgrade the DBMS 28 • A major new MySQL version (8.0) is released with many improvements and features • Bill needs to upgrade the whole setup but is afraid it gets broken... Shell to the rescue!
  • 29. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. MySQL Shell: Features (Ops) • Upgrade checker – Verify whether instances are ready or not for upgrading to MySQL 8 – Available through the util object 29 mysql-js> util.checkForServerUpgrade(“root@localhost:3306”); MySQL Administration
  • 30. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Upgrade the DBMS 30
  • 31. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. MySQL Shell: Features (Ops) • API Command line integration – cmdline syntax to invoke built-in Shell commands – Requires minimal extra typing, quoting and escaping – Supported objects: dba, cluster, shell, shell.options and util Syntax: mysqlsh [OPTIONS] [URI] -- <object_name> <method_name> [argument_list] 31 $ mysqlsh root@myserver:33060 –- util check-for-server-upgrade MySQL Administration
  • 32. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Upgrade the DBMS 32 • Bill is smart • Bill is a devOps-engineer • Bill automates processes, by using continuous automation frameworks • How could Bill ensure that the MySQL Servers deployments are always using the latest available version?
  • 33. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Shell meets continuous automation 33 • Let’s use as an example: service { ‘mysql’: ensure => latest, enable => true, require => Package[‘mysql-server-community’], }
  • 34. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Shell meets continuous automation 34 What if current is 5.7 and latest is 8.0? Will it break everything? service { ‘mysql’: ensure => latest, enable => true, require => Package[‘mysql-server-community’], } ! • Let’s use as an example:
  • 35. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Shell meets continuous automation 35 service { ‘mysql’: ensure => latest, enable => true, require => Package[‘mysql-server-community’], before => Exec [‘upgrade checker’] } exec { “upgrade checker”: command => “mysqlsh -- util check-for-server-upgrade { --user=root -- host=localhost --port=3306} --password=‘myPwd’” require => Service[“mysqlsh”] } • Use MySQL Shell upgrade checker
  • 36. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. • Customizable prompts – Display context information – Custom/dynamic tags that react to context • Eg. export PRODUCTION_SERVERS=192.168.42.16 MySQL Shell: The DBA toolbox Other features and tweaks 36
  • 37. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. • Secure credential manager • Passwords queried from a secure password store (uses OS native APIs) • Optional auto-save for typed passwords (default will prompt) • History • Typed command history • Pager • Pass SQL results through an external screen paging program MySQL Shell: The DBA toolbox Other features and tweaks 37
  • 38. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. • Built-in help – Documentation for included APIs, shell commands, SQL, etc. MySQL Shell: The DBA toolbox Other features and tweaks 38
  • 39. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 2 The business unit is growing 39 • The systems are vulnerable to downtime • Downtime causes high losses... • Critical data can’t be lost and must ”always” be available! • High Availability becomes mandatory
  • 40. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 2 The business unit is growing 40 • The systems are vulnerable to downtime • Downtime causes high losses... • Critical data can’t be lost and must ”always” be available! • High Availability becomes mandatory Bill wonders what kind of HA support MySQL has... ?
  • 41. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 41
  • 42. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 42 InnoDB cluster
  • 43. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 43 InnoDB cluster  MySQL Servers running Group Replication
  • 44. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 44 InnoDB cluster  MySQL Servers running Group Replication  App Servers with MySQL Router
  • 45. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 45 InnoDB cluster  MySQL Servers running Group Replication  App Servers with MySQL Router  MySQL Shell  Set up, Manage, Orchestrate IDC
  • 46. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. 46 InnoDB cluster  MySQL Servers running Group Replication  App Servers with MySQL Router  MySQL Shell  Set up, Manage, Orchestrate IDC  Clients / Applications
  • 47. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. MySQL Shell: Features (Ops) • Administration API: AdminAPI – Creation and Management of InnoDB Clusters – Hides the complexity of: • Configuration • Provisioning • Orchestration – Simple and straight-forward – Doesn’t require MySQL expertise – Flexible, powerful and secure – Available in both JavaScript and Python 47 MySQL Administration
  • 48. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 2 The business unit is growing 48 • Bill needs to set up an HA deployment for the company needs • Using the Shell and the AdminAPI he can achieve that very easily!
  • 49. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 2 The business unit is growing 49 • Bill needs to set up an HA deployment for the company needs • Using the Shell and the AdminAPI he can achieve that very easily! $ mysqlsh mysql-js> dba.configureInstance(“root@host1:3306”, {clusterAdmin: “bill”})
  • 50. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 2 The business unit is growing 50 • Bill needs to set up an HA deployment for the company needs • Using the Shell and the AdminAPI he can achieve that very easily! $ mysqlsh mysql-js> dba.configureInstance(“root@host1:3306”, {clusterAdmin: “bill”}) mysql-js> var cluster = dba.createCluster(“Cluster1”)
  • 51. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 2 The business unit is growing 51 • Bill needs to set up an HA deployment for the company needs • Using the Shell and the AdminAPI he can achieve that very easily! $ mysqlsh mysql-js> dba.configureInstance(“root@host1:3306”, {clusterAdmin: “bill”}) mysql-js> var cluster = dba.createCluster(“Cluster1”) mysql-js> cluster.addInstance(“bill@host2:3306”)
  • 52. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 2 HA in 5 minutes! 52  JSON object describing the structure of the Cluster  Includes general cluster information  Topology:  ReplicaSets  Instance members
  • 53. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 2 HA in 5 minutes! 53  JSON object describing the status of the Cluster  Includes general cluster status  Status information about each ReplicaSet member
  • 54. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 The requirements change 54 • A strange behaviour was seen in the application leading to user complaints
  • 55. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 The requirements change 55 • A strange behaviour was seen in the application leading to user complaints • Ops traced down the issue to the database... And found possible inconsistent reads
  • 56. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 The requirements change 56 • A strange behaviour was seen in the application leading to user complaints • Ops traced down the issue to the database... And found possible inconsistent reads • Finally someone noticed that whenever a primary failover happens, stale data was being read from the newly elected primary causing the strange “inconsistencies”
  • 57. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 The requirements change 57 • A strange behaviour was seen in the application leading to user complaints • Ops traced down the issue to the database... And found possible inconsistent reads • Finally someone noticed that whenever a primary failover happens, stale data was being read from the newly elected primary causing the strange “inconsistencies” • Direction asks for a solution even if it compromises performance!
  • 58. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 Checking the cluster options 58  Verify the current cluster settings
  • 59. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 Checking the cluster options 59  Verify the current cluster settings  JSON object listing configuration options of the Cluster  Includes global cluster options  Includes configuration options of each cluster member
  • 60. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 Failover consistency 60 The failover consistency option can have 2 values: • EVENTUAL (default)  Read queries allowed in the new primary (even if backlog is being applied)  Writes are blocked  Possible stale reads • BEFORE_ON_PRIMARY_FAILOVER  Read and write queries blocked in the new primary (meanwhile backlog is being applied)  “read your writes”
  • 61. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 Change the failover consistency 61 The AdminAPI allows changing a configuration option: 1) For the whole cluster  <Cluster.>setOption(option, value) 2) In a cluster member  <Cluster.>setInstanceOption(instance, option, value)
  • 62. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 3 Change the failover consistency 62 The AdminAPI allows changing a configuration option: 1) For the whole cluster  <Cluster.>setOption(option, value) 2) In a cluster member  <Cluster.>setInstanceOption(instance, option, value)
  • 63. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 4 Maintenance 63 • Maintenance tasks on servers are common... • Bill needs to perform a maintenance task on the current primary instance • Which implies some sort of disruption... • Idealy, Bill would rather manually elect a new primary to avoid any disruption
  • 64. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 4 Maintenance 64 • Maintenance tasks on servers are common... • Bill needs to perform a maintenance task on the current primary instance • Which implies some sort of disruption... • Idealy, Bill would rather manually elect a new primary to avoid any disruption But... How? ?
  • 65. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 4 Elect a new primary 65  <Cluster.>setPrimaryInstance(instance) By using the Shell and the AdminAPI!
  • 66. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 5 The requirements change... again 66 • Analysis of the dataset and its usage, concluded that the workload could be spread accross the cluster members:
  • 67. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 5 The requirements change... again 67 • Analysis of the dataset and its usage, concluded that the workload could be spread accross the cluster members: – No concurrent DDL ops in the same object
  • 68. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 5 The requirements change... again 68 • Analysis of the dataset and its usage, concluded that the workload could be spread accross the cluster members: – No concurrent DDL ops in the same object – No foreign key constraints
  • 69. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 5 The requirements change... again 69 • Analysis of the dataset and its usage, concluded that the workload could be spread accross the cluster members: – No concurrent DDL ops in the same object – No foreign key constraints – No large transactions, etc.
  • 70. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 5 The requirements change... again 70 • Analysis of the dataset and its usage, concluded that the workload could be spread accross the cluster members: – No concurrent DDL ops in the same object – No foreign key constraints – No large transactions, etc. • Decision to use Multi-Primary mode, even if not recommended, is taken.
  • 71. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 5 The requirements change... again 71 • Analysis of the dataset and its usage, concluded that the workload could be spread accross the cluster members: – No concurrent DDL ops in the same object – No foreign key constraints – No large transactions, etc. • Decision to use Multi-Primary mode, even if not recommended, is taken. But that implies the downtime of re-creating the whole cluster! !
  • 72. Copyright © 2019, Oracle and/or its affiliates. All rights reserved.  <Cluster.>switchToMultiPrimaryMode() A common use-case: part 5 Switch to Multi-Primary mode 72 No restarts nor downtime!
  • 73. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case: part 5 Switch to Multi-Primary mode 73 • All cluster members become writable (R/W)  Note: Switch to single-primary mode available with:  <Cluster.>switchToSinglePrimaryMode()
  • 74. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. • Suddently somes instances are expelled from the cluster • ... even though ops report that the network is OK! • But further investigation concludes the network is actually flaky • Some members are being expelled due to very small network cuts of 2 minutes A common use-case: part 6 Troubleshooting 74
  • 75. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. • Suddently somes instances are expelled from the cluster • ... even though ops report that the network is OK! • But further investigation concludes the network is actually flaky • Some members are being expelled due to very small network cuts of 2 minutes What can be done? A common use-case: part 6 Troubleshooting 75 ?
  • 76. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. • Group Replication’s failure detector window is configurable • Allows delays of suspensions of previously active cluster members • Configurable using the AdminAPI! A common use-case: part 6 Defining the expel timeout 76
  • 77. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. A common use-case Other useful features 77 • Define the next primary instance “in line” • memberWeight = x – Integer: [0, 100] • Define the behaviour of an instance whenever it drops out of the cluster • exitStateAction = y – ABORT_SERVER – READ_ONLY • Extended Cluster.status() • extended: true • queryMembers: true
  • 78. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Summary • MySQL Shell brings together developers and DBAs • Unified interface: one tool! • Development and Administration APIs and features • MySQL InnoDB Cluster is THE built-in HA solution for MySQL: • Full-stack: High Availability out-of-the-box • Easy to use: usability as a top concern • Full control of the Cluster using the AdminAPI 78
  • 79. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Resources • MySQL Shell Userguide: – https://dev.mysql.com/doc/refman/en/mysql-shell.html • MySQL InnoDB Cluster Userguide: – http://dev.mysql.com/doc/refman/en/mysql-innodb-cluster-userguide.html • APIs Reference manuals – JavaScript: https://dev.mysql.com/doc/dev/mysqlsh-api-javascript/ – Python: https://dev.mysql.com/doc/dev/mysqlsh-api-python/ • Blogging – http://mysqlserverteam.com/category/high-availability 79
  • 80. Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Thank you! Any questions? 80