Slave Status Logs-opracowanie

Nasza ocena:

3
Wyświetleń: 532
Komentarze: 0
Notatek.pl

Pobierz ten dokument za darmo

Podgląd dokumentu
Slave Status Logs-opracowanie - strona 1

Fragment notatki:

Slave Status Logs
A replication slave server creates two logs. By default, these logs are files named master.info
and relay-log.info and created in the data directory. The names and locations of these files can
be changed by using the --master-info-file [2006] and --relay-log-info-file [2008]
options, respectively. In MySQL 5.6 and later, either or both of these logs can also be written to tables
in the mysql database by starting the server with the appropriate option: use --master-inforepository
[2037] to have the master info log written to the mysql.slave_master_info table,
and use --relay-log-info-repository [2038] to have the relay log info log written to the
mysql.slave_relay_log_info table. See Section 16.1.4, “Replication and Binary Logging Options
and Variables”.
The two status logs contain information like that shown in the output of the SHOW SLAVE STATUS
statement, which is discussed in Section 13.4.2, “SQL Statements for Controlling Slave Servers”.
Because the status logs are stored on disk, they survive a slave server's shutdown. The next time the
slave starts up, it reads the two logs to determine how far it has proceeded in reading binary logs from
the master and in processing its own relay logs.
The master info log file or table should be protected because it contains the password for connecting to
the master. See Section 6.1.2.3, “Passwords and Logging”.
The slave I/O thread updates the master info log. The following table shows the correspondence
between the lines in the master.info file, the columns in the mysql.slave_master_info table,
and the columns displayed by SHOW SLAVE STATUS.
... zobacz całą notatkę



Komentarze użytkowników (0)

Zaloguj się, aby dodać komentarz