1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.4 vB 3.7.2 -> XF 1.4.5 Import Error (Table prefix)

Discussion in 'Installation, Upgrade, and Import Support' started by Static-Xbox, Mar 19, 2015.

  1. Static-Xbox

    Static-Xbox Active Member

    Hi,

    I'm trying to import a large forum from vB3.7.2 to XF 1.4.5, all of the credentials I have are correct, but there is no table prefix (verified through the database and by checking config.php). Yet when I validate the configuration of the database credentials I get the error:

    "The table prefix or database name is not correct."

    We are moving this forum from one server to a new server, but the credentials for the existing server are correct. I'm not the owner of the forum in question, but I'm doing the import in this case, and he has verified multiple times now that these are the correct credentials. Is there any other reason why this error would appear?

    Any help would be greatly appreciated!
     
  2. Mike

    Mike XenForo Developer Staff Member

    This often indicates that your copy of the database isn't complete and it doesn't have the expected tables. I believe we're checking for the "user" table.
     
  3. Static-Xbox

    Static-Xbox Active Member

    Thanks for the response, Mike!

    Could this be a result of pruning users and content periodically? It's a 15 year old forum that was being pruned at routine intervals due to hardware constraints (based on content ids, it has had over 8.6 million posts, but only 1.2 million are present in the database, and over 354,000 users, with only 134,000 still present today), just wondering if that could have caused this?
     
  4. Mike

    Mike XenForo Developer Staff Member

    No, it would only happen from the table we're checking for not being there (which usually means the prefix is wrong).
     
  5. Static-Xbox

    Static-Xbox Active Member

    Hi Mike,

    Just confirmed that the tables are present. From the owner of the site, the tables read as such:

    Your MySQL connection id is 174076 to server version: 4.0.17-standard

    Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

    mysql> use vbulletin;
    Reading table information for completion of table and column names
    You can turn off this feature to get a quicker startup with -A

    Database changed
    mysql> show tables;
    +----------------------------+
    | Tables_in_vbulletin |
    +----------------------------+
    | access |
    | adminhelp |
    | administrator |
    | adminlog |
    | adminmessage |
    | adminutil |
    | album |
    | albumpicture |
    | announcement |
    | announcementread |
    | attachment |
    | attachmentpermission |
    | attachmenttype |
    | attachmentviews |
    | avatar |
    | award |
    | award_cat |
    | award_user |
    | bbcode |
    | bookmarksite |
    | calendar |
    | calendarcustomfield |
    | calendarmoderator |
    | calendarpermission |
    | cpsession |
    | cron |
    | cronlog |
    | customavatar |
    | customprofilepic |
    | datastore |
    | deletionlog |
    | editlog |
    | event |
    | externalcache |
    | faq |
    | forum |
    | forumpermission |
    | forumprefixset |
    | forumread |
    | groupmessage |
    | groupmessage_hash |
    | holiday |
    | humanverify |
    | hvanswer |
    | hvquestion |
    | icon |
    | imagecategory |
    | imagecategorypermission |
    | infraction |
    | infractionban |
    | infractiongroup |
    | infractionlevel |
    | language |
    | mailqueue |
    | moderation |
    | moderator |
    | moderatorlog |
    | notice |
    | noticecriteria |
    | passwordhistory |
    | paymentapi |
    | paymentinfo |
    | paymenttransaction |
    | phrase |
    | phrasetype |
    | picture |
    | picturecomment |
    | picturecomment_hash |
    | plugin |
    | pm |
    | pmreceipt |
    | pmtext |
    | podcast |
    | podcastitem |
    | poll |
    | pollvote |
    | post |
    | postedithistory |
    | posthash |
    | postindex |
    | postindex_temp455282 |
    | postindex_temp461045 |
    | postindex_temp497188 |
    | postindex_temp509289 |
    | postindex_temp515837 |
    | postlog |
    | postparsed |
    | prefix |
    | prefixset |
    | product |
    | productcode |
    | productdependency |
    | profilefield |
    | profilefieldcategory |
    | profilevisitor |
    | proxycache |
    | ranks |
    | reminder |
    | reputation |
    | reputationlevel |
    | rssfeed |
    | rsslog |
    | search |
    | session |
    | setting |
    | settinggroup |
    | sigparsed |
    | sigpic |
    | smilie |
    | socialgroup |
    | socialgroupmember |
    | socialgrouppicture |
    | spamlog |
    | stats |
    | strikes |
    | style |
    | subscribeevent |
    | subscribeforum |
    | subscribethread |
    | subscription |
    | subscriptionlog |
    | subscriptionpermission |
    | tachyforumcounter |
    | tachyforumpost |
    | tachythreadcounter |
    | tachythreadpost |
    | tag |
    | taggregate_temp_1240181760 |
    | taggregate_temp_1240185360 |
    | taggregate_temp_1240188960 |
    | taggregate_temp_1240192560 |
    | taggregate_temp_1240196160 |
    | taggregate_temp_1240199760 |
    | taggregate_temp_1240203360 |
    | taggregate_temp_1240206960 |
    | taggregate_temp_1240210560 |
    | taggregate_temp_1240214160 |
    | taggregate_temp_1240217760 |
    | taggregate_temp_1240221360 |
    | taggregate_temp_1240224960 |
    | taggregate_temp_1240228560 |
    | taggregate_temp_1240232160 |
    | taggregate_temp_1240235760 |
    | taggregate_temp_1240239360 |
    | taggregate_temp_1240242960 |
    | taggregate_temp_1240246560 |
    | taggregate_temp_1240250160 |
    | taggregate_temp_1266494160 |
    | tagsearch |
    | tagthread |
    | template |
    | templatehistory |
    | thread |
    | threadrate |
    | threadread |
    | threadredirect |
    | threadviews |
    | upgradelog |
    | user |
    | useractivation |
    | userban |
    | userchangelog |
    | usercss |
    | usercsscache |
    | userfield |
    | usergroup |
    | usergroupleader |
    | usergrouprequest |
    | userlist |
    | usernote |
    | userpromotion |
    | usertextfield |
    | usertitle |
    | visitormessage |
    | visitormessage_hash |
    | word |
    +----------------------------+
    176 rows in set (0.00 sec)

    Also, the prefix is non-existent, there is no prefix set.
     
    Last edited: Mar 19, 2015
  6. Static-Xbox

    Static-Xbox Active Member

    The owner of the site has gone through to repair any errors found in the tables, with none turning up. At this point, I'm stumped.

    If it is indeed a prefix issue, with no prefix actually being set, is there a workaround?
     
  7. Mike

    Mike XenForo Developer Staff Member

    An empty prefix will be fine. We haven't had any reports of this before (except when expected).

    If you're sure the DB is complete, I can only suggest double checking the credentials are connecting to the DB/server you're expecting. Beyond that, code edits may need to be done to get the full error direct from the DB (XenForo_Importer_vBulletin, around line 140).
     
  8. Static-Xbox

    Static-Xbox Active Member

    Hi Mike,

    I'm definitely sure the DB is complete at this point, and the credentials are definitely correct. If I may ask, what exactly would I need to change in the vBulletin.php file in order to show the full errors?

    Thanks!
     
  9. Chris D

    Chris D XenForo Developer Staff Member

    At line 141, add the following:
    PHP:
    throw $e;
    The rest of the code in that block should now look like:
    PHP:
            catch (Zend_Db_Exception $e)
            {
                throw 
    $e;
                if (
    $config['db']['dbname'] === '')
                {
                    
    $errors[] = new XenForo_Phrase('please_enter_database_name');
                }
                else
                {
                    
    $errors[] = new XenForo_Phrase('table_prefix_or_database_name_is_not_correct');
                }
            }
    You should get the full error returned.
     
  10. Static-Xbox

    Static-Xbox Active Member

    Thanks, Chris!

    It's now giving the following error:

     
  11. Mike

    Mike XenForo Developer Staff Member

    This would appear to be some sort of communication error with the target server. Can you confirm the MySQL version on that server?
     
  12. Static-Xbox

    Static-Xbox Active Member

    It is quite dated, still running 4.0.17-standard.
     
  13. Brogan

    Brogan XenForo Moderator Staff Member

  14. Chris D

    Chris D XenForo Developer Staff Member

    I did see some references to that particular error and old MySQL versions, earlier.

    Ideally you're going to either need to upgrade MySQL or move the database off to a server that has a newer MySQL build.
     
  15. Static-Xbox

    Static-Xbox Active Member

    The server running XenForo is running the latest version of MariaDB

    Not sure if you can answer this or not, but is there an upgrade path from such an old version?
     
  16. Brogan

    Brogan XenForo Moderator Staff Member

    Are you trying to do an import between servers?

    The source and destination databases should really be on the same server.

    You just need the database and any avatar/attachment files (if they aren't stored in the database), so it't not necessary to actually install the software for the source forum.
     
  17. Static-Xbox

    Static-Xbox Active Member

    Yeah, we're moving from vB3.7 on an old server to XF1.4.5 on a new server.
     
  18. Brogan

    Brogan XenForo Moderator Staff Member

    Tack a backup of the VB forum.
    Create a new database instance on the new server and import the VB backup to it.
    Then copy any files as required (attachments, etc.) to a directory on the server.

    Then run the import.
     
    Static-Xbox likes this.
  19. Static-Xbox

    Static-Xbox Active Member

    Thanks Brogan, we'll give that a try!
     
  20. Mike

    Mike XenForo Developer Staff Member

    Yeah, that will be the problem. MySQL 4.1 added support for prepared statements and the protocol they use (which is what we use). The source database will need to be on a newer MySQL.
     

Share This Page