tokumx and mongodb are incompatible; you couldn't build a mixed replica-set because they had different storage engines and spoke different replication languages. But PSMDB seems to have closed this gap (with pluggable storage engines, at least, which can allow wiredTiger). Does this mean they can now also be mixed (i.e. have the differences in replication-language also been rectified?) I ask because I've got a very old tokumx system with important data on it and MUST bring it into a mongodb cluster, but there seems to be no simple way to do this. If I can migrate tokumx->PSMDB->mongodb, that would be fantastic! Any help would be appreciated!
1 Answers
I've got a very old tokumx system with important data on it and MUST bring it into a mongodb cluster, but there seems to be no simple way to do this.
TokuMX's replication protocol is not compatible with MongoDB or Percona servers, so migrating from TokuMX will unfortunately require dumping and restoring your data. Outside of replication, there are also some incompatible TokuMX index options to remove before restoring into MongoDB.
See Migrate from TokuMX to Percona Server for migration approaches & scripts to help with this.
If I can migrate tokumx->PSMDB->mongodb, that would be fantastic!
If your goal is to migrate to MongoDB Community or Enterprise edition, an intermediate migration via PSMDB will not provide any benefit. PSMDB uses replication code from the upstream MongoDB community server, but does not provide any special migration path from TokuMX.

- 63,885
- 14
- 149
- 175
-
Thanks for the answer, @Stennie. Are you saying that PSMDB can't be in the same replica-set as mongodb nodes? I was thinking that if I can at least get a tokumx node upgraded to PSMDB, I can then put that PSMDB node into a mixed replica-set with mongodb nodes, sync the mongodb nodes, and then offline the PSMDB node (and toss it). Are you saying that is not possible? – dakshang May 30 '17 at 19:35
-
@dakshang TokuMX's replication isn't compatible with either MongoDB or PSMDB, so the migration approach to *either* of those will be similar. If your ultimate goal is to migrate to MongoDB, PSMDB does not provide any shortcut so I would skip this step and use the TokuMX migration scripts to load your data directly into MongoDB (i.e. substitute MongoDB for PSMDB in the instructions). Assuming you have compatible server versions of MongoDB & PSMDB a mixed replica set is possible, but not helpful for what you are trying to achieve. – Stennie May 30 '17 at 22:11
-
Thx @Stennie . I think we are almost there. It seems we are not on the same page (I've read whitepapers and other documentation about all this already), so let me distill this down to a single yes/no question: Q: "Can a PSMDB node be part of a mixed PSMDB/MongoDB replica-set" (it looks like the answer is yes from the last comment you made) ? – dakshang Jun 05 '17 at 18:38
-
@dakshang That's exactly my last comment: "Assuming you have compatible server versions of MongoDB & PSMDB a mixed replica set is possible, but not helpful for what you are trying to achieve". – Stennie Jun 05 '17 at 19:36
-
Alright. If they can share a replica-set, then PSMDB *can* replicate to a MongoDB node, which means I can sync a MongoDB (SECONDARY) node from a PSMDB (PRIMARY) node. That is exactly what I needed, thx! : ) – dakshang Jun 06 '17 at 19:32
-
@dakshang In your original description you mentioned looking for a simpler way to migrate your TokuMX data into MongoDB. Skipping PSMDB and going directly to MongoDB is simpler than the unnecessary installation of PSMDB (i.e. "PSMDB is not helpful for your use case" ;-). – Stennie Jun 07 '17 at 23:22
-
Ahh. I see your point there. What I was unsure of was whether MongoDB would be able to understand a dump taken via the "mongodump" binary packaged with TokuMX. I guess that was the underlying question; I should have made that more clear from the beginning. Thx again! – dakshang Jun 09 '17 at 02:26
-
@dakshang As noted in my original answer, TokuMX has incompatible options that need to be fixed before importing into MongoDB. The [Migrate from TokuMX to Percona Server](https://www.percona.com/blog/2017/04/26/migrate-tokumx-percona-server-mongodb/) post I referenced includes two approaches to migration (offline & online). The [offline approach](https://github.com/Percona-Lab/tokumx2_to_psmdb3_migration/blob/master/HowToMigrate.md) uses `mongodump` and includes some scripts to save and recreate indexes without the TokuMX options (which will be the same process for either PSMDB or MongoDB). – Stennie Jun 09 '17 at 04:35