Fabrizio Vanzani

ecommerce development, magento and tech tips

Magento session migration between files and db

Here a script that helps to migrate session data from files to db and other way round.

Usage:

php script_session_migration.php <method> <mode> <dryrun|save> [session_id] 
methods: db2files, files2db 
modes: insert, replace, upsert (todo) 
Examples:
php script_session_migration.php db2files insert save  
php script_session_migration.php db2files insert dryrun  
php script_session_migration.php db2files insert save fefa51f32efe28770ba23401aa1769fd 
php script_session_migration.php files2db insert save  
php script_session_migration.php files2db replace dryrun  
php script_session_migration.php files2db insert save fefa51f32efe28770ba23401aa1769fd

Click here to download:

Tested on: magento 2.3


Posted

in

,

by

Tags:

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *