New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lots of "Warning: watch ENOSPC" warnings #236

Closed
binarykitchen opened this Issue Nov 7, 2013 · 24 comments

Comments

Projects
None yet
@binarykitchen

binarykitchen commented Nov 7, 2013

Like that:

Running "watch" task
Waiting...Warning: watch ENOSPC

Running "watch" task
Waiting...Warning: watch ENOSPC

Running "watch" task
Waiting...Warning: watch ENOSPC

Running "watch" task
Waiting...Warning: watch ENOSPC

Running "watch" task
Waiting...Warning: watch ENOSPC

Running "watch" task
Waiting...Warning: watch ENOSPC

Running "watch" task
Waiting...Warning: watch ENOSPC

Running "watch" task
Waiting...Warning: watch ENOSPC

and then

Running "watch" task
(node) warning: possible EventEmitter memory leak detected. 11 listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
    at StatWatcher.EventEmitter.addListener (events.js:160:15)
    at Object.fs.watchFile (fs.js:1162:8)
    at Gaze._pollFile (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:319:10)
    at /home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:389:12
    at Array.forEach (native)
    at /home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:387:11
    at iterate (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/helper.js:52:5)
    at Object.forEachSeries (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/helper.js:66:3)
    at Gaze._initWatched (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:332:10)
    at Gaze.add (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:167:8)
(node) warning: possible EventEmitter memory leak detected. 11 listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
    at StatWatcher.EventEmitter.addListener (events.js:160:15)
    at Object.fs.watchFile (fs.js:1162:8)
    at Gaze._pollFile (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:319:10)
    at /home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:389:12
    at Array.forEach (native)
    at /home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:387:11
    at iterate (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/helper.js:52:5)
    at Object.forEachSeries (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/helper.js:66:3)
    at Gaze._initWatched (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:332:10)
    at Gaze.add (/home/michael.heuberger/projects/binarykitchen/code/signdna/node_modules/gaze/lib/gaze.js:167:8)

increasing the limit won't help. The ENOSPC error keeps coming up always. Any clues? (older versions didn't have this)

@shama

This comment has been minimized.

Show comment
Hide comment
@shama

shama Nov 8, 2013

Member

Could you post the contents of your Gruntfile that produced this error? Also which version of node.js and which os and version? Thanks!

Member

shama commented Nov 8, 2013

Could you post the contents of your Gruntfile that produced this error? Also which version of node.js and which os and version? Thanks!

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Nov 12, 2013

Forget it. I had a mess in my package.json related to npm dedupe. With the correct versions it is not happening anymore.

binarykitchen commented Nov 12, 2013

Forget it. I had a mess in my package.json related to npm dedupe. With the correct versions it is not happening anymore.

@jfgodoy

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Nov 14, 2013

Ah, interesting. Learning here ...

binarykitchen commented Nov 14, 2013

Ah, interesting. Learning here ...

@petrivoges

This comment has been minimized.

Show comment
Hide comment
@petrivoges

petrivoges Apr 14, 2014

Thanks a million

petrivoges commented Apr 14, 2014

Thanks a million

@kiki-le-singe

This comment has been minimized.

Show comment
Hide comment
@kiki-le-singe

kiki-le-singe commented Sep 4, 2014

@jfgodoy Thanks it works

@migaber

This comment has been minimized.

Show comment
Hide comment
@migaber

migaber Sep 17, 2014

@jfgodoy thanks ... done

migaber commented Sep 17, 2014

@jfgodoy thanks ... done

@kane-thornwyrd

This comment has been minimized.

Show comment
Hide comment
@kane-thornwyrd

kane-thornwyrd Oct 13, 2014

For reference, the solution:

`$ echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p`

Answered Jul 2 '13 at 23:49 by kds

Developped answer:

The system has a limit to how many files can be watched by a user. You can run out of watches pretty quickly if you have Grunt running with other programs like Dropbox. This command increases the maximum amount of watches a user can have.
Benjamin Manns the Sep 3 '13 at 19:28

kane-thornwyrd commented Oct 13, 2014

For reference, the solution:

`$ echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p`

Answered Jul 2 '13 at 23:49 by kds

Developped answer:

The system has a limit to how many files can be watched by a user. You can run out of watches pretty quickly if you have Grunt running with other programs like Dropbox. This command increases the maximum amount of watches a user can have.
Benjamin Manns the Sep 3 '13 at 19:28

@whysama

This comment has been minimized.

Show comment
Hide comment
@whysama

whysama Dec 16, 2014

@jfgodoy Merci beaucoup!

whysama commented Dec 16, 2014

@jfgodoy Merci beaucoup!

@luisgagocasas

This comment has been minimized.

Show comment
Hide comment
@luisgagocasas

luisgagocasas commented Jan 25, 2015

Gracias @jfgodoy

@jomaora

This comment has been minimized.

Show comment
Hide comment
@jomaora

jomaora commented Feb 8, 2015

@jfgodoy thanks!!

@gakuba

This comment has been minimized.

Show comment
Hide comment
@gakuba

gakuba Aug 13, 2015

@jfgodoy thanks. it works on ubuntu 14.04 LTS

gakuba commented Aug 13, 2015

@jfgodoy thanks. it works on ubuntu 14.04 LTS

@Aabir1

This comment has been minimized.

Show comment
Hide comment
@Aabir1

Aabir1 Sep 10, 2015

Thanks. It also work for me

Aabir1 commented Sep 10, 2015

Thanks. It also work for me

@alejandropaciotti

This comment has been minimized.

Show comment
Hide comment
@alejandropaciotti

alejandropaciotti commented Oct 5, 2015

Thanks !!!

@jasonwzw

This comment has been minimized.

Show comment
Hide comment
@jasonwzw

jasonwzw Dec 22, 2015

thx, it works for me!

jasonwzw commented Dec 22, 2015

thx, it works for me!

@nisdis

This comment has been minimized.

Show comment
Hide comment
@nisdis

nisdis Apr 8, 2016

I had and same issue, so I found out it was an Inode issue on my ubuntu box
run the cmd: df -h --output=source,target,ipcent,pcent

to check inode usage
then delete all tmp files to solve the problem

nisdis commented Apr 8, 2016

I had and same issue, so I found out it was an Inode issue on my ubuntu box
run the cmd: df -h --output=source,target,ipcent,pcent

to check inode usage
then delete all tmp files to solve the problem

@GaneshPediredla

This comment has been minimized.

Show comment
Hide comment
@GaneshPediredla

GaneshPediredla Apr 28, 2016

Same Issue I got in my linux Fedora machine. What Should I do now?
Can anyone help me out to solve this problem?

GaneshPediredla commented Apr 28, 2016

Same Issue I got in my linux Fedora machine. What Should I do now?
Can anyone help me out to solve this problem?

@shahfaisal91

This comment has been minimized.

Show comment
Hide comment
@shahfaisal91

shahfaisal91 commented May 3, 2016

@jfgodoy thanks!!

@kane-thornwyrd

This comment has been minimized.

Show comment
Hide comment
@kane-thornwyrd

kane-thornwyrd commented May 3, 2016

@GaneshPediredla #236 (comment) next time READ damnit !

@GaneshPediredla

This comment has been minimized.

Show comment
Hide comment
@GaneshPediredla

GaneshPediredla commented May 4, 2016

@kane-thornwyrd thanks!!

@devendrachhaiya

This comment has been minimized.

Show comment
Hide comment
@devendrachhaiya

devendrachhaiya Sep 8, 2016

Thanks!! @kane-thornwyrd. Your solution works for me.

devendrachhaiya commented Sep 8, 2016

Thanks!! @kane-thornwyrd. Your solution works for me.

@kaleemullah360

This comment has been minimized.

Show comment
Hide comment
@kaleemullah360

kaleemullah360 Jan 18, 2017

SO suggested to do this: and it works too

echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

it wont produce the error again, but consume system Memory & Swap file. mine system has 4GB with 1.5GB Swap space. so can't predict about system with higher Memory that it won't let your work slow.

kaleemullah360 commented Jan 18, 2017

SO suggested to do this: and it works too

echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

it wont produce the error again, but consume system Memory & Swap file. mine system has 4GB with 1.5GB Swap space. so can't predict about system with higher Memory that it won't let your work slow.

@eksyam

This comment has been minimized.

Show comment
Hide comment
@eksyam

eksyam Oct 27, 2017

i have same problem
Error: watch ../src/static ENOSPC
solve with script echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

eksyam commented Oct 27, 2017

i have same problem
Error: watch ../src/static ENOSPC
solve with script echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

@superdav42

This comment has been minimized.

Show comment
Hide comment
@superdav42

superdav42 Apr 9, 2018

Increasing max_user_watches worked for me too. Perhaps a better error message could be emitted?

superdav42 commented Apr 9, 2018

Increasing max_user_watches worked for me too. Perhaps a better error message could be emitted?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment