delphix setup with mysql db

  • 0
  • 1
  • Question
  • Updated 2 years ago
  • Answered
  • (Edited)
We have completed delphix implementation with oracle database and about to start the same for mysql. When looking into the source and target host/database requirements, I have some gaps in understanding.
Q1) createDelphixDBUser.sh script was provided with proper details for oracle whereas it is missing for mysql and it was not detailed out properly.
eg: a) If Delphix Engine has to take backup of the MySQL databases, additional privileges for the MySQL user are required
b) If you are providing the MySQL backup file, the operating system user must have read privilege on the MySQL backup file
Above instructions says that "if" mysql backup file is provided then read privilege is required. Don't we need any other privileges for db user "if mysql backup is not provided"?
Can you please share shell script to create dbuser for mysql database?

Q2) Allowing Replication Slave permissions from IPs

To grant the privilege for the user, use the following command:

SQL> GRANT REPLICATION SLAVE ON *.* TO '<delphix>'@'<staging_target_ip>';

Why do we need stating_target_ip ? Does this mean a target ip address? Please clarify
Photo of Viswas Patnala

Viswas Patnala

  • 492 Points 250 badge 2x thumb

Posted 2 years ago

  • 0
  • 1
Photo of Iwan Sutardji

Iwan Sutardji, Employee

  • 140 Points 100 badge 2x thumb
The reason we recommend using IP address to create MySQL users is for security purpose. But for simplicity, you can just do the following.

Log on to your source MySQL instance using existing user account with super privilege, copy and paste the following statements to create MySQL user accounts that will be used by Delphix, which will have enough privilege to generate MySQL db backup.

You can replace 'delphix' with your preferred user name, and replace 'mysql_user_password' with your preferred password.

GRANT SELECT, RELOAD, REPLICATION SLAVE, REPLICATION CLIENT, SHOW VIEW, EVENT, TRIGGER ON *.* TO 'delphix'@'localhost' IDENTIFIED BY 'mysql_user_password';

GRANT SELECT, RELOAD, REPLICATION SLAVE, REPLICATION CLIENT, SHOW VIEW, EVENT, TRIGGER ON *.* TO 'delphix'@'%' IDENTIFIED BY 'mysql_user_password';

flush privileges;

Yes, the staging target IP address is the IP address for your staging host on which Delphix will set up replication.