# General Mongo update assistance

**URL:** <https://forums.rocket.chat/t/general-mongo-update-assistance/13714>\
**Category:** Community Support\
**Created:** [March 30, 2022, 8:09pm UTC](https://forums.rocket.chat/t/general-mongo-update-assistance/13714 "2022-03-30T20:09:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Roy.Hess](https://avatars.discourse-cdn.com/v4/letter/r/a5b964/32.png) [@Roy.Hess](https://forums.rocket.chat/u/Roy.Hess)\
**Post date:** [March 30, 2022, 8:09pm UTC](https://forums.rocket.chat/t/general-mongo-update-assistance/13714/1 "2022-03-30T20:09:00Z")

</div>

### Description

Currently my RocketChat 4.5.1 is still running on MongoDB 4.2.17 wiredTiger, but the feature compatibility version says its 4.0.  
Rocket Chat says MongoDB version 4.0.27 is deprecated, please upgrade your installation.

**My general question is:**  
Can’t I just dump the “parties” database…  
(I have a local: 14GB and a parties: 9GB (the actual Rocket Chat data it seems, I dont know what that local is supposed to be…))  
…and install mongo 5.x and import the dump?  
Would that work?  
Or should I just set the feature compatibility to 4.2 to postpone it for a bit?

### Server Setup Information

- Version of Rocket.Chat Server: 4.5.1
- Operating System: Ubuntu 18.x
- Deployment Method: snap
- Number of Running Instances: 1
- DB Replicaset Oplog: enabled
- NodeJS Version: 14.18.3
- MongoDB Version: 4.2.17
- Proxy: nginx
- Firewalls involved: iptables

---

<div class="post-metadata">

**Author:** ![dudanogueira](https://sea1.discourse-cdn.com/flex021/user_avatar/forums.rocket.chat/dudanogueira/32/2529_2.png) [@dudanogueira](https://forums.rocket.chat/u/dudanogueira)\
**Post date:** [March 30, 2022, 8:28pm UTC](https://forums.rocket.chat/t/general-mongo-update-assistance/13714/2 "2022-03-30T20:28:05Z")

</div>

Hi!

As this is more of a mongo topic please consider this information:

> **[Upgrade to the Latest Revision of MongoDB — MongoDB Manual](https://www.mongodb.com/docs/manual/tutorial/upgrade-revision/)**

Rocket.Chat will work with the following Mongo versions:

> **[Getting Support](https://docs.rocket.chat/getting-support#mongodb-versions)**
>
> Requirements for official support from the Rocket.Chat team

It should be ultimately a matter of dumping and restoring your data.

If your uploads are in GridFS that’s enough.  
Otherwise you should copy the upload folder you can set up in Rocket.Chat to the new server.

One suggestion is to always use **docker** instead of snap.

---

<div class="post-metadata">

**Author:** ![Roy.Hess](https://avatars.discourse-cdn.com/v4/letter/r/a5b964/32.png) [@Roy.Hess](https://forums.rocket.chat/u/Roy.Hess)\
**Post date:** [March 31, 2022, 4:56pm UTC](https://forums.rocket.chat/t/general-mongo-update-assistance/13714/3 "2022-03-31T16:56:26Z")

</div>

Thank you for the reply,  
I have tested porting my instance of RocketChat to a Docker container with actual useful results on two test machines.  
But Docker seems to add a whole bunch of IPTABLES rules to my ruleset which I dont really like.  
There’s already quite a ruleset on my server for certain services.

Why I’m asking here in the first place was; maybe RocketChat uses sole special database calls that might break if I just dump my DB, install MongoDB5.x and import the dump there.  
And people here might have an advise.  
I’ve had some bad memories with MongoDB and RocketChat in the past where the DB didnt come back up.

---

<div class="post-metadata">

**Author:** ![Roy.Hess](https://avatars.discourse-cdn.com/v4/letter/r/a5b964/32.png) [@Roy.Hess](https://forums.rocket.chat/u/Roy.Hess)\
**Post date:** [April 2, 2022, 2:40pm UTC](https://forums.rocket.chat/t/general-mongo-update-assistance/13714/4 "2022-04-02T14:40:40Z")

</div>

So I have tested dumping the current database,  
edited the default docker-compose.yml to have mongo:latest (instead of the suggested 4.0 that rocket.chat has in its official tutorial) and had to change from mmapi1 to wiredTiger.  
Other than toying around a bit it seems to have worked.  
Odd thing is it didn’t carry over my custom CSS scripts properly, my custom assets also didn’t carry over and I had to re-edit the “content” and so on under layout settings.

If anyone reads that in the future, it works.
