Page 1 of 1

remote connection

Posted: Wed Sep 16, 2009 2:00 am
by harikrishnanair
hi,

I have PHP installed on Server1 and mySQL installed on Server2. I am not able to connect to mySQL on Server2 from a php script on Server1. Needed extension is enabled in php.ini (php_mysql.dll). Extension_dir = "c:\php5\ext" which is also set correctly.

Can someone suggest what else has to be done for this to happen?

Thanks

Re: remote connection

Posted: Wed Sep 16, 2009 2:42 am
by VladSun
1. Does MySQL listen to reachable-from-outside IPs - i.e. skip-networking option is disabled and it DOES NOT listen only on localhost (127.0.0.1)?

2. Check your server1/2 firewalls

3. Have you GRANTed the right permissions to the user - .i.e.
[sql]GRANT ALL ON my_database.* TO my_user@server_1_ip IDENTIFIED BY 'my_password'[/sql]