Version 2.2.0 causes "Can't start Mongo server.Unspecified unrecoverable error. Exit was not clean" error

I’ve upgraded from Meteor version 2.1.1 to 2.2.0 and I’m experiencing errors when trying to build the Windows and macOS versions using Meteor-Desktop.

Has anyone else experienced this problem?

The error shown is:

Can't start Mongo server.Unspecified unrecoverable error. Exit was not clean

The meteor.log file is showing the following:

Unexpected mongo exit code 14. Restarting.

Unexpected mongo exit code 14. Restarting.

Unexpected mongo exit code 14. Restarting.

Can't start Mongo server.
Unspecified unrecoverable error. Exit was not clean

Someone posted about corrupted data earlier. Might be a similar issue. Mongodb driver has been updated

We have the same error and it would be a big bummer if it requires us to purge the entire database

OK fixed it by downloading the 4.2 binaries, running mongod --dbpath .meteor/local/db and then connecting to run the command

db.adminCommand( { setFeatureCompatibilityVersion: "4.2"} )

Then I could start meteor again since 4.4 is compatible with 4.2 (but not 4.0 which is what I had in my local db)

A good tip btw is to run a local mongod of the same version as meteor has embedded against .meteor/local/db since it will show much better error messages

We’re on version 4.2.13. So that can’t be the problem.

The solution that worked for us is to delete the content of the db folder under the .meteor folder. That fixed it the MongoDb problem.

It build without any further problems but we have Linux and macOS users reporting problems with the app all of a sudden now.

When mongodb upgrade its version would be need to upgrade database.
An right method is to backup and restore database, in local environment can do:

  • start Meteor in early version and backup mongo database with: mongodump --forceTableScan -h 127.0.0.1 --port 3001 -d meteor
  • update Meteor, delete “.meteor/local/db” directory, start meteor and then restore with: mongorestore -h 127.0.0.1 --port 3001 ./dump/

In production need to do the same thing, backup and restore database.

1 Like