Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

REPLICATION SLAVE and REPLICATION CLIENT permissions

2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

The version tested is 5.6.30

REPLICATION SLAVE is often used to establish the user rights needed to establish replication, that is, slave server must be authorized by master server to have that permission before it can be replicated by that user.

And the command "SHOW SLAVE HOSTS" is related to REPLICATION SLAVE permissions, otherwise an error will be reported during execution:

ERROR 1227 (42000): Access denied; you need (at least one of) the REPLICATION SLAVE privilege (s) for this operation

REPLICATION CLIENT cannot be used to establish replication, but when you have this permission, you can use commands such as "SHOW SLAVE STATUS", "SHOW MASTER STATUS", etc.

After version 5.6.6, you can also use "SHOW BINARY LOGS".

Original text:

The REPLICATION CLIENT privilege enables the use of SHOW MASTER STATUS and SHOW SLAVE STATUS. In MySQL 5.6.6 and later, it also enables the use of the SHOW BINARY LOGS statement.The REPLICATION SLAVE privilege should be granted to accounts that are used by slave servers to connect to the current server as their master. Without this privilege, the slave cannot request updates that have been made to databases on the master server.

References:

MySQL 5.6 Reference Manual-6.2.1 Privileges Provided by MySQL

Author's official account on Wechat (continuously updated)

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report