cancel
Showing results for 
Search instead for 
Did you mean: 

Restore magento2 store in defferent Server

   Did you know you can see the translated content as per your choice?

Translation is in progress. Please check again after few minutes.

Restore magento2 store in defferent Server

Hi,

I have an issue while restoring Magento2 backup in different server. Need help, very interesting use case.

 

Scenario:

I have installed Magento 2.3.3 in two different servers, created mystore store (with same store name) in both the servers.

For example:  https://www.server1/mystore

                       https://www.server2/mystore

I went to Server1/mystore/admin and created products and setup email address etc.

               Server2 left with base store, no additional steps conducted.

 

Now I ran backup from Server1.mystore using the below command

  # bin/magento setup:backup --code --db --media, which created three backup files.

     1586052300_filesystem_media.tgz,1586052300_filesystem_code.tgz,1586052300_db.sql

 

Transferred the above backup files from Server1 to the Server2. I logged into to the 2nd server and ran the below restore (rollback) command.

  # bin/magento setup:rollback -m 1586052300_filesystem_media.tgz -c            1586052300_filesystem_code.tgz -d 1586052300_db.sql

 

It succeeded in restoring filesystem and media. However it failed while restoring db. It is throwing below error:

In Serialize.php line 33:Unable to unserialize value.

 

My question:  Does the above scenario work?  If yes what am I missing. Many thanks in advance.

 

1 REPLY 1

Re: Restore magento2 store in defferent Server

I had the same isssue and found out it is because I didn't set the crypt key.