PDF (A4) - 43.4Mb
Man Pages (TGZ) - 297.2Kb
Man Pages (Zip) - 402.4Kb
Info (Gzip) - 4.3Mb
Info (Zip) - 4.3Mb
MySQL Globalization
MySQL Information Schema
MySQL Installation Guide
Security in MySQL
Starting and Stopping MySQL
MySQL and Linux/Unix
MySQL and Windows
MySQL and macOS
MySQL and Solaris
Building MySQL from Source
MySQL Restrictions and Limitations
MySQL Partitioning
MySQL Tutorial
MySQL Performance Schema
MySQL Replication
Using the MySQL Yum Repository
MySQL NDB Cluster 8.0
This section covers the steps necessary to install the correct executables for each type of Cluster node from precompiled binaries supplied by Oracle.
For setting up a cluster using precompiled binaries, the first step in the installation process for each cluster host is to download the binary archive from theNDB Cluster downloads page. (For the most recent 64-bit NDB 8.0 release, this ismysql-cluster-gpl-8.0.43-linux-glibc2.12-x86_64.tar.gz.) We assume that you have placed this file in each machine's/var/tmp directory.
If you require a custom binary, seeSection 2.8.5, “Installing MySQL Using a Development Source Tree”.
After completing the installation, do not yet start any of the binaries. We show you how to do so following the configuration of the nodes (seeSection 25.3.3, “Initial Configuration of NDB Cluster”).
SQL nodes. On each of the machines designated to host SQL nodes, perform the following steps as the systemroot user:
Check your
/etc/passwdand/etc/groupfiles (or use whatever tools are provided by your operating system for managing users and groups) to see whether there is already amysqlgroup andmysqluser on the system. Some OS distributions create these as part of the operating system installation process. If they are not already present, create a newmysqluser group, and then add amysqluser to this group:$> groupadd mysql$> useradd -g mysql -s /bin/false mysqlThe syntax foruseradd andgroupadd may differ slightly on different versions of Unix, or they may have different names such asadduser andaddgroup.
Change location to the directory containing the downloaded file, unpack the archive, and create a symbolic link named
mysqlto themysqldirectory.NoteThe actual file and directory names vary according to the NDB Cluster version number.
$> cd /var/tmp$> tar -C /usr/local -xzvf mysql-cluster-gpl-8.0.43-linux-glibc2.12-x86_64.tar.gz$> ln -s /usr/local/mysql-cluster-gpl-8.0.43-linux-glibc2.12-x86_64 /usr/local/mysqlChange location to the
mysqldirectory and set up the system databases usingmysqld--initializeas shown here:$> cd mysql$> mysqld --initializeThis generates a random password for the MySQL
rootaccount. If you donot want the random password to be generated, you can substitute the--initialize-insecureoption for--initialize. In either case, you should reviewSection 2.9.1, “Initializing the Data Directory”, for additional information before performing this step. See alsoSection 6.4.2, “mysql_secure_installation — Improve MySQL Installation Security”.Set the necessary permissions for the MySQL server and data directories:
$> chown -R root .$> chown -R mysql data$> chgrp -R mysql .Copy the MySQL startup script to the appropriate directory, make it executable, and set it to start when the operating system is booted up:
$> cp support-files/mysql.server /etc/rc.d/init.d/$> chmod +x /etc/rc.d/init.d/mysql.server$> chkconfig --add mysql.server(The startup scripts directory may vary depending on your operating system and version—for example, in some Linux distributions, it is
/etc/init.d.)Here we use Red Hat'schkconfig for creating links to the startup scripts; use whatever means is appropriate for this purpose on your platform, such asupdate-rc.d on Debian.
Remember that the preceding steps must be repeated on each machine where an SQL node is to reside.
Data nodes. Installation of the data nodes does not require themysqld binary. Only the NDB Cluster data node executablendbd (single-threaded) orndbmtd (multithreaded) is required. These binaries can also be found in the.tar.gz archive. Again, we assume that you have placed this archive in/var/tmp.
As systemroot (that is, after usingsudo,su root, or your system's equivalent for temporarily assuming the system administrator account's privileges), perform the following steps to install the data node binaries on the data node hosts:
Change location to the
/var/tmpdirectory, and extract thendbd andndbmtd binaries from the archive into a suitable directory such as/usr/local/bin:$> cd /var/tmp$> tar -zxvf mysql-cluster-gpl-8.0.43-linux-glibc2.12-x86_64.tar.gz$> cd mysql-cluster-gpl-8.0.43-linux-glibc2.12-x86_64$> cp bin/ndbd /usr/local/bin/ndbd$> cp bin/ndbmtd /usr/local/bin/ndbmtd(You can safely delete the directory created by unpacking the downloaded archive, and the files it contains, from
/var/tmponcendb_mgm andndb_mgmd have been copied to the executables directory.)Change location to the directory into which you copied the files, and then make both of them executable:
$> cd /usr/local/bin$> chmod +x ndb*
The preceding steps should be repeated on each data node host.
Although only one of the data node executables is required to run an NDB Cluster data node, we have shown you how to install bothndbd andndbmtd in the preceding instructions. We recommend that you do this when installing or upgrading NDB Cluster, even if you plan to use only one of them, since this saves time and trouble in the event that you later decide to change from one to the other.
The data directory on each machine hosting a data node is/usr/local/mysql/data. This piece of information is essential when configuring the management node. (SeeSection 25.3.3, “Initial Configuration of NDB Cluster”.)
Management nodes. Installation of the management node does not require themysqld binary. Only the NDB Cluster management server (ndb_mgmd) is required; you most likely want to install the management client (ndb_mgm) as well. Both of these binaries also be found in the.tar.gz archive. Again, we assume that you have placed this archive in/var/tmp.
As systemroot, perform the following steps to installndb_mgmd andndb_mgm on the management node host:
Change location to the
/var/tmpdirectory, and extract thendb_mgm andndb_mgmd from the archive into a suitable directory such as/usr/local/bin:$> cd /var/tmp$> tar -zxvf mysql-cluster-gpl-8.0.43-linux-glibc2.12-x86_64.tar.gz$> cd mysql-cluster-gpl-8.0.43-linux-glibc2.12-x86_64$> cp bin/ndb_mgm* /usr/local/bin(You can safely delete the directory created by unpacking the downloaded archive, and the files it contains, from
/var/tmponcendb_mgm andndb_mgmd have been copied to the executables directory.)Change location to the directory into which you copied the files, and then make both of them executable:
$> cd /usr/local/bin$> chmod +x ndb_mgm*
InSection 25.3.3, “Initial Configuration of NDB Cluster”, we create configuration files for all of the nodes in our example NDB Cluster.
PDF (A4) - 43.4Mb
Man Pages (TGZ) - 297.2Kb
Man Pages (Zip) - 402.4Kb
Info (Gzip) - 4.3Mb
Info (Zip) - 4.3Mb
MySQL Globalization
MySQL Information Schema
MySQL Installation Guide
Security in MySQL
Starting and Stopping MySQL
MySQL and Linux/Unix
MySQL and Windows
MySQL and macOS
MySQL and Solaris
Building MySQL from Source
MySQL Restrictions and Limitations
MySQL Partitioning
MySQL Tutorial
MySQL Performance Schema
MySQL Replication
Using the MySQL Yum Repository
MySQL NDB Cluster 8.0