Announcement

Announcement Module
Collapse
No announcement yet.

User permissions not replicating (5.5.31).

Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • User permissions not replicating (5.5.31).

    Hello,

    We have setup a 4 node cluster. I started the first node using `service mysql bootstrap-pxc` and prepopulated our database with some mysql.user values by running:

    Code:
    INSERT INTO `mysql`.`user` VALUES
    ('localhost', 'user', ... ),
    ('localhost', 'user2', ...);
    FLUSH PRIVILEGES;
    However, when we bring up nodes 2-4 these permissions are not replicated and I am unable to connect as these users. The only way to connect is to login as our root user on node one, then manually run:

    Code:
    GRANT INSERT,...,DELETE ON dbname.* TO 'user'@'localhost' IDENTIFIED BY PASSWORD 'password';
    Then the user is then replicated out to the cluster and I am able to connect.

    Is this a bug, or is there something I'm doing wrong? Here is a snippet of our build script that runs this:

    Code:
    service mysql bootstrap-pxc
    mysql -uroot < /tmp/bootstrap.sql
    rm /tmp/*.sql
    Best regards,
    Andrew

  • #2
    You must use the GRANT commands to assign permissions. Item #1: http://support.severalnines.com/entr...tion-for-mysql

    Comment


    • #3
      You can also use MyISAM replication feature -
      HTML Code:
      wsrep_replicate_myisam = ON
      , but indeed GRANT commands are better approach. While it's (still) OK for some system tables, I would not recommend using MyISAM for any production tables.

      Comment

      Working...
      X