upsforum

Well-Known Member
Jul 27, 2005
474
0
166
Hi,

I set a remote server additional mysql db,

I set IP remote server, I set password root of remote server and I try connect to this:


$db_host = "IPREMOTESERVER";
$db_user = "usernamerootserver";
$db_password = "passwordrootserver";
$db_name = "databasename";

But I get a error permission denied
 

madaboutlinux

Well-Known Member
Jan 24, 2005
1,051
2
168
Earth
You will have to replace the db username/password with the one you have created and assigned to the database. If you haven't assigned a user to the database, you can either do it from the control panel you have or you can do it from Mysql prompt using the below command:

GRANT ALL PRIVILEGES ON databse.* TO 'username'@'%' IDENTIFIED BY 'newpassword';

Also you will have to check whether the other server allows remote access to databases.