Migration or upgrade path

Created on 20 November 2023, 7 months ago
Updated 27 February 2024, 4 months ago

What is the status for a migration and or upgrade path? From D7->D10? Or from version 1 to vesion 2?

I recently did a D7->D9 migration, and I used Version V1 initially. I somehow got the message to appear in Version D1 under D9. It's been so long that I did this, I cannot remember how I did it... Potentially I just copied the DB tables over back then. At any rate, the data did show up.

I then did a D10 upgrade, and as part of this V2 was installed, and nothing worked any more. I reverted back to V1, and getting the message.

Is there at least an upgrade path in the works for V1 -> V2?

πŸ“Œ Task
Status

Active

Version

2.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @hoporr
  • As a test, I did this and it worked:

    1) re-exported all pm tables out of the D7 site.
    2) re-imported them into the d10 site, with module version 1.0.0-alpha4

    Data comes up.

    So here seems to be a way to get at least the old messages into a D10 site? (with version 1.0.0)

    What is missing then is an upgrade path from 1.0.0 to 2.0.0, as the DB tables have changed.

    If that is true, this may be easier than a full migration, but maybe a hook_n_update that recasts the data to the new structure?

  • ivnish Poland

    Useful information:

    Version 1.0 was this is quick and dirty port to D9+. It use the same tables and data as D7 and there is no migration. Just import privatemsg tables from D7 DB to new DB

    Version 2.0 was sponsored by anonymous client and this is powerful version with drupal entities. The migration from D7 to 2.0 version will be sponsored later. You can wait or sponsor this early

    Also, there is no migration from 1.0 to 2.0

    I don't recommend to use 1.0 version. This is dead end version

  • In our case, I just needed the data in the system for now with a minimal running private message system, so waiting for a migration was not an option. Going to V1 was then a way to move forward, instead of having privatemsg be a stopper for the D10 version.

    I could see others to be in the same situation, so I would briefly suggest:

    Short of a full migration, the path from D7 to D10 would be:
    1) install V1 + DB tables (so you have at least the data plus a minimal system),
    2) upgrade to V2 -- that part is missing, but writing an upgrade from V1 to V2 may be easier then a full migration, because you can work within the same D10 system.

    However that path allows you to at least get the data over now.

  • ivnish Poland

    Migration from 1.x to 2.x howto:

    1. Backup your database!

    2. Upgrade privatemsg to 1.0.0-alpha5

    3. Run drush updb / update.php

    4. Open your database with PhpMyAdmin/Adminer/etc and check new tables pm_index_old and pm_message_old with your messages data

    5. Uninstall privatemsg 1.x module

    6. Install privatemsg 2.x module

    7. Run drush pmsg1to2

    8. Check your imported messages

    9. If they ok, remove tables pm_index_old and pm_message_old from database

    If you have problems, open new issue with problem details

  • ivnish Poland

    Migration from Drupal 6 (6.x-1.5) to 2.x howto:

    1. Backup your database!

    2. Enable submodule privatemsg_migration_d6

    3. Run users migration drush migrate-import d6_user

    4. Run drush migrate-import d6_privatemsg_email_notify

    4. If you need info about blocked users run drush migrate-import d6_privatemsg_blocked (optional)

    5. Run drush migrate-import d6_privatemsg_message

    6. Run drush migrate-import d6_privatemsg_thread

    7. Check messages in the new site

    If you have problems, open new issue with problem details

  • ivnish Poland

    Migration from Drupal 6 (6.x-2.x) to 2.x howto:

    1. Backup your database!

    2. Enable submodule privatemsg_migration_d6_2

    3. Run users migration drush migrate-import d6_user

    4. Run drush migrate-import d6_privatemsg_email_notify

    4. If you need info about blocked users run drush migrate-import d6_privatemsg_blocked (optional)

    5. Run drush migrate-import d6_privatemsg_message

    6. Run drush migrate-import d6_privatemsg_thread

    7. If you has file attachments to messages you need to open privatemsg_migration_d6_2/src/Plugin/migrate/destination/PrivatemsgAttachments.php and change "field_attachments" to your new field name for message attachments

    8. Run drush migrate-import d6_file

    9. Run drush migrate-import d6_privatemsg_attachments

    10. Check messages in the new site

    If you have problems, open new issue with problem details

  • ivnish Poland

    Migration from Drupal 7 (7.x-1.4) to 2.x howto:

    1. Backup your database!

    2. Enable submodule privatemsg_migration_d7

    3. Run users migration drush migrate-import d7_user

    4. Run drush migrate-import d7_privatemsg_email_notify

    4. If you need info about blocked users run drush migrate-import d7_privatemsg_blocked (optional)

    5. Run drush migrate-import d7_privatemsg_message

    6. Run drush migrate-import d7_privatemsg_thread

    7. Check messages in the new site

    If you have problems, open new issue with problem details

Production build 0.69.0 2024