8.4 中文镜像

MySQL 8.4 参考手册 · 中文镜像

正文为中文,英文原文默认隐藏。点击任意中文段落即可展开 / 收起对应英文原文。

打开官方英文原文 ↗

译文由机器翻译生成,仅供理解参考;有疑问请以官方英文原文为准。

中文点击中文段落可显示 / 隐藏英文原文本页译文覆盖 100%

25.1 一般信息25.1 General Information

MySQL NDB Cluster 使用带有NDB存储引擎的 MySQL 服务器。标准 MySQL Server 8.4 二进制文件(由 Oracle 构建)中不包含对NDB存储引擎的支持。相反,Oracle 提供的 NDB Cluster 二进制文件用户应升级到支持平台的最新 NDB Cluster 二进制版本——这些版本包括应能在大多数 Linux 发行版上使用的 RPM 包。自行从源码构建的 NDB Cluster 8.4 用户应使用为 MySQL 8.4 提供的源代码,并使用提供 NDB 支持所需的编译选项进行构建。(获取源代码的位置在本节后面列出。)MySQL NDB Cluster uses the MySQL server with the NDB storage engine. Support for the NDB storage engine is not included in standard MySQL Server 8.4 binaries built by Oracle. Instead, users of NDB Cluster binaries from Oracle should upgrade to the most recent binary release of NDB Cluster for supported platforms—these include RPMs that should work with most Linux distributions. NDB Cluster 8.4 users who build from source should use the sources provided for MySQL 8.4 and build with the options required to provide NDB support. (Locations where the sources can be obtained are listed later in this section.)

Important

MySQL NDB 集群不支持 InnoDB 集群,InnoDB 集群必须使用 MySQL Server InnoDB 存储引擎以及 NDB 集群发行版中未包含的其他应用程序来部署。MySQL Server 8.4 二进制文件不能与 MySQL NDB 集群一起使用。有关部署和使用 InnoDB 集群的更多信息,请参见 MySQL AdminAPI。第 25.2.6 节,“使用 InnoDB 的 MySQL Server 与 NDB 集群对比”讨论了 NDB 和 InnoDB 存储引擎之间的差异。MySQL NDB Cluster does not support InnoDB Cluster, which must be deployed using MySQL Server InnoDB storage engine as well as additional applications that are not included in the NDB Cluster distribution. MySQL Server 8.4 binaries cannot be used with MySQL NDB Cluster. For more information about deploying and using InnoDB Cluster, see MySQL AdminAPI. Section 25.2.6, “MySQL Server Using InnoDB Compared with NDB Cluster”, discusses differences between the NDB and InnoDB storage engines.

支持的平台。 NDB Cluster 目前可在多种平台上使用并得到支持。有关特定操作系统版本、操作系统发行版和硬件平台组合的具体支持级别,请参阅 https://www.mysql.com/support/supportedplatforms/cluster.html。Supported Platforms.  NDB Cluster is currently available and supported on a number of platforms. For exact levels of support available for on specific combinations of operating system versions, operating system distributions, and hardware platforms, please refer to https://www.mysql.com/support/supportedplatforms/cluster.html.

可用性。 NDB Cluster 的二进制包和源代码包可在支持的平台上通过 https://dev.mysql.com/downloads/cluster/ 获取。Availability.  NDB Cluster binary and source packages are available for supported platforms from https://dev.mysql.com/downloads/cluster/.

NDB Cluster 软件中使用的版本字符串。 MySQL NDB Cluster 发行版提供的 mysql 客户端显示的版本字符串使用以下格式:Version strings used in NDB Cluster software.  The version string displayed by the mysql client supplied with the MySQL NDB Cluster distribution uses this format:

mysql-mysql_server_version-cluster

mysql_server_version 表示 NDB Cluster 版本所基于的 MySQL 服务器的版本。使用 -DWITH_NDB 或等效选项从源码构建时,会在版本字符串上添加 -cluster 后缀。(参见 第 25.3.1.4 节,“在 Linux 上从源码构建 NDB Cluster”,以及 第 25.3.2.2 节,“在 Windows 上从源码编译和安装 NDB Cluster”。)你可以在 mysql 客户端看到这种格式,如下所示:mysql_server_version represents the version of the MySQL Server on which the NDB Cluster release is based. Building from source using -DWITH_NDB or the equivalent adds the -cluster suffix to the version string. (See Section 25.3.1.4, “Building NDB Cluster from Source on Linux”, and Section 25.3.2.2, “Compiling and Installing NDB Cluster from Source on Windows”.) You can see this format used in the mysql client, as shown here:

$> mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 8.4.7-cluster Source distribution

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> SELECT VERSION()\G
*************************** 1. row ***************************
VERSION(): 8.4.7-cluster
1 row in set (0.00 sec)

其他 NDB Cluster 程序显示的版本字符串(通常不包含在 MySQL 8.4 发行版中)使用此格式:The version string displayed by other NDB Cluster programs not normally included with the MySQL 8.4 distribution uses this format:

mysql-mysql_server_version ndb-ndb_engine_version

mysql_server_version 表示 NDB Cluster 发行版所基于的 MySQL 服务器版本。对于 NDB Cluster 8.4,这是 8.4.n,其中 n 是发行编号。ndb_engine_version 是此 NDB Cluster 软件发行版使用的 NDB 存储引擎的版本。对于 NDB 8.4,此数字与 MySQL 服务器版本相同。您可以在 ndb_mgm 客户端中 SHOW 命令的输出中看到此格式,如下所示:mysql_server_version represents the version of the MySQL Server on which the NDB Cluster release is based. For NDB Cluster 8.4, this is 8.4.n, where n is the release number. ndb_engine_version is the version of the NDB storage engine used by this release of the NDB Cluster software. For NDB 8.4, this number is the same as the MySQL Server version. You can see this format used in the output of the SHOW command in the ndb_mgm client, like this:

ndb_mgm> SHOW
Connected to Management Server at: localhost:1186 (using cleartext)
Cluster Configuration
---------------------
[ndbd(NDB)]     2 node(s)
id=1    @10.0.10.6  (mysql-8.4.7 ndb-8.4.7, Nodegroup: 0, *)
id=2    @10.0.10.8  (mysql-8.4.7 ndb-8.4.7, Nodegroup: 0)

[ndb_mgmd(MGM)] 1 node(s)
id=3    @10.0.10.2  (mysql-8.4.7 ndb-8.4.7)

[mysqld(API)]   2 node(s)
id=4    @10.0.10.10  (mysql-8.4.7 ndb-8.4.7)
id=5 (not connected, accepting connect from any host)

与标准 MySQL 8.4 版本兼容。 虽然许多标准的 MySQL 模式和应用程序可以使用 NDB Cluster 工作,但同样也存在未经修改的应用程序和数据库模式在使用 NDB Cluster 时可能略微不兼容或性能不佳的情况(参见 第 25.2.7 节,“NDB Cluster 的已知限制”)。大多数这些问题可以解决,但这也意味着您很可能无法直接将现有应用程序的数据存储——例如当前使用 MyISAM 或 InnoDB——切换为使用 NDB 存储引擎,而不考虑模式、查询和应用程序可能需要的更改。没有 NDB 支持编译的 mysqld(即,构建时未使用 -DWITH_NDB 或 -DWITH_NDBCLUSTER_STORAGE_ENGINE)无法作为编译了 NDB 支持的 mysqld 的直接替代品。Compatibility with standard MySQL 8.4 releases.  While many standard MySQL schemas and applications can work using NDB Cluster, it is also true that unmodified applications and database schemas may be slightly incompatible or have suboptimal performance when run using NDB Cluster (see Section 25.2.7, “Known Limitations of NDB Cluster”). Most of these issues can be overcome, but this also means that you are very unlikely to be able to switch an existing application datastore—that currently uses, for example, MyISAM or InnoDB—to use the NDB storage engine without allowing for the possibility of changes in schemas, queries, and applications. A mysqld compiled without NDB support (that is, built without -DWITH_NDB or -DWITH_NDBCLUSTER_STORAGE_ENGINE) cannot function as a drop-in replacement for a mysqld that is built with it.

NDB 集群开发源代码树。 NDB 集群开发树也可以通过 https://github.com/mysql/mysql-server 访问。NDB Cluster development source trees.  NDB Cluster development trees can also be accessed from https://github.com/mysql/mysql-server.

在 https://github.com/mysql/mysql-server 上维护的 NDB 集群开发源代码是以 GPL 许可的。有关如何使用 Git 获取 MySQL 源代码并自行构建的详细信息,请参见 第 2.8.5 节,“使用开发源代码树安装 MySQL”。The NDB Cluster development sources maintained at https://github.com/mysql/mysql-server are licensed under the GPL. For information about obtaining MySQL sources using Git and building them yourself, see Section 2.8.5, “Installing MySQL Using a Development Source Tree”.

Note

与 MySQL Server 8.4 一样,NDB 集群 8.4 版本是使用 CMake 构建的。As with MySQL Server 8.4, NDB Cluster 8.4 releases are built using CMake.

NDB Cluster 8.4 作为长期支持(LTS)版本可用,推荐用于新部署。NDB Cluster 8.0 是之前的 GA 发行系列(参见 MySQL NDB Cluster 8.0),仍然在生产环境中受支持。NDB Cluster 7.6 和 7.5 是早期的 GA 发行版本,仍然在生产环境中受支持,尽管我们建议在计划用于生产的新部署中使用 NDB Cluster 8.4。NDB Cluster 8.4 is available as an LTS release, and is recommended for new deployments. NDB Cluster 8.0 is the previous GA release series (see MySQL NDB Cluster 8.0), still supported in production. NDB Cluster 7.6 and 7.5 are earlier GA releases still supported in production, although we recommend NDB Cluster 8.4 for new deployments intended for use in production.

NDB Cluster 7.4 和 7.3 是之前的 GA 发行版本,现已停用;它们不再维护或受支持。NDB Cluster 7.4 and 7.3 were previous GA releases which have been discontinued; they are no longer maintained or supported.

有关 NDB Cluster 的更多信息可以在 MySQL 网站上找到,网址为 https://www.mysql.com/products/cluster/。Additional information regarding NDB Cluster can be found on the MySQL website at https://www.mysql.com/products/cluster/.

附加资源。 有关 NDB Cluster 的更多信息可以在以下位置找到:Additional Resources.  More information about NDB Cluster can be found in the following places: