• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion
  • Please beaware of a breaking change in the REST API on the next Plesk release (18.0.62).
    Starting from Plesk Obsidian 18.0.62, requests to REST API containing the Content-Type header with a media-type directive other than “application/json” will result in the HTTP “415 Unsupported Media Type” client error response code. Read more here

Resolved Custom Wordpress install attempts to create the DB user credentials with the wrong hostname

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.
 
Nevermind the noise :)
I think I've worked this one out: in the "Database Hosting Settings" I had "Default settings for remote access of database users" set to "Allow local connections only". After changing it to "Allow remote connections from any host" Plesk started to create the users with the host set to '%', which is what I needed.
Thanks.
 
Back
Top