trying to remotely connect to mysql database wont work
I am trying to connect to a remote mysql database. I am using mac os x serve. This is the code that I use, and it wont connect..
mysql_connect("serverip", "username", "password") or die(mysql_error()); I get the error Access denied for user 'username'@'xserve.sun********** The problem is, on the xserve, it's saying username @ xserve it is not a user on xserve, its a user on our other database server... so it should be user@150.15.***.*** not xserve |
Is the MySQL server actually listening on a TCP-port on a network interface to the outside world?
IIRC MySQL by default only listens at loopback interface (localhost, 127.0.0.1) or a filesystem socket. |
you also need to ensure that the permissions are set up for the user to log in remotely, often it would be identified within the permissions systems as user@localhost
|
Quote:
Is your login credentials right? Also try tnsping xserve - does it resolve to the ip mentioned above? Linux |
I fixed it!! Thanks for all the reply's. I had to create a new user giving it permissions to connect to it's public ip.
|
All times are GMT -5. The time now is 03:44 PM. |