|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #81182 Could not create a MySQLi connection
Submitted: 2021-06-20 22:03 UTC Modified: 2021-06-20 22:39 UTC
From: list at understudy dot net Assigned:
Status: Not a bug Package: MySQLi related
PHP Version: 7.4.20 OS: FreeBSD 12.2
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: list at understudy dot net
New email:
PHP Version: OS:


 [2021-06-20 22:03 UTC] list at understudy dot net
Specs on system:
FBSD 12.2 
PHP 7.4.20 
MariaDB 10.5.10
Coppermine 1.6.10
phpmyadmin 4.9.7

Error from coppermine when trying to connect to database on install step 6 
Could not create a MySQLi connection, please check the MySQLi details entered
Database error: No such file or directory

Through CLI DB is confirmed and working. 
Tests on CLI and with port 3306 on localhost and show ok. 

Test also preformed with phpmyadmin which gave similar errors in their setup. 

Issue: failure to connect to DB via mysqli through "localhost" 

Possible solution implemented:

edit the following file:

add the following lines:

This solution may only work for FBSD. It is uncertain if this solution will work with Linux or Windows or if they are having this issue. 

Test script:

Expected result:
I would like to see if the ext-20-mysqli.ini needs to be modified in the ports/pkg for FBSD or if this is an issue that may pertain to other OS systems out there. 


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2021-06-20 22:10 UTC]
-Status: Open +Status: Not a bug
 [2021-06-20 22:10 UTC]
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

If you installed PHP and MariaDB/"MySQL" through standard FreeBSD mechanisms (like pkg) and did not install anything yourself manually (for example, by compiling locally) then you may need to report this issue to FreeBSD and/or whoever maintains those packages.

But first, consider asking on StackOverflow or elsewhere to see if you made a mistake somewhere during installation or configuration.
 [2021-06-20 22:39 UTC] list at understudy dot net
Thank you for your time. I apologize if this is the wrong place.
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Sat Nov 26 12:03:57 2022 UTC