WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] How to reset blog_IDs being issued (4 posts)

  1. amurderofcrows
    Member
    Posted 3 years ago #

    Hey all

    I was working on the site last night, and i have 4 or 5 blogs i need reserved. i had wanted them all under the blog_IDs of 1-5 for ease of finding them in the super admin panel, and for my own OCD.

    This morning i found that someone had registered blog_id 2, setting up a spam site because i forgot to lock up.

    I've dropped their site and went through the database to try to find references to the blog ID, and after i went back and tried to set up the reserved blogs i wanted, however they are all off by 1 number in the blog id....i can't get any of them to get set up as blog 2 anymore.

    i've since removed all blogs except for the main install.

    does anyone know how i can go about resetting WPMU so that it appears as if there has never been any other blogs set up besides the first?

    thank you!

  2. James Collins
    Member
    Posted 3 years ago #

    You need to alter the wp_blogs table in the MySQL database that your WPMU install is running on, and reset the AUTO_INCREMENT counter back down to 2.

    ALTER TABLE wp_blogs AUTO_INCREMENT=2

    Before doing that though I'd take a look at the rows in the wp_blogs table to make sure there is only one row (id 1).

    Ref: http://dev.mysql.com/doc/refman/5.1/en/alter-table.html

  3. Of note, there's no real need to do that. WordPress adapts to the numbers nicely. In some cases, it's best to let your OCD trust the software, because if you screw it up, it's he'll to fix.

  4. amurderofcrows
    Member
    Posted 3 years ago #

    thank you james, you saved my sanity!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.