Snaps, Docker, Mongo, upgrades

Snaps and upgrades

OK so I don’t have to keep writing the SAME thing over and over.

First read this about snaps:

“Rocket.Chat provides no support for these additional deployment methods”

IOW Snaps are no longer supported and YMMV.

Next.

I don’t believe that snaps will AUTOMATICALLY upgrade the Mongo DB from 7 to 8 inside the snap.

IIRC I believe manual intervention is required but I do not have a snap to test with.

Check Mongo docs for ‘Feature compatibility’ and look for posts on upgrading Mongo 5/6 - 7 as similar issue arose.

However, you are far better off moving to docker.

Rough procedure to move.

  • Make sure you backup and restore to the SAME RocketChat VERSION, and only upgrade Rocket AFTER the restore
  • Do NOT try and backup say 7.13.x and restore to 8.5.x There are important db updates that will get skipped and you will likely break your install
  • So backup Rocket 7.13.x and restore to Rocket 7.13.x
  • Note the db in snaps has a different name (parties?) to the one in docker (rocketchat)
  • You MUST rename the DB. There are posts here and around on doing this
  • You CAN setup Mongo in docker as 8.x and import a 7.x database to it
  • Setup your compose file but ONLY start Mongo first. Do NOT start Rocket
  • Import the DB, check that it seems OK, and THEN start Rocket
  • Do NOT start Rocket UNTIL the DB is imported
  • After Rocket has started check everything is working BEFORE you try anything else
  • Be prepared to go back and try again

I also advise you use the docker compose files with .env as per github.

And last, never, EVER use ‘latest’ unless you like nasty surprises. Pick a version and use it specifically. Upgrade on your own timescale.

Personally I always have a separate test box running and upgrade that first…

PS check github for bugs. Check for both open AND closed ones.