Jump to content

Recommended Posts

Posted (edited)

Hi everyone, I have my own webserver running at home, it is running the following:

 

a. IIS 6

b. PHP

c. MySql 5

 

IIS is working perfectly and so are the PHP scripts. I have recently installed the MySql 5 server and now im trying to install vBulleting but get this annoying message when i start the installation:

 

Step 2) Connect to the database

 

Attempting to attach to database

 

 

Warning: mysql_errno(): supplied argument is not a valid MySQL-Link resource in C:\Inetpub\Sites\forum\includes\db_mysql.php on line 140

 

The database has failed to connect because you do not have permission to connect to the server. Please confirm the values entered in the 'includes/config.php' file.

 

 

===================

Below I have also included my config.php file

 

 

/*-------------------------------------------------------*\

| ****** NOTE REGARDING THE VARIABLES IN THIS FILE ****** |

+---------------------------------------------------------+

| If you get any errors while attempting to connect to |

| MySQL, you will need to email your webhost because we |

| cannot tell you the correct values for the variables |

| in this file. |

\*-------------------------------------------------------*/

 

// ****** DATABASE SERVER NAME ******

// This is the hostname or IP address of the database server.

// It is in the format HOST:PORT. If no PORT is specified, 3306 is used.

// If you are unsure of what to put here, leave it at the default value.

$servername = 'localhost';

 

// ****** DATABASE USERNAME & PASSWORD ******

// This is the username and password you use to access MySQL.

// These must be obtained through your webhost.

$dbusername = 'myusername';

$dbpassword = 'mypassword';

 

// ****** DATABASE NAME ******

// This is the name of the database where your vBulletin will be located.

// This must be created by your webhost.

$dbname = 'db_forum';

 

// ****** TECHNICAL EMAIL ADDRESS ******

// If any database errors occur, they will be emailed to the address specified here.

// Leave this blank to not send any emails when there is a database error.

$technicalemail = 'paul@hotmail.com';

 

// ****** PERSISTENT CONNECTIONS ******

// This option allows you to turn persistent connections to MySQL on or off.

// The difference in performance is negligible for all but the largest boards.

// If you are unsure what this should be, leave it off.

// 0 = Off; 1 = On

$usepconnect = 0;

 

// ****** PATH TO ADMIN & MODERATOR CONTROL PANELS ******

// This setting allows you to change the name of the folders that the admin and

// moderator control panels reside in. You may wish to do this for security purposes.

// Please note that if you change the name of the directory here, you will still need

// to manually change the name of the directory on the server.

$admincpdir = 'admincp';

$modcpdir = 'modcp';

 

// ****** USERS WITH ADMIN LOG VIEWING PERMISSIONS ******

// The users specified here will be allowed to view the admin log in the control panel.

// Users must be specified by *ID number* here. To obtain a user's ID number,

// view their profile via the control panel. If this is a new installation, leave

// the first user created will have a user ID of 1. Seperate each userid with a comma.

$canviewadminlog = '1';

 

// ****** USERS WITH ADMIN LOG PRUNING PERMISSIONS ******

// The users specified here will be allowed to remove ("prune") entries from the admin

// log. See the above entry for more information on the format.

$canpruneadminlog = '1';

 

// ****** USERS WITH QUERY RUNNING PERMISSIONS ******

// The users specified here will be allowed to run queries from the control panel.

// See the above entries for more information on the format.

// Please note that the ability to run queries is quite powerful. You may wish

// to remove all user IDs from this list for security reasons.

$canrunqueries = '';

 

// ****** UNDELETABLE / UNALTERABLE USERS ******

// The users specified here will not be deletable or alterable from the control panel by any users.

// To specify more than one user, separate userids with commas.

$undeletableusers = '';

 

// ****** SUPER ADMINISTRATORS ******

// The users specified below will have permission to access the administrator permissions

// page, which controls the permissions of other administrators

$superadministrators = '';

 

// Prefix that your vBulletin tables have in the database.

// For example: $tableprefix = 'vb3_';

$tableprefix = '';

 

// Prefix that all vBulletin cookies will have

// For example

$cookieprefix = 'bb';

 

===========================

I have also created this database by using these commands, so Im assuming my log on credentials are ok but still I get this error?

 

*************************************

mysql> create database db_forum;

 

Query OK, 1 row affected (0.02 sec)

 

mysql> GRANT ALL PRIVILEGES ON db_forum.* TO myusername@"%" IDENTIFIED BY 'mypassword' WITH GRANT OPTION;

**************************************

 

can anyone help?

Edited by Turbopb
Posted

Welcome to the forums. Since the db name is db_forum have you tried changing the username to db_username? I do not know your setup so I cannot say for sure if this will work but I did find the following on the vbulletin site;

 

1. One or more of the following is wrong in your config.php file:

$servername (except in rare cases, this should almost always be left as 'localhost' or '127.0.0.1')

$dbusername

$dbpassword

$dbname

 

If you are unsure of what the appropriate values are then you will need to ask your web host.

 

2. Or that this db user is not assigned to that database or does not have permission to access MySQL to create or access a database. You may need to first manually create the database and assign the db user to it. Since each web host is different, if you do not know how to do this then contact your web host for help.

 

I see that you created the database but did you add the user to the database?

Posted
Welcome to the forums. Since the db name is db_forum have you tried changing the username to db_username? I do not know your setup so I cannot say for sure if this will work but I did find the following on the vbulletin site;

I see that you created the database but did you add the user to the database?

 

 

Hi Thanks for the reply, tried that suggestion but still the same error... even suggested what vBulleting recommends but same error persists... any other ideas?

Posted
May not help, but you have a few improperly defined variables, like

$canrunqueries = '';

only one quote

should be

$canrunqueries = ''";

 

Hello and Thank you for the reply, I tried taht and same issue.. you see so far I have tried the "root" username with the password that I use to access MySql dos console, I have also tried the user and password that I have set up for the db_forum database and still the same error... the strange thing is it works fine when I log on to the My Sql dos console but it will just not allow to connect because of that security issue... I doubt it has to do anything with the Active Directory that im running?

Posted
Hello everyone, i have opened the support ticket!

 

Question, since this is on your own machine, who did you open a ticket with? The VBulletin group? Let us know what happens.

Posted
Question, since this is on your own machine, who did you open a ticket with? The VBulletin group? Let us know what happens.

 

Hey guys I finally got it to work... took me two days to figure it out but it works like a charm now... I am fully hosting the vbulleting site from my own web server running IIS6 on 2003 server networked ofcourse :-)

I woult like to share the information with you guys so perhaps if you find it usefull you can maybe post it in a special place on your forums so that anyone else that experiences this problem can find it usefull...

 

Well here it goes...

 

As you probably know earlier I taught I set up everything righ which in fact I did but there was one problem...

 

By default I set up the following:

 

username: root

password: password

localhost: localhost

database: db_forum

 

I gave 'root' all the privileges to sign on to the MySql server from any computer as well as execute all the forum files etc.... so I specified the same log on credentials in the config.php file which is located in vbulleting/includes folder. It sounded like these credentials are right which in fact are right but still they would not work.

 

So I decided to create another user... I called it:

 

username: usern

password: passw

localhost: localhost

database: dbforum

 

so now I assigned this user all the privileges to the dbforum and everything worked fine...

 

I gues the default user 'root' should be only used to access MySql server, but for installing other scripts/applications you want to create a seperate user for that purpose... also keep an eye for your databases naming conventions... Inoticed that it likes it better when you don't use any of the following signs when naming your database... "-,/,&" etc... I simply called by database dbforum and the whole thing works fine.... I can personally answer some of anyone elses problems concerning this matter.. if Administrators of this forum don't mind you can email me or PM me and I will try to help in anyway that I can. Thanks

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...