nipman: переводы
Mysql 5.6: Replication with Global Transaction Identifiers / Репликация с помощью глобальных идентификаторов транзакций
→You may also need to supply appropriate values for the master's host name and port number as well as the user name and password for a replication user account which can be used by the slave to connect to the master; if these have already been set prior to Step 1 and no further changes need to be made, the corresponding options can safely be omitted from the statement shown here.
0 Возможно потребуется дополнительно указать имя и пароль пользователя репликации, так же имени и номера порта master-сервера, которые будут использованы slave-сервером для подключения; Если эти значения уже были установлены на Шаге 1 и никаких дополнительных действий не требуется, эти опции могут быть опущены при выполнении приведенного ниже выражения.
→GTID mode and mysql_upgrade. Prior to MySQL 5.6.7, mysql_upgrade could not connect to a MySQL Server that was running with --gtid-mode=ON unless mysql_upgrade was run with --write-binlog=OFF. (Otherwise, mysqld had to be restarted with --gtid-mode=OFF before running mysql_upgrade, then restarted with --gtid_mode=ON afterwards.) This is not an issue in MySQL 5.6.7 and later, where mysql_upgrade runs with --write-binlog=OFF by default. (Bug #13833710) However, it is not recommended to do so, since mysql_upgrade can make changes to system tables that use the MyISAM storage engine, which is nontransactional.
0 GTID-режим и mysql_upgrade. В версиях MySQL предшесовавших 5.6.7, процесс mysql_upgrade не имел возможности подключиться к серверу, запущенному с опцией --gtid-mode=ON, до перезапуска с опцией --write-binlog=OFF. (Или с опцией --gtid-mode=OFF для запуска mysql_upgrade, а затем с --gtid_mode=ON ). В версиях MySQL 5.6.7 и старше проблема устранена, опция --write-binlog=OFF присутствует по-умолчанию. (Bug #13833710) Тем не менее рекомендуется избегать таких действий, так как mysql_upgrade может вносить изменения в системные таблицы, использующие механизм MyISAM и как следствие не поддерживающие транзакции.
→Prior to MySQL 5.6.9, mysqldump did not record global transaction IDs, and it was necessary to use the binary log and mysqlbinlog to restore GTIDs. (Bug #14797808, Bug #14832472)
0 В версиях предшествовавших 5.6.9, в mysqldump не поддерживалась запись глобальных идентификаторов транзакций, для это было необходимо использовать бинарный лог и mysqlbinlog для восстановления GTID. (Ошибка #14797808, Ошибка #14832472)
→GTID mode and mysqldump. In MySQL 5.6.9 and later, it is possible to import a dump made using mysqldump into a MySQL Server running with GTID mode enabled, provided that there are no GTIDs in the target server's binary log.
0 GTID и mysqldump. В MySQL версии 5.6.9 и старше, возможно импортирование слепка сделанного mysqldump на сервер запущенном в GTID-режиме даже если в его бинарном логе нет GTID.
→sql_slave_skip_counter is not supported when using GTIDs. If you need to skip transactions, use the value of the master's gtid_executed variable instead; see Injecting empty transactions, for more information.
0 При использовании GTID sql_slave_skip_counter не поддерживается. Если нужно пропустить транзакции, используйте gtid_executed на master-сервере; см Внедрение пустых транзакций.
→For information about other required startup options when enabling GTIDs, see Section 16.1.3.2, “Setting Up Replication Using GTIDs”.
0 Для получения инофрмации о других опциях GTID, см 16.1.3.2 "Настройка репликации с помощью GTID".
→Preventing execution of unsupported statements. In order to prevent execution of statements that would cause GTID-based replication to fail, all servers must be started with the --enforce-gtid-consistency option when enabling GTIDs. This causes statements of any of the types discussed previously in this section to fail with an error.
0 Ограничение использования неподдерживаемых выражений. Использование таких выражение приведет к нарушению функционирования GTID-репликации. Все сервера должны быть запущены с опцией --enforce-gtid-consistency. Что обеспечит возникновение ошибки при попытке выполнить описанные выше выражения.
→Temporary tables. CREATE TEMPORARY TABLE and DROP TEMPORARY TABLE statements are not supported inside transactions when using GTIDs (that is, when the server was started with the --enforce-gtid-consistency option). It is possible to use use these statements with GTIDs enabled, but only outside of any transaction, and only with autocommit=1.
0 Временные таблицы. Использование выражение CREATE TEMPORARY TABLE и DROP TEMPORARY TABLE внутри транзакций не поддерживается при использовании GTID (при указании опции --enforce-gtid-consistency). Возможно использование этих выражений только за пределами транзакций и только с autocommit=1.
→CREATE TABLE ... SELECT statements. CREATE TABLE ... SELECT is not safe for statement-based replication. When using row-based replication, this statement is actually logged as two separate events—one for the creation of the table, and another for the insertion of rows from the source table into the new table just created. When this statement is executed within a transaction, it is possible in some cases for these two events to receive the same transaction identifier, which means that the transaction containing the inserts is skipped by the slave. Therefore, CREATE TABLE ... SELECT is not supported when using GTID-based replication.
0 CREATE TABLE ... SELECT выражения. CREATE TABLE ... SELECT небезопасны для командо-ориентированной репликации. При использовании строко-ориентированной репликации это действие записывается в виде двух отдельных событий - создание и добавление строк в созданную таблицу. Выполнение этого выражения внутри транзакции, в некоторых случаях может привести к тому, что обе транзакции получат одинаковый идентификатор, что в свою очередь приведет к пропуску операции вставки на slave-сервере. Поэтому выражение CREATE TABLE ... SELECT не поддерживается при использовании GTID-ориентированной репликации.
→In any of the cases just mentioned, the one-to-one correspondence between transactions and GTIDs is broken, with the result that GTID-based replication cannot function correctly.
0 В каждом из описанных случаев происходит нарушение связи один-к-одному между GTID и транзакцией, что приводит некорректному функционированию репликации.
→Such problems can also occur when the master and the slave use different storage engines for their respective versions of the same table, where one storage engine is transactional and the other is not.
0 Такие проблемы могут возникнуть еще и в том случае, если master и slave сервера используют разные типы хранилищ для одной и той же таблицы, где одно из них поддерживает транзакции а другое нет.
→This restriction is due to the fact that updates to tables that use a nontransactional storage engine mixed with updates to tables that use a transactional storage engine within the same transaction can result in multiple GTIDs being assigned to the same transaction.
0 Это ограничение вызвано с тем, что смешанное обновление транзакционных и нетранзакционных хранилищ во время одной транзакции может привести к появлению множества GTID связанных с одной и той же транзакцией.
→Updates involving nontransactional storage engines. When using GTIDs, updates to tables using nontransactional storage engines such as MyISAM cannot made in the same statement or transaction as updates to tables using transactional storage engines such as InnoDB.
0 Обновление хранилищ, неподдерживающих транзакции. При использовании GTID, одновременное обновление таких хранилищ как MyISAM и InnoDB не может быть произведено в рамках одого выражения или транзакции.
→Because GTID-based replication is dependent on transactions, some features otherwise available in MySQL are not supported when using it. This section provides information about restrictions on and limitations of replication with GTIDs.
0 Следствием зависимости GTID-ориентированной репликации от транзакций, является то, что некоторые функции MySQL не будут доступны при ее использовании. Этот раздел посвещен таким запретам и ограничениям.
→As with the method using empty transactions, this method creates a server that is functionally a snapshot, but in time is able to become a master as its binary log history converges with that of the replication master or group.
0 Как и в случае с методом пустых транзакций, этот метод создает сервер функционально являющийся слепком исходного сервера, который можно будет доступен для использования в качестве master-сервера, как только сойдет на нет отставание его бинарного лога.
→Note
Prior to MySQL 5.6.9, gtid_purged was not settable. (Bug #14797808)
Prior to MySQL 5.6.9, gtid_purged was not settable. (Bug #14797808)
0 Примечание
В версиях MySQL ниже 5.6.9 значение gtid_purged неизменяемо. (Bug #14797808)
В версиях MySQL ниже 5.6.9 значение gtid_purged неизменяемо. (Bug #14797808)
→The master's global gtid_purged variable contains the set of all transactions that have been purged from the master's binary log. As with the method discussed previously (see Injecting empty transactions), you can record the value of gtid_executed on the server from which the snapshot was taken (in place of copying the binary logs to the new server). Unlike the previous method, there is no need to commit empty transactions (or to issue PURGE BINARY LOGS); instead, you can set gtid_purged on the slave directly, based on the value of gtid_executed on the server from which the backup or snapshot was taken.
0 Глобальная переменная gtid_purged на master-сервере содержит список всех транзакций, которые были исключены из бинарного лога. Как и в предыдущем методе (см Добавление пустых транзакций), вы можете записать значение gtid_executed источника данных (вместо копирования бинарного лога). В отличии от предыдущего метода, нет необходимости сохранять пустые транзакции (или запускать PURGE BINARY LOGS); вместо этого можно просто установить на целевом сервере gtid_purged равной gtid_executed сервера с которого данные были получены.
→Excluding transactions with gtid_purged
0 Пропуск транзакций с помощью gtid_purged
→This method creates a server that is essentially a snapshot, but in time is able to become a master as its binary log history converges with that of the replication stream (that is, as it catches up with the master or masters). This outcome is similar in effect to that obtained using the remaining provisioning method, which we discuss in the next few paragraphs.
0 Этот метод позволяет создавать slave-сервера, являющиеся слепком текущего состояния master-севера. Slave-севрер, который может стать master-сервером так как его бинарный лог сходится с потоком данных репликации (в том виде в котором его генерирует один или несколько master-серевров). Этот метод дает тот же результат что и последний оставшийся метод, рассмотрим его далее.
→You should do this to prevent this server from flooding the replication stream with false transactions in the event that it is later promoted to master. (The FLUSH LOGS statement forces the creation of a new binary log file; PURGE BINARY LOGS purges the empty transactions, but retains their identifiers.)
0 Это делается для того, что бы эта пустая транзакция не попала в поток реплицируемых данных, в случае повышения этого slave-сервера до master. (Выражение FLUSH LOGS приводит к созданию нового файла лога, PURGE BINARY LOGS удаляет пустые транзакции, оставив их идентификаторы).
Резюме
- Пол:
- мужчина
- Родной язык:
- русский
- С нами:
-
с 1 мая 2010 г.
(6014 дней)
Не является членом клуба. - Деятельность:
-
357 версий перевода
с общим рейтингом 5
12 комментариев
Карма: 1 (оценок: 1)
