Jump to content

Archived

This topic is now archived and is closed to further replies.

Nylex

Problems starting MySQL

Recommended Posts

I\'ve installed MySQL from source (version 4.0.12 and I\'m using Red Hat 8.0). Am I supposed to start MySQL using ./mysql user=mysql (or root)? I get command not found errors if I just try # mysql or # mysqld. When I do use ./mysql ..., it gives the following error message: ERROR 2002: Can\'t connect to local MySQL server through socket \'/tmp/mysql.sock\' (2)

 

Can anyone help? Thanks.

Share this post


Link to post
Share on other sites

as root run ./mysqladmin ping and make sure it\'s running.

Share this post


Link to post
Share on other sites

It came up with the same error when I tried ./mysqladmin ping. I then did ./mysqld_safe --user=mysql and then ./mysqladmin again:

 

./mysqladmin: connect to server at \'localhost\' failed

error: \'Access denied for user: \'root@localhost\' (Using password: NO)\'

 

Thanks.

Share this post


Link to post
Share on other sites

good deal. now it\'s running. just use the -p switch and it will prompt you for a password. you should have set the root password on installation.

Share this post


Link to post
Share on other sites

I did set the password when I installed. Lol. Thanks a lot (again!).

Share this post


Link to post
Share on other sites

no problem. if you do not want to type -p everytime, open the mysql configuration file and under the heading for the binary, [mysql] for example, put a line under there that simply says \"password.\" now anytime you use mysql it will automatically prompt for a password. no switches needed.

Share this post


Link to post
Share on other sites

Cheers, I\'ll do that. Now my LAMP server is up and running!

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.