Ad Widget

Collapse

Can not connect to remote database.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • NomenNescio
    Member
    • Jan 2009
    • 70

    #1

    Can not connect to remote database.

    Hi, I'm trying to connect to a remote database from the php installation but I keep getting the following error when I press on "test":

    Code:
        * mysql_pconnect() [<a href='function.mysql-pconnect'>function.mysql-pconnect</a>]: Can't connect to MySQL server on '192.168.205.1' (4)[/home/zabbix/web/include/db.inc.php:56]
        * Error connecting to database [Can't connect to MySQL server on '192.168.205.1' (4)]
    I am able to connect to localhost, but not the remote database.

    Edit:
    After a bit of trying I've found out that if I use the MySql servers IP address it doesn't work, but if I use it's DNS name it does connect and work. weird.

    Edit:

    It worked for a moment but now I'm getting this error:
    Code:
        * mysql_pconnect() [<a href='function.mysql-pconnect'>function.mysql-pconnect</a>]: Unknown MySQL server host 'rit-srv-05.beheer.RIT' (2)[/home/zabbix/web/include/db.inc.php:56]
        * Error connecting to database [Unknown MySQL server host 'server.mysql' (2)]
        * mysql_pconnect() [<a href='function.mysql-pconnect'>function.mysql-pconnect</a>]: Unknown MySQL server host 'rit-srv-05.beheer.RIT' (2)[/home/zabbix/web/include/db.inc.php:56]
    Edit:

    I found out that we had some kind of DNS error, but we fixed it, it works correctly now, I think >.>
    Last edited by NomenNescio; 28-01-2009, 13:28.
Working...