Have you ever connected to MySQL from the local machine?  Sounds like a
permissions problem, because it appears to be successfully creating the
socket.  Your user may not be set up to access it from localhost, perhaps
just the remote machine.  Log in to MySQL as admin/root and execute the
following query:

GRANT ALL PRIVILEGES ON 'database' TO 'username@localhost' IDENTIFIED BY
'password';

Obviously, substitute database, username and password with your specific
values.  That query will allow the particular user/pass combo to access
MySQL from the local machine.

Mike Frazer


"Greg Conway" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hi Steve,
>
> Thanks. I have tried this (the line was not there), but still I have my
> original problem. I am now suspecting it is more than a PHP problem, as I
> have the same problem with Zope (where I have PHP installed :) but I don't
> think the MySQL connector is reliant on it....!), namely:
>
> Error
> MySQL said:
>
> MySQL Connection Failed: Can't connect to local MySQL server through
socket
> '/tmp/mysql.sock' (111)
>
> So I think it's something wrong with the MySQL somewhere... despite the
fact
> that MySQL is running okay! I have Db Tools querying the Db okay from
> outside the machine!!
>
> Anyway, thanks for the tip.
>
> Regards,
>
> Greg.
>
> > -----Original Message-----
> > From: Steve Werby [mailto:[EMAIL PROTECTED]]
> > Sent: 30 January 2002 22:41
> > To: Greg Conway; Php-General
> > Subject: Re: [PHP] MySQL-PHP-RAQ4 dilemma!
> >
> >
> > "Greg Conway" <[EMAIL PROTECTED]> wrote:
> > > I'm trying to add MySQL to my RaQ4. It came
> > > by default with PHP4 but no MySQL.
> >
> > I'd have to check a clean RaQ4 to be sure, but I thought MySQL
> > was installed
> > by default, but it was setup as a loadable module in PHP and was
commented
> > out by default.  Please check for the file mysql.so on your
> > server.  If it's
> > there, you're PHP has MySQL support compiled, it just needs to be
> > turned on.
> > Try checking for /usr/lib/apache/php/mysql.so or in case it's in
> > a different
> > location try "locate mysql.so".  If you find it, try this.
> >
> > 1. Edit /etc/httpd/php.ini and add the following at the bottom:
> >
> > extension=mysql.so
> >
> > If it's there, but has a ";" in front, remove the ";" as that's a
comment
> > character.
> >
> > 2. Restart Apache.
> >
> > /etc/rc.d/init.d/httpd restart
> >
> > --
> > Steve Werby
> > President, Befriend Internet Services LLC
> > http://www.befriend.com/
> >
>
> ***********************************************************************
> This is a confidential communication between sender and addressee. If you
are not the intended recipient of this message, please notify the sender and
do not read, copy, use or disclose this communication to others. Any
opinions or views expressed are those of the individual, and unless
otherwise stated, are not those of the company. All attachments and
intellectual rights remain the property of GML (NT) Limited.
> ***********************************************************************



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to