mysql problem with socket
Ryan Schmidt
ryandesign at macports.org
Sun Apr 29 15:50:05 PDT 2012
On Apr 29, 2012, at 17:39, jeff at ayendesigns.com wrote:
> Well, let's back up a second. I installed mysql and mysql-server yesterday, and didn't make any manual changes, so should the my.cnf in the standard ports path (/opt/local/etc) only have 2 entries in it normally?
It's normal for /opt/local/etc/mysql5/my.cnf not to exist. MacPorts MySQL doesn't install it for you. If it exists, it's because you created it and put things into it. It can contain whatever you need or want in order to configure MySQL. As long as you do not set "socket=whatever" in a my.cnf file, it should use the default socket location I mentioned earlier.
/etc is another place where a my.cnf would be found.
More documentation at:
http://dev.mysql.com/doc/refman/5.1/en/option-files.html
> Is it a matter then of adding the path to the front of $PATH
$PATH has nothing to do with where MySQL looks for my.cnf or where it puts the socket file.
> or renaming the other instances to .old?
If you find other my.cnf files on your drive and you don't wish for them to be used, you can delete them or rename them as you like.
On Apr 29, 2012, at 17:21, jeff at ayendesigns.com wrote:
> I also see a my.cnf at
> /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports/databases/mysql4/files/my.cnf
This is part of the mysql4 port definition. It will not interfere with MySQL or be used by MySQL from this location. You should not delete any files in /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports because they are needed by MacPorts and anyway they'll be replaced next time you sync or selfupdate.
> /usr/local/mysql-5.5.15-osx10.6-x86_64/mysql-test/suite/federated/my.cnf
> /usr/local/mysql-5.5.15-osx10.6-x86_64/mysql-test/suite/rpl/my.cnf
These are part of a MySQL installation you installed in /usr/local. These probably also won't interfere with MacPorts MySQL. However you should remove this copy of MySQL. Although installing MySQL in /usr/local/mysql-* shouldn't be a problem for MacPorts, users frequently report problems with other software installed in /usr/local, therefore I recommend you do not install anything in /usr/local when you already use MacPorts.
If you want MySQL 5.5 instead of 5.1, use the mysql55 port.
More information about the macports-users
mailing list