erikras / react-redux-universal-hot-example

A starter boilerplate for a universal webapp using express, react, redux, webpack, and react-transform
MIT License
12.01k stars 2.5k forks source link

npm run dev not working with ubuntu #1344

Closed anuj-dhanju closed 7 years ago

anuj-dhanju commented 7 years ago

I have clone this project and did npm install. I am using ubuntu. Its working fine on Window system. First day it was working fine. But when I run second day it was not working. Things that I have already tried to fix this..

  1. Delete all node module and reinstall again.
  2. Delete webpack-assets.json
  3. Tried with node version (v5.6.0, v6.0.0, v6.9.0)
  4. Clone again new project and install everything again

I have tried above all but still its not working for me. Please suggest me if I need to do anything else or you have any fix for this. Logs. `$ npm run dev

react-redux-universal-hot-example@0.9.0 dev /home/clickapps/apps/react-redux-lp concurrent --kill-others "npm run watch-client" "npm run start-dev" "npm run start-dev-api"

[1] [1] > react-redux-universal-hot-example@0.9.0 start-dev /home/clickapps/apps/react-redux-lp [1] > better-npm-run start-dev [1] [2] [2] > react-redux-universal-hot-example@0.9.0 start-dev-api /home/clickapps/apps/react-redux-lp [2] > better-npm-run start-dev-api [2] [0] [0] > react-redux-universal-hot-example@0.9.0 watch-client /home/clickapps/apps/react-redux-lp [0] > better-npm-run watch-client [0] [1] running better-npm-run in /home/clickapps/apps/react-redux-lp [1] Executing script: start-dev [1] [1] to be executed: node ./bin/server.js [2] running better-npm-run in /home/clickapps/apps/react-redux-lp [0] running better-npm-run in /home/clickapps/apps/react-redux-lp [2] Executing script: start-dev-api [2] [2] to be executed: node ./bin/api.js [0] Executing script: watch-client [0] [0] to be executed: node webpack/webpack-dev-server.js [2] events.js:160 [2] throw er; // Unhandled 'error' event [2] ^ [2] [2] Error: watch /home/clickapps/apps/react-redux-lp/bin ENOSPC [2] at exports._errnoException (util.js:1022:11) [2] at FSWatcher.start (fs.js:1429:19) [2] at Object.fs.watch (fs.js:1456:11) [2] at createFsWatchInstance (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:37:15) [2] at setFsWatchListener (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:80:15) [2] at FSWatcher.NodeFsHandler._watchWithNodeFs (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:228:14) [2] at FSWatcher.NodeFsHandler._handleDir (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:407:19) [2] at FSWatcher. (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:455:19) [2] at FSWatcher. (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:460:16) [2] at FSReqWrap.oncomplete (fs.js:123:15) [2] [2] npm [2]
[2] ERR! Linux 3.16.0-77-generic [2] npm ERR! [2] argv "/home/clickapps/.nvm/versions/node/v6.9.2/bin/node" "/home/clickapps/.nvm/versions/node/v6.9.2/bin/npm" "run" "start-dev-api" [2] npm ERR! node v6.9.2 [2] npm ERR! npm [2] v3.10.9 [2] npm ERR! [2] code ELIFECYCLE [2] npm ERR! [2] react-redux-universal-hot-example@0.9.0 start-dev-api: better-npm-run start-dev-api [2] npm ERR! Exit status 1 [2] npm ERR! [2] npm [2] ERR! Failed at the react-redux-universal-hot-example@0.9.0 start-dev-api script 'better-npm-run start-dev-api'. [2] npm ERR! [2] Make sure you have the latest version of node.js and npm installed. [2] npm ERR! [2] If you do, this is most likely a problem with the react-redux-universal-hot-example package, [2] npm ERR! not with npm itself. [2] npm ERR! Tell the author that this fails on your system: [2] npm [2] ERR! better-npm-run start-dev-api [2] npm ERR! [2] You can get information on how to open an issue for this project with: [2] npm ERR! npm bugs react-redux-universal-hot-example [2] npm [2] ERR! Or if that isn't available, you can get their info via: [2] npm ERR! npm owner ls react-redux-universal-hot-example [2] npm ERR! There is likely additional logging output above. [2] [2] npm ERR! Please include the following file with any support request: [2] npm ERR! [2] /home/clickapps/apps/react-redux-lp/npm-debug.log [2] npm run start-dev-api exited with code 1 [1] events.js:160 [1] throw er; // Unhandled 'error' event [1] ^ [1] [1] Error: watch /home/clickapps/apps/react-redux-lp/bin ENOSPC [1] at exports._errnoException (util.js:1022:11) [1] at FSWatcher.start (fs.js:1429:19) [1] at Object.fs.watch (fs.js:1456:11) [1] at createFsWatchInstance (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:37:15) [1] at setFsWatchListener (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:80:15) [1] at FSWatcher.NodeFsHandler._watchWithNodeFs (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:228:14) [1] at FSWatcher.NodeFsHandler._handleDir (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:407:19) [1] at FSWatcher. (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:455:19) [1] at FSWatcher. (/home/clickapps/apps/react-redux-lp/node_modules/chokidar/lib/nodefs-handler.js:460:16) [1] at FSReqWrap.oncomplete (fs.js:123:15) [1] [1] npm [1] ERR! Linux 3.16.0-77-generic [1] npm ERR! [1] argv "/home/clickapps/.nvm/versions/node/v6.9.2/bin/node" "/home/clickapps/.nvm/versions/node/v6.9.2/bin/npm" "run" "start-dev" [1] npm ERR! node v6.9.2 [1] npm ERR! npm v3.10.9 [1] npm ERR! code ELIFECYCLE [1] npm ERR! react-redux-universal-hot-example@0.9.0 start-dev: better-npm-run start-dev [1] npm ERR! Exit status 1 [1] npm ERR! [1] npm ERR! Failed at the react-redux-universal-hot-example@0.9.0 start-dev script 'better-npm-run start-dev'. [1] npm ERR! Make sure you have the latest version of node.js and npm installed. [1] npm ERR! If you do, this is most likely a problem with the react-redux-universal-hot-example package, [1] npm ERR! not with npm itself. [1] npm ERR! Tell the author that this fails on your system: [1] npm ERR! better-npm-run start-dev [1] npm ERR! You can get information on how to open an issue for this project with: [1] npm ERR! npm bugs react-redux-universal-hot-example [1] npm ERR! Or if that isn't available, you can get their info via: [1] npm ERR! npm owner ls react-redux-universal-hot-example [1] npm ERR! There is likely additional logging output above. [1] [1] npm [1] ERR! Please include the following file with any support request: [1] npm ERR! /home/clickapps/apps/react-redux-lp/npm-debug.log [1] npm run start-dev exited with code 1 [0] ==> 🚧 Webpack development server listening on port 3001 --> Sending SIGTERM to other processes.. --> Sending SIGTERM to other processes.. [0] Hash: d4d7e656d6ffa9a1c247 [0] Version: webpack 1.14.0 [0] Time: 18077ms [0] Asset Size Chunks Chunk Names [0] af7ae505a9eed503f8b8e6982036873e.woff2 77.2 kB [emitted]
[0] f4769f9bdb7466be65088239c12046d1.eot 20.1 kB [emitted]
[0] fa2772327f55d8198301fdb8bcfc8158.woff 23.4 kB [emitted]
[0] e18bbf611f2a2e43afc071aa2f4e1512.ttf 45.4 kB [emitted]
[0] 89889688147bd7575d6327160d64e760.svg 109 kB [emitted]
[0] 674f50d287a8c48dc19ba404d20fe713.eot 166 kB [emitted]
[0] 448c34a56d699c29117adc64c43affeb.woff2 18 kB [emitted]
[0] fee66e712a8a08eef5805a46892932ad.woff 98 kB [emitted]
[0] b06871f281fee6b241d60582ae9369b9.ttf 166 kB [emitted]
[0] 912ec66d7572ff821749319396470bde.svg 444 kB [emitted]
[0] c29770d03d2e95e3ea5899d57c6cfeab.jpg 92.2 kB [emitted]
[0] main-d4d7e656d6ffa9a1c247.js 7.99 MB 0 [emitted] main [0] webpack built d4d7e656d6ffa9a1c247 in 18077ms `

anuj-dhanju commented 7 years ago

After long efforts I have find out the solution. I have just increase the inotify max_user_watch limit. https://github.com/guard/listen/wiki/Increasing-the-amount-of-inotify-watchers

Thank you