phpBB to bbPress Migration Process - Step 1, Remove Spam Users
We’ve been planning to move to bbPress for quite a while. phpBB is plagued with spam, both through spam user signups and to a lesser extent spam postings. Last time I checked there was no serious anti-spam plugins or modifications available, and the couple of hacky attempts to fix the problem were painful to implement and not particularly effecive.
So we’re now seriously on the path to a bbPress migration, there are some scripts around which will convert a phpBB database to bbPress, but our phpBB currently has 7486 registered users, and I’d say about 300 of those are real people. So before the migration, it’s time to remove the spam profiles.
Here’s a great start, it deletes all “members” who signed up over 48 hours ago and are inactive (haven’t clicked the confirmation link in their signup email).
The SQL looks like this:
[code lang="sql"]DELETE FROM phpbb_users WHERE user_active=0 AND user_id>0 AND FROM_UNIXTIME(user_regdate)
I’m confident enough in my SQL that I don’t need to search around for something to do this, just modify that last SQL command. “user_posts” is where the post count is contained, so here’s what should remove users which are activated but haven’t made any posts: [code lang="sql"]DELETE FROM phpbb_users WHERE user_posts=0 AND user_id>0 AND FROM_UNIXTIME(user_regdate)
An aside: The lovely code highlighting in this post was provided with the Code Snippet Wordpress plugin, which I installed because WP was misinterpreting my html <code> blocks.


3 Comments
Josh
You alluded to scripts to migrate from a phpBB to BBPress DB. Got any links to those? Did you complete this migration? How did it go? I’m about to embark on the same migration journey. Any tips or words of caution?
December 20, 2007 @ 11:46 am
jaymis
Hi Josh. Haven’t done so yet, but was hoping to do so over the next week or so. I didn’t save any in my links, but seem to recall I found a couple of different migration scripts with a small amount of googling.
… http://www.google.com/search?q=bbpress+phpbb+migration
Whoops. I guess we’ve actually become the top hit on Google for that
I was looking at this: http://bbpress.org/forums/topic/importing-from-phpbb
and this: http://bbpress.org/forums/topic/phpbb-gt-bbpress-gt-wordpress
But hadn’t made any more progress than that. If you end up running with them I’d love to hear how it goes. Otherwise I’ll be doing the migration and documenting it soon.
December 20, 2007 @ 11:11 pm
jaymis
… and in a funny quirk of the internet we’re having to turn off comments on this post because we’re getting too much spam and Akismet doesn’t seem to be stopping any of it.
January 30, 2008 @ 10:35 pm
Sorry, the comment form is closed at this time.
RSS feed for comments on this post. TrackBack URI