Page 1 of 1

Trouble connecting to MYsql database

Posted: Thu Jan 16, 2003 1:26 am
by MrCrap
I have a client that has a subdomain off my server it is jrrobotics.crappyhosting.com I am trying to install vbulletin for him. I keep getting an error such as this:

Warning: Unknown MySQL Server Host 'jrrobot_adam@jrrobotics.crappyhosting.com' (2) in /home/jrrobot/public_html/forums/upload/admin/db_mysql.php on line 40

Warning: MySQL Connection Failed: Unknown MySQL Server Host 'jrrobot_adam@jrrobotics.crappyhosting.com' (2) in /home/jrrobot/public_html/forums/upload/admin/db_mysql.php on line 40

Warning: mysql_select_db(): supplied argument is not a valid MySQL-Link resource in /home/jrrobot/public_html/forums/upload/admin/db_mysql.php on line 47

The database has failed to connect because you do not have permission to connect to the server. Please go back to the last step and ensure that you have entered all your login details correctly.


The config file looks like this:

// type of database running
// (only mysql is supported at the moment)
$dbservertype="mysql";

// hostname or ip of server
$servername="jrrobot_adam@jrrobotics.crappyhosting.com";

// username and password to log onto db server
$dbusername="jrrobot_adam";
$dbpassword="273821";

// name of database
$dbname="jrrobot_vbulletin";

// technical email address - any error messages will be emailed here
$technicalemail = "Munkaboo@comcast.net";

// use persistant connections to the database
// 0 = don't use
// 1 = use
$usepconnect = 0;

// which users are allowed to view the admin log
// separate each userid with a comma
$canviewadminlog = "1";

// which users are allowed to prune the admin log
// separate each userid with a comma
$canpruneadminlog = "";


What should the servername be? I have tried every combo I can think of localhost, localhost@ etc etc.. I have added just about every combo to the allowed hosts also.

Thanks for any assistance.

Posted: Thu Jan 16, 2003 10:59 am
by porcupine
Try replacing:

// hostname or ip of server
$servername="jrrobot_adam@jrrobotics.crappyhosting.com";


With:

// hostname or ip of server
$servername="localhost";

or

// hostname or ip of server
$servername="127.0.0.1";

(127.0.0.1 is the ip address for a loopback to your server, same with any windows box, etc.)

Posted: Thu Jan 16, 2003 1:36 pm
by MrCrap
It would have been working all this time if I would have remembered to add user to database button. I had assumed that once you created a user it was automatically added. Stupid thing is, I have made that mistake before. :oops:

Posted: Thu Jan 16, 2003 1:42 pm
by porcupine
that too helps :)