• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

How to use mysqlsh to execute addInstance in silent mode

by admin

Question: How to use mysqlsh to execute addInstance in silent mode (from a script) and avoid answering such a question?

cl.addInstance('[USER]@[HOST]:[PORT]')
Please pick an option out of [C]lone/[I]ncremental recover/[A]bort (default Clone):

Adding an instance to InnoDB Cluster requires the specification of what kind of recovery is desired. This can be of two types (incremental or clone), one can be better than another depending on the distance of the data between the candidate instance and the cluster.

As an example, if the instance to be added is empty, the option would be clone. In such a case the command can be executed in silent mode as follows.

cl.addInstance('[USER]@[HOST]:[PORT]', {recoveryMethod: 'clone'})

Filed Under: mysql

Some more articles you might also be interested in …

  1. Configuring mysqld to log slow queries
  2. Understanding the REVOKE statement in MySQL
  3. How to Set Space limits for MySQL for database/schema/table
  4. How to Backup a MySQL Cluster
  5. How To Reset MySQL 8.0 Root Password On Windows
  6. MySQL Shell: Using External Python Modules
  7. MySQL : how to set (change) user password
  8. How to Change the Default Character Set and Collation for a Database in MySQL
  9. What are the various types of locking used in the MySQL Server
  10. MySQL : How To Find the Slowest Queries

You May Also Like

Primary Sidebar

Recent Posts

  • grpck command – Remove corrupt or duplicate entries in the /etc/group and /etc/gshadow files.
  • xxd command – Expressed in hexadecimal form
  • sesearch: command not found
  • macof: command not found

© 2022 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright