Running the Cluster Database Replication and Message: ERROR 1045 (28000): Access denied for user 'repluser'@'Your_Machine_Name' (using password: YES)
search cancel

Running the Cluster Database Replication and Message: ERROR 1045 (28000): Access denied for user 'repluser'@'Your_Machine_Name' (using password: YES)

book

Article ID: 10901

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

When running the cluster database replication received the following error:

Message: ERROR 1045 (28000): Access denied for user 'repluser'@'Your_Machine_Name' (using password: YES)

[root@localhost bin]# ./create_slave.sh
--> For verbose output run with -v

Enter hostname or IP for the MASTER: primary_host
Enter replication user: [repluser]
Enter replication password: [replpass]
Enter MySQL root user: [root]
Enter MySQL root password: []
Do you want to clone a database from primary_host (yes or no)? [no]

==> Error getting master status

Message: ERROR 1045 (28000): Access denied for user 'repluser'@'Your_Machine_Name' (using password: YES)

Environment

This fix will work with all version of Gateway as long as they are using MYSQL has the Database.

Cause

The repluser was created under a different Hostname or used an IP address instead of a Hostname and vice versa.

Resolution

Commands that need to be ran (in order on both nodes) from within the MySQL Database:

# DELETE FROM mysql.user WHERE user = "repluser";

# FLUSH PRIVILEGES;

 

Then run the following script:

# /opt/SecureSpan/Appliance/bin/add_slave_user.sh

 

You can follow the instructions states in the documentation

https://techdocs.broadcom.com/us/en/ca-enterprise-software/layer7-api-management/api-gateway/10-1/install-configure-upgrade/configure-a-gateway-cluster/configuring-cluster-database-replication.html