• 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

Question How to set MySQL DB from /Opt directory

Zoo3

Regular Pleskian
Currently I have installed software in /opt directory. That application needs MySQL. I made a database with Plesk, and the software specifies it.
I can not access the database if I specify "localhost:3306" in the setting with that software.
I seem to be able to access the DB by designating it as "XXX.XXX.XXX.XX(Server IP Address):3306".

When I set "localhost:3306", when I look at the error log, a wording such as "using password: YES" is displayed. Of course I have already set the DB's own password. And giving all authority.

That software can not be configured within PLESK, I write the setting in /etc/nignx/conf.d/ on the same server as PLESK and running it.
  • The site(subdomain) itself is created with PLESK UI.
  • I have software in /opt.
  • I am directing nginx directly to /opt.
  • I would like to specify it as "localhost:3306".

How can I do with these conditions?

---
CentOS 7.6 / MariaDB 10.2.21 / Plesk 17.8.11
 
The server name must be identical to the server name that you have set in the user record that is specified to access the database. Sometimes for example "localhost:3306" will not work, but "localhost" will work. Check the user record that you are using to login to the database.
 
Back
Top