On Monday 16 July 2001 15:03, Kalpesh Modha wrote:
> Hello.
>
> I am trying to get mysql working on RedHat 7.1 and it works fine however,
> when I try to make a local connection from either Java or PHP.  I get a
> connection refused message.  Whats missing ?
>
> Thanks for your help in advance.
You need to grant the user you are connecting as the appropriate rights from 
the appropriate host. The jdbc driver uses the default mysql port when 
connecting(check that mysql are listening to the default port), and if you 
also connect from the same machine as you run the server, the client will be 
connecting from 'localhost', or the hostname of your computer, the stacktrace 
from your javaprogram, or a mysql logfile should tell you which host. So you 
need to grant the user in question the  right to connect to the server from 
'localhost'. MySQL manual will tell you how to fo that.

-- 
Nils O. Selåsdal

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to