Recent changes to mariadb changed the default location of mysql.sock from /tmp/ to /var/run/mysql/ which causes PHP scripts to not be able to connect without manually adding the path in php.ini. See bug #246694 for more info. It was my understanding that PHP was supposed to be able to automatically figure out the correct location for the socket directory when it's compiled however I've tried reinstalling the php74, php74-mysqli, and php74-pdo_mysql ports via "make install clean" but it still doesn't work. Is this something that can be fixed via a patch or is the only way to manually go edit the php.ini file on every affected server?
^Triage: - Assign to php-* maintainer - Request feedback from MariaDB maintainer
Confirmed. The default socket path has changed for the ports, but not for existing configurations in /var/db/mysql/my.cnf. Result is that mariadbd uses /var/db/mysql/mysql.sock whereas the client's default installation uses /var/run/mysql/mysql.sock. This is documented in UPDATING 20200526. Closing this bug as "Works as intended". I know this affects you and is a POLA violation, but I have to get the MariaDB ports to respect hier(7). Changing the rc(8) script in the 10.4 version to change the default my.cnf felt too breaking to pursue. If you upgrade to 10.5 this "shoul all work" (TM). I am interested in your experience in non-production environments. (The first GA release is not the one you want to run in production).