Re: MySQL Error. Please Help!
| From: | Michael Dearman | Date: | Mon, 06 Nov 2000 16:03:47 +0000 |
| Subject: | Re: MySQL Error. Please Help! | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-4247@lists.php.net to get a copy of this message | ||
Hi Nicolas,
The more info the better.
What platform, etc.
Some of your code that is relevant would also help.
Are you sure that mysql is running? Do a ps aux and see if you can spot it.
If you don't already, stick error reporting stuff everywhere you can?
Have you got your file permissions correct?
Have you used the 'GRANT' command to grant privileges for that user.
Mike D.
Nicolas Raitman wrote:
>
> Hi to all ! I have the following mistake when I attempt to connect to mysql.
> I do the
> following:
>
> $host = "localhost";
> $user = "php";
> $pass = "php";
> $con = mysql_connect($host, $user, $pass);
>
> when I try to wacth the results on netscape I get the follwing message:
>
> Mysql Connection Failed. Cannot connect to local Mysql server trough socket
> /var/lib/mysql/mysql.sock
>
> As I recently installed mysql I thought that it could be a problem of not
> having the php user enabled, so I created a user php with password php and
> host localhost in the user table, is that ok? If not, how can I do to create
> a user to access certain databases??
>
> Thanks a lot,
> Nicolas
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net
> For additional commands, e-mail: php-db-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net