Skip to content
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

Browser sync error #6

Closed
moeen-basra opened this issue Dec 9, 2017 · 1 comment
Closed

Browser sync error #6

moeen-basra opened this issue Dec 9, 2017 · 1 comment

Comments

@moeen-basra
Copy link
Owner

Some times on linux, when trying to run npm commands npm run watch-poll or npm run hot
it throws following error.

events.js:136
      throw er; // Unhandled 'error' event
      ^

Error: watch app ENOSPC
    at _errnoException (util.js:1031:13)
    at FSWatcher.start (fs.js:1397:19)
    at Object.fs.watch (fs.js:1423:11)
    at createFsWatchInstance (/var/www/laravel-react/node_modules/chokidar/lib/nodefs-handler.js:37:15)
    at setFsWatchListener (/var/www/laravel-react/node_modules/chokidar/lib/nodefs-handler.js:80:15)
    at FSWatcher.NodeFsHandler._watchWithNodeFs (/var/www/laravel-react/node_modules/chokidar/lib/nodefs-handler.js:228:14)
    at FSWatcher.NodeFsHandler._handleDir (/var/www/laravel-react/node_modules/chokidar/lib/nodefs-handler.js:407:19)
    at FSWatcher.<anonymous> (/var/www/laravel-react/node_modules/chokidar/lib/nodefs-handler.js:455:19)
    at FSWatcher.<anonymous> (/var/www/laravel-react/node_modules/chokidar/lib/nodefs-handler.js:460:16)
    at FSReqWrap.oncomplete (fs.js:167:5)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! laravel-react@2.2.2 hot: `cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the laravel-react@2.2.2 hot script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
@moeen-basra
Copy link
Owner Author

This happens when we cross the limit for the notifications watcher. following command fixes the issue.

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant