Mongodb – Is it possible to upgrade MongoDB from 2.0 to 2.4 directly

mongodbupgrade

We have a replica set with 2 members and one arbiter in production. 10gen documentation states that 2.0 to 2.2 is a binary-compatible “drop-in" upgrade and so it's 2.2 to 2.4. Is it safe to upgrade from the 2.0 version directly to the 2.4 version?

This question was posted on stackoverflow and closed as offtopic. It was suggested to me that I try to ask it here.

Best Answer

In general, yes, you can do this, the 2.4 binaries can be used as drop in replacements. However, there are exceptions. In sharded clusters for example, you have to make sure to do the meta data upgrade

Essentially, the caveats are all really deployment and feature (authentication), not version based. Basically make sure to read the notes here:

http://docs.mongodb.org/manual/release-notes/2.4-upgrade/