#1481 closed enhancement (fixed)
[patch] Using alternate MySQL unix socket
Description ¶
Hi,
Attached a patch which allows an alternate UNIX socket to be used for MySQL. The default is /tmp/mysql.sock, but this is mostly changed to a path like /var/run/mysql or /var/lib/mysql in production.
I have made it so that when DATABASE_HOST starts with a '/' it is a socket, otherwise it's a HOST. This might not work on Windows, but heck, who's using namedpipes anyway :)
Cheers,
Geert
Change History (4)
by , 19 years ago
Attachment: | mysql_base_unixsocket.diff added |
---|
comment:1 by , 19 years ago
I found this patch very useful in some cases. I'm getting trouble using shared hosting with dedicated database where connections to MySQL db are establised via non standard socket like "/home/username/tmp/mysql-socket"
comment:2 by , 19 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Using alternate UNIX Socket for MySQL