List:General Discussion« Previous MessageNext Message »
From:Jack Wang Date:September 28 1999 1:06am
Subject:Cannot connect to MySQL server
View as plain text  

I have read the old mail list, but did not find the answer.

I use jdbc driver to connect to mysql, my servlet (java)
is passed when I use "nobody/null" as the user name and password.

Now I change the mysql database's user table, set user "jack" password with
"jackpass", then reload the database, and in the servlet use "jack/jackpass"
as the user name and password.

I run the mysql as "mysqld" (note: I can not see safe_mysqld.exe in
for win32), the mysqld 's process ID is 5, its user is jack. I can use
mysql,mysqladmin with user name "jack" and password "jackpass' in command.

To my suprise, I can see the table which was created with "jack/jackpass"
any use name and password, simple "mysql testdatabase" and "select * from
mytable | go". This is one problem.

And the most important problem is that when I change the user name and
from "nobody/null" to "jack/jackpass", my servlet which uses
reports the following err:

"500 Internal Server Error
          ("This is used to test MySQL database" sent by me)
DriverManager:java.sql.SQLException: Cannot connect to MySQL server on
wangjun:3306. Is there a MySQL server running on the machine/port you are
trying to connect to? 1"

user table has a record

At last please ask where can I find the mysql.server script which is used to
start mysqld as another user?

Thanks in advances.


Cannot connect to MySQL serverJack Wang28 Sep
  • Cannot connect to MySQL serverJani Tolonen1 Oct