Upgrading from MongoDB 3.0 to 4.4

Hi,

I’m planning to upgrade my application from using MongoDB 3.0.6 to MongoDB 4.4.

The documentation states that:

To upgrade from a version earlier than the 4.2-series, you must successively upgrade major releases until you have upgraded to 4.2- series. For example, if you are running a 4.0-series, you must upgrade first to 4.2 before you can upgrade to 4.4.

This means that I need to upgrade from 3.0.6, to 3.2, 3.4, 3.6, 4.0, 4.2 and finally to 4.4

I’m wondering if dumping the database using mongodump, then updating directly to mongoDB 4.4, and finally restoring the database using mongorestore can work, and if there any disadvantages or complications we need to be aware of. Any ideas?

Thanks a lot!

Hi @Evan_L,

Successive in-place upgrades are the most thoroughly tested approach and will minimise downtime.

However, if downtime is acceptable (and you’re open to hitting a few fixable speedbumps along the way), mongorestore is definitely a possibility.

Please see my comment on Replace mongodb binaries all at once? for more elaboration on alternatives to in-place upgrades.

The mongorestore path is the last option discussed in my comment:

Regards,
Stennie

1 Like