• Ever since I moved my blog to another host (Dreamhost) last summer, I’ve been having strange little issues that I’ve posted about before, but found no real answers. Things like always getting a “Saving post . . .” message in the edit screen (the post does get auto-saved, but the message gets stuck), unable to get to some plugin settings screens (insufficient permissions), and — this is new — inability to upgrade WP automatically. And a few other things, none of which are, on their own, catastrophic, but together are a pain.

    To try to solve this, I’ve tried turning off and deleting all plugins, refreshing all the WP files, switching to the default theme, etc. After doing some research, I really think it’s the database that’s to blame. I thought it had something to do with prefixes, but they all seem to be fine (although I once used a security plugin on the install at the old host that I think did something with prefixes, but like I said, all of them seem to properly have the wp_ prefix).

    So now, I think it’s time to just go with a fresh database. Can anyone point me to some step-by-step instructions on how to do this without resorting to a completely fresh install?

    Thanks

Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter mrmonster

    (@mrmonster)

    Would emptying the tables of data and then running an import of the XML export file work?

    It should do.

    Thread Starter mrmonster

    (@mrmonster)

    Ok, so my next question would be, how would I do the import? If I’ve cleared data out of the DB, I’m assuming I won’t be able to access the admin area.

    Export the data first, clear the tables out of the db, re-run wp-admin/install.php and then import the .xml file.

    Thread Starter mrmonster

    (@mrmonster)

    Awesome, thanks. I’ll give it a shot tonight.

    Thread Starter mrmonster

    (@mrmonster)

    It sort of worked. I deleted all the WP core tables and then ran the reinstall, and imported the XML file. All my settings, widget configurations, etc, were gone. I had mistakenly thought that the file contained settings, which it didn’t, so I had to comb through the settings section and try to remember what I had set the options to. But that’s not a big deal. Unfortunately, except for solving the failed auto-upgrade issue (which I’m psyched about), I’m still having that weird stuck message in post edit: “Saving draft . . .” Luckily, it’s not a big issue, just strange.

    For future reference, is there any way to export settings (in addition to the post data) in case one wants to do a database rebuild?

    Thanks for your help!

    The only way to do that is to import an .sql backup into the new db. The problem there is, if you setting up a new db because of problems with the old one, you may just be copying the issues across to the new db.

    Thread Starter mrmonster

    (@mrmonster)

    So true. I didn’t do it that way because I was worried about. But I also didn’t actually delete all the tables, just the core WP ones. I kept some of the third-party plug-in tables in order to keep some of the settings — which actually didn’t work. The fact that my install is _still_ showing problems is making me think the problems lie with those tables. I think I need to delete _all_ the tables and try it again.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Need help to rebuild database’ is closed to new replies.