• Dear Pleskians! The Plesk Forum will be undergoing scheduled maintenance on Monday, 7th of July, at 9:00 AM UTC. The expected maintenance window is 2 hours.
    Thank you in advance for your patience and understanding on the matter.

How to share mysql db between domains?

J

jackop

Guest
I created a mysql db in domain A, and I now want to access it from domain B.
How can I do that?
 
Are the domains on the same server? If not you will need to modify the "mysql" database entries on the target server to allow remote access.

Log in to mysql as admin and run the following commands:

use mysql;

update user set Host = '%' where User = 'TargetDB_Username';

update db set Host = '%' where Db = 'TargetDB_Database';

flush privileges;

Also make sure the 3306 port is open on the firewall, at least for the connecting IP. :D
 
Back
Top