1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Restoring a massive database?

Discussion in 'MySQL' started by cpvr, Jan 27, 2006.

  1. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #21
    The rebuild search utility has an option to delete the tables if present and then recreate them and rebuild the search index. Do that.

    I assume you've completed the database import via BigDump by now?
     
    minstrel, Apr 16, 2006 IP
  2. RazorWing

    RazorWing Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #22
    Yes, using bigdump without the search tables works wonders, its just rebuilding the tables on the orginial database and login into the new site i am currently having problems with.
     
    RazorWing, Apr 16, 2006 IP
  3. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #23
    Can you login to your MySQL database via your site control panel?

    Assuming yes, drop all three search tables (they are the ones with "search" in the table name). Then run the rebuild utility.
     
    minstrel, Apr 16, 2006 IP
  4. RazorWing

    RazorWing Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #24
    Fasthost doesnt have any SQL features in the control panel, it only allows you to create new databases and new users. They do suggest accessing the database using MySQL Administrator Client. But i am no expert when it comes to databases.
     
    RazorWing, Apr 16, 2006 IP
  5. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #25
    That's what you want.

    You don't need to be an expert in MySQL to drop a couple of tables - just select the database, check the boxes next to the search tables you want to drop, and down at the bottom you should see a drop down box with options to delete and other things.

    That said, if you're nervous about it, you might want to get someone to do it for you. Do a current backup before dropping the tables so you can restore it if anything goes wrong.
     
    minstrel, Apr 16, 2006 IP
  6. RazorWing

    RazorWing Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #26
    I am currently dowing a phpBB full backup first, then i will do a MySQL administrator client backup as they seem to differ for some reason, then i will drop all three search tables and hopefully rebuild them. Once rebuilt i should be able to install the repaired database into my new site with bigdump without any problems. Fingers Crossed :)
     
    RazorWing, Apr 16, 2006 IP
  7. RazorWing

    RazorWing Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #27
    Search Tables are dropped, still same error:

    Could not obtain rebuild details

    DEBUG MODE

    SQL Error : 1146 Table 'EnB.phpbb_search_rebuild' doesn't exist

    SELECT * FROM phpbb_search_rebuild ORDER BY rebuild_session_id DESC LIMIT 1

    Line : 239
    File : functions_admin_rebuild_search.php
     
    RazorWing, Apr 16, 2006 IP
  8. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #28
    :confused:

    I thought you had already finished the BigDump import...

    If not, then do not rebuild the search indices until AFTER you have imported the database - you'll find that your phpBB database is considerably smaller without the search tables.
     
    minstrel, Apr 16, 2006 IP
  9. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #29
    :confused:

    You have to INSTALL the rebuild utility to your phpBb forum before you can use it. Did you do that? It's not a stand-alone utility. Once it's installed, you access it through your forum ACP.
     
    minstrel, Apr 16, 2006 IP
  10. RazorWing

    RazorWing Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #30
    Fasthost - I just dropped all my search tables from the orginial source
    One and One - When installing the backup database without search tables i am unable to login

    You see the problem i am having, i carnt rebuild the search tables within one and one as i carnt login to the control panel of phpBB for some reason.
     
    RazorWing, Apr 16, 2006 IP
  11. JRayers

    JRayers Well-Known Member

    Messages:
    528
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    110
    #31
    I had serious problems transferring my phpBB once. Stick with it, it will resolve in the end. I'll have a read through this thread in the morning properly and see if I can offer any advice from that experience.

    James
     
    JRayers, Apr 16, 2006 IP
  12. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #32
    Update: We determined the problem via instant messaging. RazorWing was trying to transfer a database from a phpBB 2.0.17 installation to a phpBB 2.0.20 installation - the later version has some additional tables and phpBB wasn't able to find them in the database.
     
    minstrel, Apr 16, 2006 IP
  13. RazorWing

    RazorWing Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #33
    Current Status

    New Site: 2.0.20
    Old Site: 2.0.20

    Current Problem
    Old Site: Wont Rebuild dropped search tables
    New Site: Wont Carnt Login at all

    Old Site: Backup of Database wont install into new site
     
    RazorWing, Apr 17, 2006 IP
  14. RazorWing

    RazorWing Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #34
    OK i fixed, the new site is almost up and running, but i need a bit of help on rebuilding the tables. On both the old and new site i am getting the same error message,

    DEBUG MODE

    SQL Error : 1146 Table 'db433435.phpbb_search_rebuild' doesn't exist

    SELECT * FROM phpbb_search_rebuild ORDER BY rebuild_session_id DESC LIMIT 1

    Line : 239
    File : functions_admin_rebuild_search.php

    I will provide a detail fix so if anyone gets a problem with phpBB and tranfering Database from one site to another they will be able to fix it and wont have to go through days and days of different attempts like i have just done.

    Your right minstrel, phpBB is a pain in the bumb and JRayers yeah you do get alot of problems with phpBB, but providing you dont do anything once its working, then your alright lol :p

    If someone could help me fix the problem above that would be the last hurdle. The topic about rebuilding the search table on the phpBB mod topic, doesnt tell you what exactly to edit, it tells you, you got to edit two files, but it doesnt tell you what in those two files has to be editted.

    So the current state of play on rebuilding the search tables is that i have copyed all rebuild search tables files to my new site and i can login to the new site and see the rebuild search mod installed. When executed i get the above message which might be because i havent editted any files.

    So if you can provide help i would be very greatful :)
     
    RazorWing, Apr 17, 2006 IP
  15. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #35
    RazorWing: Sent you an email. Reply to send me the files and I'll have a look.
     
    minstrel, Apr 17, 2006 IP
  16. RazorWing

    RazorWing Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #36
    Error in deleting post

    DEBUG MODE

    SQL Error : 1146 Table 'db161186838.phpbb_search_wordmatch' doesn't exist

    DELETE FROM phpbb_search_wordmatch WHERE post_id IN (2)

    Line : 419
    File : functions_search.php
     
    RazorWing, Apr 17, 2006 IP
  17. MrRyt

    MrRyt Peon

    Messages:
    3
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #37
    Hello guys

    I have to restore a 100MB database

    its .gz

    my question is should I have the current database dropped or emptied? and how could that be done through SSH?

    its a forum database

    plz help as I'm really lost (I have a dedicated so I have to rely on myself)

    thanks a lot
     
    MrRyt, Apr 27, 2006 IP
  18. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #38
    It depends on how you set up the export. Usually, you'll have the option of adding DROP before the CREATE statements. Double check as to how the SQL statements in the export file are created.

    Or, just empty the tables in the database and try to run the import. If you get errors saying, "TABLE exists", then drop them and run the import again.
     
    minstrel, Apr 27, 2006 IP
  19. MrRyt

    MrRyt Peon

    Messages:
    3
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #39
    would you please write the code for me.. including the unzip part and the path .. as I'm totally new in this and I desperately need to get this done the right way...

    thank you so much :(
     
    MrRyt, Apr 27, 2006 IP
  20. minstrel

    minstrel Illustrious Member

    Messages:
    15,082
    Likes Received:
    1,243
    Best Answers:
    0
    Trophy Points:
    480
    #40
    No. There's no way I can do that. The path will be different on different servers. I would suggest you find someone or hire someone to do it for you or contact tech support for your host.
     
    minstrel, Apr 27, 2006 IP