burnley
Regular Pleskian
Hi,
I've been playing with using a remote MySQL instance for Plesk 12.5.30 and I've noticed something that's NQR. When trying to install Wordpress selecting the "Install custom" path, it appears that Plesk connects to the remote MySQL server and issues the following statements:
2016-09-28T14:49:33.529101+10:00335069 Query SELECT VERSION()
2016-09-28T14:49:33.531326+10:00335069 Query SELECT * FROM mysql.user WHERE User = 'testu_wordpres_3' LIMIT 1
2016-09-28T14:49:33.539494+10:00335069 Query SELECT VERSION()
2016-09-28T14:49:33.543639+10:00335069 Query CREATE USER 'testu_wordpres_3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<secret>'
2016-09-28T14:49:33.546839+10:00335069 Query GRANT Select, Insert, Update, Delete, Create, Drop, References, Alter, Index, Create Temporary Tables, Lock Tables, Create View, Show View, Create Routine, Alter Routine, Execute, Event, Trigger ON `testuser1local\_wordpress\_1`.* TO 'testu_wordpres_3'@'localhost'
The problem is with 'localhost'. Since the SQL client (the Plesk server) is remote, shouldn't Plesk use its own IP address when creating the user? Something like 'testu_wordpres_3'@'192.168.100.101', 'testu_wordpres_3'@'192.168.100.%' or similar? This approach adds a bit more complexity in the case when Plesk server is using multiple IP addresses, additional business logic might be required for the Panel.
I'd like to know what your thoughts are here, but obviously the remote MySQL server can't be used at least in this scenario.
I've been playing with using a remote MySQL instance for Plesk 12.5.30 and I've noticed something that's NQR. When trying to install Wordpress selecting the "Install custom" path, it appears that Plesk connects to the remote MySQL server and issues the following statements:
2016-09-28T14:49:33.529101+10:00335069 Query SELECT VERSION()
2016-09-28T14:49:33.531326+10:00335069 Query SELECT * FROM mysql.user WHERE User = 'testu_wordpres_3' LIMIT 1
2016-09-28T14:49:33.539494+10:00335069 Query SELECT VERSION()
2016-09-28T14:49:33.543639+10:00335069 Query CREATE USER 'testu_wordpres_3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<secret>'
2016-09-28T14:49:33.546839+10:00335069 Query GRANT Select, Insert, Update, Delete, Create, Drop, References, Alter, Index, Create Temporary Tables, Lock Tables, Create View, Show View, Create Routine, Alter Routine, Execute, Event, Trigger ON `testuser1local\_wordpress\_1`.* TO 'testu_wordpres_3'@'localhost'
The problem is with 'localhost'. Since the SQL client (the Plesk server) is remote, shouldn't Plesk use its own IP address when creating the user? Something like 'testu_wordpres_3'@'192.168.100.101', 'testu_wordpres_3'@'192.168.100.%' or similar? This approach adds a bit more complexity in the case when Plesk server is using multiple IP addresses, additional business logic might be required for the Panel.
I'd like to know what your thoughts are here, but obviously the remote MySQL server can't be used at least in this scenario.