I just updated Meteor and now suddenly all my applications throw the following error when trying to run them:
app/packages/mongo-livedata/mongo_driver.js:32
throw err;
^
Error: failed to connect to [127.0.0.1:3002]
at Server.connect.connectionPool.on.server._serverState (/usr/local/meteor/lib/node_modules/mongodb/lib/mongodb/connection/server.js:482:73)
at EventEmitter.emit (events.js:123:20)
at connection.on._self._poolState (/usr/local/meteor/lib/node_modules/mongodb/lib/mongodb/connection/connection_pool.js:96:15)
at EventEmitter.emit (events.js:96:17)
at Socket.errorHandler (/usr/local/meteor/lib/node_modules/mongodb/lib/mongodb/connection/connection.js:411:10)
at Socket.EventEmitter.emit (events.js:93:17)
at Socket._destroy.self.errorEmitted (net.js:328:14)
at process.startup.processNextTick.process._tickCallback (node.js:244:9)
Exited with code: 1
Any tips are welcome! Thanks
Run meteor update
to upgrade to 0.5.4, which should fix it. See below to understand what was wrong.
This was a regression in Meteor 0.5.3. In development mode, Meteor runs ps
in order to figure out if there's an existing mongod
to kill before starting a new mongod
. When making an unrelated bugfix, I added some misguided error checking to see if ps
prints anything to standard error. Unfortunately, on OSX Mountain Lion, if DYLD_LIBRARY_PATH
(or several other environment variables starting with DYLD
, or LD_LIBRARY_PATH
) is set, then running ps
prints a warning to stderr, causing Meteor 0.5.3 to consider ps
to have failed. I fixed this and released the fix in Meteor 0.5.4, thanks to this Stack Overflow question.
I found the problem, I had to use sudo to launch meteor server. In the past I didn't have to do this.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With