MySQL Cluster concepts

Source: Internet
Author: User

We all know that MySQL Cluster is a technology. Its main function is to deploy the Cluster of a database in memory in a non-shared system. Without a shared architecture, the system can use cheap hardware without special requirements for hardware and software.

In addition, since each component has its own memory and disk, there is no single point of failure.

MySQL Cluster is composed of a group of computers, each of which runs a variety of processes, including MySQL servers, NDB Cluster data nodes, management servers, and possibly) dedicated data access programs. For the relationship between these components in the Cluster, see:

All these nodes form a complete MySQL cluster system. Data is stored in the storage engine of the "NDB storage server", and the table structure is saved in the "MySQL server. Applications access these data tables through the "MySQL Server", and the cluster management server manages the "NDB storage server" through the management tool (ndb_mgmd ".

By introducing MySQL Cluster into the open source world, MySQL provides Cluster data management with high availability, high performance, and scalability for all people who need it.

Basic concepts of MySQL Cluster

"NDB" is a "in-memory" storage engine with high availability and good data consistency.

MySQL Cluster can use a variety of failover and load balancing options to configure the NDB storage engine, but it is the easiest to do this on the storage engine at the Cluster level. The NDB storage engine of MySQL Cluster contains the complete dataset, which depends only on other data in the Cluster.

Currently, the Cluster of the MySQL Cluster can be configured independently of the MySQL server. In MySQL Cluster, each part of the Cluster is considered as one node.

Management (MGM) nodes: these nodes manage other nodes in the MySQL Cluster, such as providing configuration data, starting and stopping nodes, and running backups. Because these nodes are responsible for managing the configurations of other nodes, they should be started before other nodes are started. The MGM node is started with the command "ndb_mgmd.

Data nodes: these nodes are used to save Cluster data. The number of data nodes is related to the number of copies, which is a multiple of the segments. For example, if two copies have two segments, each of them has four data nodes. However, there is no need to set multiple copies. The data node is started with the "ndbd" command.

SQL node: This is the node used to access Cluster data. For MySQL Cluster, the client node is a traditional MySQL server that uses the NDB Cluster Storage engine. Generally, an SQL node is started with the command "mysqld-ndbcluster", or "ndbcluster" is added to "my. cnf" and then started with "mysqld. Note: in many cases, the term "Node" is used for computers, but when discussing MySQL Cluster, it represents a process. A single computer can have any number of nodes. Therefore, we use the term "Cluster host ".

The Management Server (MGM node) is responsible for managing Cluster configuration files and Cluster logs. Each node in the Cluster retrieves configuration data from the Management Server and requests to determine the location of the management server. When a new event occurs in the data node, the node transmits the information about the event to the management server, and then writes the information to the Cluster log.

In addition, there can be any number of Cluster client processes or applications. They are divided into two types:

Standard MySQL clients: For MySQL clusters, they are no different from standard non-Cluster MySQL clients. In other words, you can access the MySQL Cluster from existing MySQL applications written in PHP, Perl, C, C ++, Java, Python, and Ruby.

Management clients: these clients are connected to the Management Server and provide only debugging versions for starting and stopping nodes, starting and stopping message tracing) displays the node version and status, starts and stops the backup, and other commands.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.