Problems merging existing phpbb board with drupal

Events happening in the community are now at Drupal community events on www.drupal.org.
Cross_and_Flame's picture

How do I go about merging an existing phpbb board with drupal?

The board is phpbb2. Here's what I tried so far

1) Following the instructions for a blank drupal 5.3 and a blank phpbb3 RC7 and it worked perfectly. My only confusion was with the drupal_sequences table...I assume it meant the users_uid to change to 1000, not add a new entry? Regardless, it worked perfectly with the new test users sharing the same login session. Neat!

2) Then I tried it with a base drupal 5.3 install with the users transferred over from phpbb2drupal and the phpbb2 forum upgraded to phpbb3 RC7.

3) I try to register a new user and it says "there has been an error. Please see the watchdog for the error" and there is no watchdog entry. I also cannot login with any established user on either board except the drupal superuser.

So, what is the method by which I can merge an established phpbb3 board with Drupal? Keep in mind I still have the phpbb2 data so I can phpbb2drupal it over if need be, but at what stage of the process should I do it?

I've got a planned site refresh in a few days, so any timely assistance would be greatly appreciated! Thanks in advance!

Comments

1) user_uid should be

arkepp's picture

1) user_uid should be incremented by 1000, not set to 1000 (if you have less than 900 users that's probably okay too) and not add a new entry. It really surprises me that said column is not set to be unique, but I have seen the same thing myself.

2) Are you talking about http://drupal.org/project/phpbb2drupal ? It's not maintained, and I don't think it works with anything newer than Drupal 4.6. Previously I have told to try to transfer users to 4.6 and then upgrade that installation to 5.3 (or sponsor a rewrite), never got any feedback whether that worked or not.

3) Not sure. Maybe because phpbb2drupal isnt written for 5.3 and writes the error message to the wrong place.

phpBB 2.x and Drupal use the same type of password hash. I would probably transfer (manually / SQL) every user with id greather than 3 from phpBB 2 to Drupal 5.3 by copying their information to Drupal, namely uid, password hash, username and email address. Then you have to add each of them to the authenticated group in Drupal, by inserting a row for each in the appropriate table. That would probably be enough to let them log in, but you should test that pretty carefully.

Then I would upgrade phpBB2 to phpBB3, and finally follow the steps of installing my module (pretending like you had all your users in Drupal 5.3, and that phpBB is empty).

Haven't tested this, but I pretty much did the same thing (dropped Drupals user table and repopulated it) when I upgraded my websites because I was merging three forums. Beware that phpBB's upgrade stuff will choke if you have duplicate usernames or usernames that become identical when you omit special and uppercase characters, something Drupal used to allow and still tolerates.

I would probably not bother with signatures, timezones and avatars if I was in a hurry. That's stuff you can fix later. Best of luck :)

followup questions

Cross_and_Flame's picture

Thank you, you have by far the best support of any modification on drupal. In my limited experience ;-)

Two questions

1) So I take it that the userids in both drupal and phpbb should match? User #371 should be the same person be it in phpbb or in drupal?
2) If so, then I should make sure all users are matched up in both drupal and phpbb before installing your mod and fast-forwarding the sequencing question?

I am using a self-modified version of phpbb2drupal that works under 4.7. I will submit it to that issue once I figure out how!

1) Yes, except for the

arkepp's picture

1) Yes, except for the superuser in Drupal and the search engines in phpBB.

2) Absolutely, otherwise people will be logged in as the wrong people and they'll overwrite the wrong user in Drupal if they update their profiles.

arkepp - you say user_id

archard-gdo's picture

arkepp - you say user_id should be INCREMENTED by 1000? That's not what I did, and that's not what it says to do on the phpBB3 module instruction page.

It says

Look at the table "drupal_sequences", update the row with name "drupal_users_uid"
to have id = 1000:
UPDATE databasename.drupal_sequences SET id = '1000' WHERE drupal_sequences.name = 'drupal_users_uid' LIMIT 1 ;

I executed that SQL code exactly like that, and my user ids increment by 1, starting at 1000. I think you should fix the instructions if it's not supposed to be like that. I have not had any problems yet though.

The instructions are only

arkepp's picture

The instructions are only for a fresh install, you'll lose signatures, avatars etc if you're starting with a full Drupal table anyway... and I think you may run into some issues with the first 50 users as well, because they overlap with phpBBs predefined search engines.

I'll look into it when I get a chance.

I updated the instruction

arkepp's picture

I updated the instruction with a warning. Thanks for pointing out the ambiguity... hopefully I'll soon find time to release a few updates, but I'm having to stay up working well past midnight already.

mm i did all those

demon326's picture

mm i did all those instructions with an existing install and i have no problems at all when users are logging in....,and arkepp take your time to release the next release there is no need to hurry i think

Quick! Help!

Cross_and_Flame's picture

Some help please...I successfully setup the installation in a subdomain. But when I moved it over to the main site (not a subdomain), my logins through the drupal system don't register in the phpbb system.

I moved it back to the subdomain, reset all the default.php and the phpbb settings to point to the right domain, flushed my cookies, and it still won't let me in.

Any ideas?

phpbb

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: