I'm usin ZC 1.3.8 and mysql 5.0.67. ZC wants to access it using
'MYSQL_UNIX_ADDR =/var/mysql/mysql.sock which is set in a c header file
mysql uses MYSQL_UNIX_ADDR = "/tmp/mysql.sock"
how do I configure php or ZC to use the correct file?
Printable View
I'm usin ZC 1.3.8 and mysql 5.0.67. ZC wants to access it using
'MYSQL_UNIX_ADDR =/var/mysql/mysql.sock which is set in a c header file
mysql uses MYSQL_UNIX_ADDR = "/tmp/mysql.sock"
how do I configure php or ZC to use the correct file?
Zen Cart doesn't explicity specify a socket to use for MySQL communications.
Instead, it relies on the PHP configuration (usually php.ini controlled by the server administrator) to handle that.
Assuming you've got PHP and MySQL and Apache installed and running properly on your Mac, then you would simply begin the Zen Cart install and specify the database name/user/password credentials when prompted. Zen Cart will use the Apache/PHP/MySQL configuration settings to do the database table setup etc.
yes, my issue is php relies on a c header file that is not editable without a compiling. Its permissions are read only. I can change the permissions and file, but I'm not a c programmer and am concerned that may hurt my php install
Since you posted in the section about Installing on a Mac, I suppose you'll need to contact Apple's Developer Network for instructions on reprogramming your operating system or recompiling. Did you ever suppose that perhaps the file is read-only for a very important reason? Sure seems like it to me.
Either that or find yourself a simpler way to install/configure your Apache/PHP/MySql support.
Personally I think you're making things WAY TOO complicated. Yours is the first I've heard of anyone having to do any editing to C header files.
You have several options:
a) continue on the path you're on ... which is entirely illogical in my opinion
b) surf the search engines for the proper way to configure Apple's built-in services and adding/configuring PHP/MySQL support.
c) install a prepackaged Apache/PHP/MySQL stack for the Mac, such as MAMP or XAMPP
d) skip installing on your Mac, and just install to a real webserver ... since that's where you're going to run your site anyway ... Using a live server is far more straightforward for people unfamiliar with configuring their own computer (Mac or PC) to pretend to be a webserver.
I recommend you try option (d). And, if that's not suitable for some reason, try (c).
If you choose (a), then this forum is not for you until you've got your Mac/programming/webserver/etc issues sorted out. After that, come back once you're able to use the webserver and start using Zen Cart.
Although DrByte is "da man" when it comes to serving up Zen Cart, it's at least possible that the OP was actually trying to use a Mac as a "real webserver". Mac OS X comes in two flavours, one for the usual personal computer uses and one -- called conveniently enough, Mac OS X Server -- for use as a server. It is a highly capable server -- in effect a BSD Unix box -- that has all the usual capabilities of such machines.
The OP didn't say what he was using and may even have posted in the wrong forum, but assuming he is using a Mac, and even assuming he's using Mac OS X Server, his question remains worrisome. I have to go with the good Doctor's advise, which I'll paraphrase as... If you have to ask that question, you probably shouldn't be doing what you're doing.
Rob
changed in /etc/php.ini, in the section [MySQL] from:
mysql.default_socket = /var/mysql/mysql.sock
to
mysql.default_socket = /mysql/mysql.sock
then restarted apache
Thanks for the advice and responses. While I'm new to both Zencart and php, I'm not new to web computing (java and ruby) nor bsd unix so configuring mybox correctly was the best solution for me, now all my php work will access mysql correctle as my ruby does.