question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

'Unable to start server' on npm start on create-react-native-app

See original GitHub issue

Description

Created react native app using create-react-native-app and error on when run npm start in the app folder

Expected Behavior

To start the app and show QR code which a mobile can connect through expo app.

Observed Behavior

What actually happened when you performed the above actions?

If there’s an error message, please paste the full terminal output and error message in this code block:

> whyerrors@0.1.0 start /home/pankaja/Documents/Projects/react-native/whyerrors
> react-native-scripts start

5:24:24 PM: Unable to start server
  See https://git.io/v5vcn for more information, either install watchman or run the following snippet:
    sudo sysctl -w fs.inotify.max_user_instances=1024
    sudo sysctl -w fs.inotify.max_user_watches=12288

npm ERR! Linux 4.13.0-25-generic
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "start"
npm ERR! node v6.11.4
npm ERR! npm  v3.5.2
npm ERR! code ELIFECYCLE
npm ERR! whyerrors@0.1.0 start: `react-native-scripts start`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the whyerrors@0.1.0 start script 'react-native-scripts start'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the whyerrors package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     react-native-scripts start
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs whyerrors
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls whyerrors
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /home/pankaja/Documents/Projects/react-native/whyerrors/npm-debug.log

Environment

Please run these commands in the project folder and fill in their results:

  • npm ls react-native-scripts: react-native-scripts@1.8.1
  • npm ls react-native: react-native@0.50.3
  • npm ls expo: expo@23.0.6
  • node -v: v6.11.4
  • npm -v: 3.5.2
  • yarn --version: not installed
  • watchman version: not installed

Also specify:

  1. Operating system: Ubuntu 17.10
  2. Phone/emulator/simulator & version: not relevant

Reproducible Demo

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:12 (1 by maintainers)

github_iconTop GitHub Comments

22reactions
kennylbjcommented, Feb 2, 2018

Just type following commands to fix it if you don’t wanna install Watchman

sudo sysctl -w fs.inotify.max_user_instances=1024
sudo sysctl -w fs.inotify.max_user_watches=12288
15reactions
redbar0ncommented, Jan 17, 2018

Fixed it.

watchman installation is required:

https://facebook.github.io/watchman/docs/install.html

Thanks to @austinhale suggesting it in this related issue: https://github.com/react-community/create-react-native-app/issues/515

Read more comments on GitHub >

github_iconTop Results From Across the Web

npm start not working in react project [duplicate] - Stack Overflow
After installing the project using create-react-native-app, the npm start command failed to start the server but it was working just fine ...
Read more >
concurrently - npm
Start using concurrently in your project by running `npm i concurrently`. ... Also if one process fails, others still keep running and you ......
Read more >
Build a React Native Login app with Node.js Backend
In this guide, we will cover how to connect React Native and Node.js to develop a login application, having prior knowledge of both...
Read more >
Create React Native app using Expo CLI or ... - Codemagic Blog
Create React Native app using Expo CLI. Run the following commands to create a new React Native project named 'FirstProject' using Expo CLI:....
Read more >
React Native - Environment Setup - Tutorialspoint
C:\Users\Tutorialspoint> npm install -g create-react-native-app ... As instructed, one way to run react native apps on your android devise is to using expo....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found