error starting todos example

我的梦境 提交于 2019-12-21 05:07:16

问题


noob here. on linux, i installed meteor, tried to load 'todos' app, got this error. it seems to be related to file system monitoring? am i missing a package or perm? i installed meteor with sudo, but i installed the 'todos' as my basic user.

thanks in advance!

~$ mkdir meteorDev
~$ cd meteorDev/
~/meteorDev$ meteor create --example todos
todos: created.

To run your new app:
   cd todos
   meteor
~/meteorDev$ cd todos/
~/meteorDev/todos$ meteor
[[[[[ ~/meteorDev/todos ]]]]]

Running on: http://localhost:3000/

fs.js:663
    throw errnoException(errno, 'watch');
          ^
Error: watch EMFILE
    at errnoException (fs.js:636:11)
    at FSWatcher.start (fs.js:663:11)
    at Object.watch (fs.js:691:11)
    at [object Object]._scan (/usr/lib/meteor/app/meteor/run.js:322:12)
    at Array.forEach (native)
    at Function.<anonymous> (/usr/lib/meteor/app/lib/third/underscore.js:76:11)
    at new <anonymous> (/usr/lib/meteor/app/meteor/run.js:264:5)
    at /usr/lib/meteor/app/meteor/run.js:455:17
    at /usr/lib/meteor/app/meteor/run.js:512:5
    at /usr/lib/meteor/app/meteor/run.js:570:9

回答1:


Meteor uses node's "fs.watch" command, which uses linux's inotify API. It is possible your system does not have inotify support, or it is turned off. Try this to see if you have inotify enabled:

 cat /proc/sys/fs/inotify/max_user_instances

If that file exists and has a low number in it, try this as root to up the limit:

 echo 8192 > /proc/sys/fs/inotify/max_user_instances

If that file does not exist, it is likely your system does not support inotify or it is somehow turned off.

The increase in max_user_instances is temporary and won't persist after a reboot. To make it permanent:

 echo fs.inotify.max_user_instances=8192 | sudo tee /etc/sysctl.d/10-inotify.conf && sudo sysctl -p



回答2:


Do you have MongoDB installed? Try running it in another shell.

mongod


来源:https://stackoverflow.com/questions/10129496/error-starting-todos-example

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!