1

How do you update Magento2 version without any downtime of the website?

If updating from the command line, at point of di:compile, the website is down during this period.

If updating from Web Setup Component Manager, there is obviously downtime while store is put in maintenance mode.

Question is simple, is there a way to have no down time of the website when updating Magento2 version?

Same question I guess applied for any 3rd party extensions updated from Web Setup Component Manager or command line.

2

If you put magento into a directory and symlink your webroot to the magento pub folder. You can simply create another directory with the updated code and change the symlink almost atomically. Problem is the database as there might be changes to it too. So you need to clone the database and run the update on the cloned database that's not live. Then it would appear as if there was no downtime. But obviously in the time between cloning the database and updating it all data changes to the old database (like new orders) would get lost. So you can lower downtime but I'm not sure you can get rid of it.

  • Understood. Quite a complex technique I guess, and have experimented with order import on Magento1 and found it fiddly to do without error and missing data, so would imagine it's harder on Magento2.... I guess best solution is just let the maintenance mode take place and swallow the few minutes of downtime? Just wondered how big sites that use Magento2 get around this? Surely they don't have any downtime... – MagentoMac Dec 20 '17 at 14:32
  • If you separate website and shop you can minimize downtime of the website by just downing the shop and showing a note that the shop is down temporarily. I have no idea, if it's even possible, how to get Magento to update without any downtime. My feeling is without massive adaptions it's not possible. – steros Dec 20 '17 at 15:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.