Group: Member
Post Group: Newbie
Posts: 15
Status:
|
Softaculous generates wp-config.php with localhost:3306, which causes PHP to attempt a connection to a unix socket rather than over TCP/IP. The unix socket file does not exist in the chroot, so the database connection fails.
A similar issue is in “APS installer in chrooted PHP-FPM: database connection problems” https://git.ispconfig.org/ispconfig/ispconfig3/issues/5235, fixed with https://git.ispconfig.org/ispconfig/ispconfig3/-/merge_requests/879/diffs . Since Softaculous php files are encrypted, I can’t hack in.
Trying to change $conf['db_host'] = '127.0.0.1'; in /usr/local/ispconfig/server/lib/config.inc.php
And /usr/local/ispconfig/interface/lib/config.inc.php doesn’t help either.
BTW, when creating the website, where does softaculous gets his information about the database? From mysql_clientdb_plugin.inc.php? Maybe we could also hack some ispconfig plugins.
A related issue is https://www.softaculous.com/board/index.php?tid=16135&title=ispconfig “Yes you can use an external MySQL server. You need to set that server as default MySQL server and then Softaculous will create databases on the remote server.” The difference is that I have to trigger 127.0.0.1, instead of localhost, for default local server.
Using [client] protocol=tcp in my.cnf won’t help ( via https://serverfault.com/questions/337818/how-to-force-mysql-to-connect-by-tcp-instead-of-a-unix-socket)
Thanks!
|