How to use a shared database from other server

my database in in another server,
my website in Dreamhost, i want it run that database, but i could not
help me please
i tried, for example:
$mysql_database = “visstre”;
$mysql_username = “visstre”;
$mysql_password = “***”;
$mysql_host = “”; ( that from other server)
but website do not run because it look for a database in Dreamhost,

mysql_connect() [function.mysql-connect]: Access denied for user ‘visstre’@‘’ (using password: YES) in /home/.julio/blogtre/ on line 7

@‘’ that seem be my problem now
anyone help me ??
ofcouse that database is ready set up for sharing to my domain in Dreamhost is denying you access. The isn’t the problem.

Make sure that is really a database server.

Make sure that allows visstre to connect from the IP address of squirt (


also dont post here REAL login/pass or some user can hack your BD

BUGabundo :o)
50$ discount with promo code “BUG50” on ALL plans

Are you sure that $mysql_host = ""; ( that from other server) gives enough information? That’s a tld so you couldn’t have any websites or anything else on that domain if the preceeding line is complete.

I had to use the fully qualified database host name, e.g.: define ('DB_HOST', '');

Scott- actually, I don’t think this problem is on the remote server’s side but inside DH. trungtamtuvan, did you ever solve this and if so how?

I am trying to get pages at DH to access a MySQL server hosted at ISP2. From my home web server/dev box the exact same pages as at DH can do this. The mysql user at ISP2 is wild-carded to allow access from any IP address. From within the DH world, however, I get the same error as trungtamtuvan:

Access denied for user ‘username’@‘’ to database ‘otherDBname’

the phrasing of the error message further makes me think this is a DH environment problem- I see no reason why the ‘’ should be entering that error message. If it said it could not connect to ‘username’@‘’ then I would agree it is ISP2, but this smells like a DH issue/policy.

has anyone successfully connected to an outside, remote mysql database from a page hosted in dreamhost?