Announcement

Collapse
No announcement yet.

My Sql Issue?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • My Sql Issue?

    Install a fresh copy of my vbulletin v. 3.0.0

    I created the database on my webhost and configure the config.php file to reflect the correct database, username and password. Yet when I run the installation. I get the following error on STEP 2.

    Warning: mysql_errno(): supplied argument is not a valid MySQL-Link resource in /home/www/rotochat/forums/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.

    My Config.php file looks like this?


    // ****** 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 = '****';
    $dbpassword = '****';
    // ****** DATABASE NAME ******
    // This is the name of the database where your vBulletin will be located.
    // This must be created by your webhost.
    $dbname = '*****';

    Any ideas what i'm doing wrong?

    -candidog

  • #2
    Note: I removed your db user name and password for your own security.

    If the db info is correct, then this means that db user does not have permission to access that database. You need to assign the user to this db.
    Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
    Change CKEditor Colors to Match Style (for 4.1.4 and above)

    Steve Machol Photography


    Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


    Comment


    • #3
      Install a fresh copy of my vbulletin v. 3.0.0

      I also am receiving this following error on STEP 2:

      Warning: mysql_errno(): supplied argument is not a valid MySQL-Link resource in /home/www/rotochat/forums/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.

      My Config.php file looks like this?


      // ****** 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 = '****';
      $dbpassword = '****';
      // ****** DATABASE NAME ******
      // This is the name of the database where your vBulletin will be located.
      // This must be created by your webhost.
      $dbname = '*****';


      The permission is already set:

      wwwhunt_forums
      Users in forums
      wwwhunt_USER (Privileges: ALL PRIVILEGES)

      Connection Strings
      Perl $dbh = DBI->connect("DBI:mysql:wwwhunt_forums:localhost","wwwhunt_USER","<PASSWORD HERE>");
      PHP $dbh=mysql_connect ("localhost", "wwwhunt_USER", "<PASSWORD HERE>") or die ('I cannot connect to the database because: ' . mysql_error());
      mysql_select_db ("wwwhunt_forums");

      Any ideas what i'm doing wrong?

      Thanks
      Becky

      Comment


      • #4
        The database has failed to connect because you do not have permission to connect to the server. According to part of the error you dont have access to that server.

        If your using cpanel you need to assign this user to the database.

        Comment


        • #5
          I guess I am confused then because according to this screen in cPanel the permission has been set.

          MySQL Account Maintenance


          Databases: wwwhunt_
          Users in
          wwwhunt_becky (Privileges: ALL PRIVILEGES)

          Connection Strings
          Perl $dbh = DBI->connect("DBI:mysql:wwwhunt_:localhost","wwwhunt_becky","<PASSWORD HERE>");
          PHP $dbh=mysql_connect ("localhost", "wwwhunt_becky", "<PASSWORD HERE>") or die ('I cannot connect to the database because: ' . mysql_error());
          mysql_select_db ("wwwhunt_");

          Comment


          • #6
            config info

            // ****** 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 = '*****';
            $dbpassword = '*****';

            // ****** DATABASE NAME ******
            // This is the name of the database where your vBulletin will be located.
            // This must be created by your webhost.
            $dbname = 'wwwhunt_';

            Comment


            • #7
              You need to prefix your database username with your cpanel login name

              your login looks like wwwhunt_

              so all users should be

              wwwhunt_USERNAME



              You should make a database with a name though not just wwwhunt_

              Comment


              • #8
                I have tried wwwhunt_USERNAME serveral times (I saw that in the instruction manual) But that won't work either - still getting error

                Comment


                • #9
                  are you sure your database name is just wwwhunt_ ?

                  Comment


                  • #10
                    Finally got it - had to delete the database and recreate

                    Comment


                    • #11
                      I'm having the same problem.

                      Users in tidewaterracing
                      harea_test (Privileges: ALL PRIVILEGES)

                      Connection StringsPerl$dbh = DBI->connect("DBI:mysql:harea_tidewaterracing:localhost","harea_test","<PASSWORD HERE>");PHP$dbh=mysql_connect ("localhost", "harea_test", "<PASSWORD HERE>") or die ('I cannot connect to the database because: ' . mysql_error());

                      mysql_select_db ("harea_tidewaterracing");
                      I don't understand why I can't connect. I have the correct info in the config.php file.
                      Last edited by Cary; Tue 18th May '04, 8:57pm. Reason: Removed an image so a cpanel login box would stop popping up

                      http://members.cox.net/al.hare/mysupra29.jpg

                      Comment


                      • #12
                        94SupraTT, please start your own threrd with all the relevant details including error messages.
                        Steve Machol, former vBulletin Customer Support Manager (and NOT retired!)
                        Change CKEditor Colors to Match Style (for 4.1.4 and above)

                        Steve Machol Photography


                        Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.


                        Comment

                        widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                        Working...
                        X