0

Can't seem to get nodemon up and running.

It works when using just node (node app.js) but when using nodemon (nodemon app.js) the following Emfile error is returned:

20 Nov 12:26:33 - [nodemon] v0.7.10
20 Nov 12:26:33 - [nodemon] to restart at any time, enter `rs`
20 Nov 12:26:33 - [nodemon] watching: /home/ramzi/ST/swaggertrack
20 Nov 12:26:33 - [nodemon] starting `node app.js`
connect.multipart() will be removed in connect 3.0
visit https://github.com/senchalabs/connect/wiki/Connect-3.0 for alternatives
connect.limit() will be removed in connect 3.0
Express server listening on port 80
mongo is connected
EMFILE: Watching too many files.
EMFILE: Watching too many files.
EMFILE: Watching too many files.
EMFILE: Watching too many files.

Has anyone got any thoughts?

Thanks.

Mantissa
  • 91
  • 3
  • 15
  • `EMFILE` happens when your process opened too many files at once. How many files/subdirectories do you have in your folder? Also, edit [your .nodemonignore file](https://github.com/remy/nodemon#ignoring-files) with the files or directories you don't want to watch, this should fix the issue. – Paul Mougel Nov 20 '13 at 12:45
  • Had to reinstall node, npm and nodemom and also re cloned my git repo. It then worked so think it was due to some sort of library duplication. – Mantissa Nov 26 '13 at 17:58

1 Answers1

0

If you update to nodemon@1.0.12 (currently latest) it will warn out if there's too many files being watched (i.e. > 25,000 files - a rough arbitrary number I chose). If you don't get that warning, it's possible it's your script.

Happy to help debug (assuming you're on the latest version) at http://github.com/remy/nodemon/issues/new

Remy Sharp
  • 4,520
  • 3
  • 23
  • 40