I have an annoying problem that I've worked around, but I would like to fix it the "right" way.
This is under MacOS X Server 10.6.latest.
I just replaced the ancient (<5) version of MySQL that came with that server to MariaDB 10.1, via MacPorts. (That was an interesting three-day exercise in itself, but it's finally working.) As part of doing that, the location of the mysqld socket changed, but I changed that in /etc/my.conf and in /etc/php.ini, in three places. I Read The Fine Manual, and I know that to MySQL, "localhost" actually means "socket," rather than 127.0.0.1. So I changed /etc/my.cnf and /etc/php.ini (three places) to refer to the new socket location. I re-started mysqld and apache
However, the moniker "localhost" isn't behaving as expected in two php applications, but working properly in a third.
It works without change in phpMyAdmin, but does not work in MediaWiki nor in a home-brew php application.
I realize there are several different MySQL libraries in php. I changed three different locations in /etc/php.ini.
I'm working around this by changing "localhost" to "localhost:/path/to/mysqld/socket" but that seems... distasteful somehow, and I don't want to struggle with it again if I install some other MySQL applications.
I also considered symlinking /opt/local/var/run/mariadb-10.1/mysqld.sock to wherever the heck Apple had it before, but that also seems like a wrong fix.
Any thoughts on why "localhost" is behaving this way, and ways to get it to behave in the normal manner?
:::: As I went under the new telegraph-wire, I heard it vibrating like a harp high overhead. It was as the sound of a far-off glorious life, a supernal life, which came down to us, and vibrated the lattice-work of this life of ours. -- Henry David Thoreau :::: Jan Steinman, EcoReality Co-op ::::
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/mysql
Feb 16
Reindl Harald Re: localhost != localhost?
Feb 16, 2015; 10:40
Reindl Harald
Re: localhost != localhost?
Search
Lasso Programming
This site manages and broadcasts several email lists pertaining to Lasso Programming and technologies related and used by Lasso developers. Sign up today!