We build. You grow.

Get best community software here

Start a social network, a fan-site, an education project with oxwall - free opensource community software

Cannot connect to database-> need to specify the port if not using standard port. | Forum

Matt
Matt Aug 8 '10
Hello,

I wanted to install a test platform, but I have issues on my hosting paltform (I use www.icdsoft.com).
I got stuck at the database page of the installation wizard. Always "Cannot connect to database" error.

The informations my control panel gave me are:
Local (web applications):
Host: localhost
Socket: /tmp/mysql5.sock

Note: Most PHP applications/scripts will accept the following syntax:
MySQL Host: localhost:/tmp/mysql5.sock

Remote (MySQL clients):
Host: mysql5.hostxxx.com
Port: 3307

-> The localhost option didn't work successfully, I tried to add pdo_mysql.default_socket= /tmp/mysql5.sock in the php.ini, but didn't worked

-> Using the remote settings didn't worked as well.

After digging, I had to hack the database.php file to manually add the port=3307 into the $dns
So I ended up with something like this :
$dsn = "mysql:host=mysql5.hostxxx.com;port=3307;dbname=mydbname";

And it works! So it would be nice if we can add the port parameters during the installation process.

Also not sure why I cannot use localhost ?

Hope it helps,

Matt
Emil Team
Emil Aug 9 '10
Matt,

Thanks for report. We are adding MySQL port to the installation wizard.

I'm also not sure why you can't use localhost. We use it for test and production setups.

Emil.
The Forum post is edited by Emil Aug 9 '10
devikakhan
devikakhan Feb 4 '23

Each form of records version is designed for interacting with distinct forms of stakeholders. We will briefly describe and give an explanation for using those data fashions underneath. If you would love a closer clarification. https://app.erdlab.io The conceptual information model is the first information model we construct. In a conceptual facts model, the primary entities are defined, commonly the use of ER diagrams. This is likewise when the principle stakeholders from the enterprise aspect participate.