Snap revert from 3.4.0-rc1 to 3.3.4 fails with database error on startup

Bug #2039687 reported by Jeff Lane 
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Triaged
Undecided
Unassigned

Bug Description

Because of https://bugs.launchpad.net/maas/+bug/2039614, I tried reverting our MAAS snap from 3.4.0 to 3.3.4 using `snap revert maas` this morning hoping that would restore our MAAS environment to it's last working state.

Unfortunately, there appear to have been DB changes that make 3.3.4 incompatible with the DB structure in 3.4.0. This resulted in an unusable MAAS (I am unable to log in via web UI nor command line as the api server is dead).

So `snap revert` broke maas and as it isn't able to do backwards DB updates. I'm not sure the right way to address this, perhaps simply warn and not allow reverts of MAAS (and warn on updating that it isn't possible to revert)?

More properly, I had expected/hoped that updating the snap from 3.3.4 to 3.4.0 would create a backup of hte DB from 3.3.4 in case a revert was necessary, which hopefully the revert would then just reload the 3.3.4 version of the DB. Admittedly there's a potential for data loss there too if you've added machines or made changes post update, but the loss would be, IMO, far less than this case where it's simply impossible to roll back to a known working condition.

I've attached regiond showing the tracebacks from when MAAS tries to restart.

Bumping this back to 3.4.0 resolved the issue and I can get into MAAS both via web and CLI again.

Revision history for this message
Jeff Lane  (bladernr) wrote :
Changed in maas:
status: New → Triaged
Jeff Lane  (bladernr)
description: updated
Jeff Lane  (bladernr)
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.