流星:mongo退出代码48

时间:2015-03-19 15:13:47

标签: node.js mongodb meteor

对我来说,不可能在我们拥有的一台特定计算机上启动Meteor。在所有其他方面,这很好。它正在运行

Linux ip-10-2-103-74 3.13.0-45-generic #74-Ubuntu SMP Tue Jan 13 19:36:28 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

Meteor 1.0.4.1

我使用的端口上没有运行任何东西。港口是开放的,可用的。我每次都使用一个不同的端口(随机)来排除任何僵持这些端口的东西。我有chmod' ed 777(并尝试使用sudo运行)以排除任何权限问题。

尝试1:

$ meteor create fresh_project
$ cd fresh_project
$ meteor --port 3863

fresh_project: created.                       

To run your new app:                          
  cd fresh_project                            
  meteor                                      
[[[[[ ~/tests/fresh_project ]]]]]             

=> Started proxy.                             
Unexpected mongo exit code 48. Restarting.    
Unexpected mongo exit code 48. Restarting.    
Unexpected mongo exit code 48. Restarting.    
Can't start Mongo server.                     
MongoDB exited because its port was closed, or was already
taken by a previous instance of MongoDB

Check for other processes listening on port 3863
or other Meteor instances running in the same project.

顺便说一下,独立的mongodb抱怨很多东西

$ tail -f /var/log/mongodb/mongodb.log
Thu Mar 19 14:01:25.257 [initandlisten] shutdown: waiting for fs preallocator...
Thu Mar 19 14:01:25.257 [initandlisten] shutdown: lock for final commit...
Thu Mar 19 14:01:25.257 [initandlisten] shutdown: final commit...
Thu Mar 19 14:01:25.259 [websvr] ERROR: listen(): bind() failed errno:99 Cannot assign requested address for socket: 127.0.0.1:28017
Thu Mar 19 14:01:25.264 [initandlisten] shutdown: closing all files...
Thu Mar 19 14:01:25.264 [initandlisten] closeAllFiles() finished
Thu Mar 19 14:01:25.264 [initandlisten] journalCleanup...
Thu Mar 19 14:01:25.264 [initandlisten] removeJournalFiles
Thu Mar 19 14:01:25.281 [initandlisten] shutdown: removing fs lock...
Thu Mar 19 14:01:25.281 dbexit: really exiting now

更改端口也无济于事。完全杀了它 通过清除移除mongodb,重新安装流星,创建一个新项目,这一切都没有。我可能已经尝试过我能找到的每个错误报告的每一步。

尝试2:

~/myapp$ MONGO_URL=mongodb://localhost:27017/myapp meteor run --port 4243
$ ./run.sh 
[[[[[ ~/myapp ]]]]]                           

=> Started proxy.                             
W20150319-16:03:52.596(1)? (STDERR) Error: listen EADDRNOTAVAIL
W20150319-16:03:52.607(1)? (STDERR)     at errnoException (net.js:905:11)
W20150319-16:03:52.608(1)? (STDERR)     at Server._listen2 (net.js:1024:19)
W20150319-16:03:52.608(1)? (STDERR)     at listen (net.js:1065:10)
W20150319-16:03:52.608(1)? (STDERR)     at net.js:1147:9
W20150319-16:03:52.608(1)? (STDERR)     at dns.js:72:18
W20150319-16:03:52.608(1)? (STDERR)     at process._tickCallback (node.js:442:13)
=> Started your app.

=> App running at: http://localhost:4243/

然而,该应用程序无法从计算机本身访问,当然也无法从外部世界访问。

1 个答案:

答案 0 :(得分:0)

问题是环回接口没有启动。所以没有任何端口可以绑定。