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

EPERM while executing nodemon on new Bash on Windows 10 feature #859

Closed
kosinw opened this issue Jun 16, 2016 · 18 comments
Closed

EPERM while executing nodemon on new Bash on Windows 10 feature #859

kosinw opened this issue Jun 16, 2016 · 18 comments
Labels
stale no activity for 2 weeks

Comments

@kosinw
Copy link

kosinw commented Jun 16, 2016

I am using ZSH on the new Bash on Windows 10 and whenever i run nodemon it still runs but it gives me this error and still allows me to use to command line

Command: sudo nodemon index.js
Output: [nodemon] Internal watch failed: watch (current directory) EPERM

Nodemon Dump Output:

[nodemon] 1.9.2
[nodemon] to restart at any time, enter `rs`
[nodemon] watching: *.*
--------------
node: v4.4.5
nodemon: 1.9.2
command: /usr/local/bin/node /usr/local/bin/nodemon index.js --dump
cwd: /mnt/d/sandbox/Web Projects/studious-carnival
OS: linux x64
--------------
{ run: false,
  system: { cwd: '/mnt/d/sandbox/Web Projects/studious-carnival' },
  required: false,
  dirs: [ '/mnt/d/sandbox/Web Projects/studious-carnival' ],
  timeout: 1000,
  options:
   { dump: true,
     ignore:
      [ '.git',
        '.nyc_output',
        '.sass-cache',
        'bower_components',
        'coverage',
        'node_modules',
        re: /\.git|\.nyc_output|\.sass\-cache|bower_components|coverage|node_modules/ ],
     watch: [ '*.*', re: /.*\..*/ ],
     ignoreRoot:
      [ '.git',
        '.nyc_output',
        '.sass-cache',
        'bower_components',
        'coverage',
        'node_modules' ],
     restartable: 'rs',
     colours: true,
     execMap: { py: 'python', rb: 'ruby' },
     stdin: true,
     runOnChangeOnly: false,
     verbose: false,
     stdout: true,
     execOptions:
      { script: 'index.js',
        exec: 'node',
        args: [],
        scriptPosition: 0,
        nodeArgs: undefined,
        ext: 'js,json',
        env: {},
        execArgs: [] },
     monitor:
      [ '*.*',
        '!/mnt/d/sandbox/Web Projects/studious-carnival/.git/**/*',
        '!.nyc_output',
        '!.sass-cache',
        '!bower_components',
        '!coverage',
        '!/mnt/d/sandbox/Web Projects/studious-carnival/node_modules/**/*' ] },
  load: [Function],
  reset: [Function: reset],
  lastStarted: 0,
  loaded: [],
  watchInterval: null,
  command:
   { raw: { executable: 'node', args: [ 'index.js' ] },
     string: 'node index.js' } }
@wellguimaraes
Copy link

I'm having this problem too. Are you running Win10 on a VM?

@kosinw
Copy link
Author

kosinw commented Jun 18, 2016

No, I am just running the new Insider Build with the Bash feature.

@tanepiper
Copy link

Can confirm I am getting the same issue with Bash On Ubuntu for Windows

@kosinw
Copy link
Author

kosinw commented Jul 9, 2016

No reason for this to be open

@kosinw kosinw closed this as completed Jul 9, 2016
@tanepiper
Copy link

@knwabueze Why? Do you have a solution to this?

@jdrydn
Copy link

jdrydn commented Jul 15, 2016

Yeah I'm also getting this issue, although I reckon it could be more to do with Bash for Windows than actually a nodemon error.

@knwabueze A clearer message would be appreciated, just closing the issue with no real explanation isn't supportive?

@kosinw
Copy link
Author

kosinw commented Jul 17, 2016

Sorry for not clarifying, I couldn't solve it out and just decided it would be better for me to switch to using a different shell. I couldn't do too much I'm still pretty new to Node.js

@kosinw kosinw reopened this Jul 17, 2016
@jackchammons
Copy link

@knwabueze It looks like this is a problem with the Windows Subsystem for Linux. Would you mind filing this issue with us?

https://github.com/Microsoft/BashOnWindows/issues

@YasharF
Copy link

YasharF commented Aug 15, 2016

Related: microsoft/WSL#723 and microsoft/WSL#216

Please vote here to get it fixed in Windows 10 Bash: https://wpdev.uservoice.com/forums/266908-command-prompt-console-bash-on-ubuntu-on-windo/suggestions/13469097-support-for-filesystem-watchers-like-inotify

@YasharF
Copy link

YasharF commented Aug 15, 2016

It looks like in cases like with rails, they have workarounds in the meantime. Is there a way to have a workaround for Nodemon?

@jopcode
Copy link

jopcode commented Nov 7, 2016

same error, some solution? :/, and i don't use zsh or another shell

@YasharF
Copy link

YasharF commented Nov 7, 2016

I can confirm that this is resolved in the latest builds of Windows 10 (I'm running 14959 atm), but those builds are still part of the Fast Ring Insider Preview program, and have other known issues.

@Naoto-Ida
Copy link

I don't use zsh either, but this still seems to be happening.

@williamoverton
Copy link

Same issue :/

@izikandrw
Copy link

this is happening to me TT

@whitneyland
Copy link

whitneyland commented Sep 8, 2017

One more status report:

  • Still happening in Windows 10.0.15063.
  • These did not resolve the problem:

        1. Microsoft fix (thought to be related) has completed for a while https://wpdev.uservoice.com/forums/266908-command-prompt-console-bash-on-ubuntu-on-windo/suggestions/13469097-support-for-filesystem-watchers-like-inotify
        2. Stopped virus scanning
        3. Using Node command prompt admin rights for install
        4. Removing readonly permissions from node_modules folder

@YasharF
Copy link

YasharF commented Sep 11, 2017

The original issue was fixed with changes from Microsoft about 10 months ago which got added to the production releases I think about four to five months ago, and I have not had an issue since. Are all of your software including the linux subsystem, system packages (apt-get), and globally installed npm packages up to date? Can you provide log/dump of the output? The following is my current setup which the problem is no longer present in.

======= My Windows version when I open CMD
Microsoft Windows [Version 10.0.15063]

======= My Windows Subsystem for Linux version:

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=16.04
DISTRIB_CODENAME=xenial
DISTRIB_DESCRIPTION="Ubuntu 16.04.3 LTS"
NAME="Ubuntu"
VERSION="16.04.3 LTS (Xenial Xerus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 16.04.3 LTS"
VERSION_ID="16.04"
HOME_URL="http://www.ubuntu.com/"
SUPPORT_URL="http://help.ubuntu.com/"
BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/"
VERSION_CODENAME=xenial
UBUNTU_CODENAME=xenial

======= My linux package status:

$ sudo apt-get update && sudo apt-get upgrade
[sudo] password for {redacted username}:
Get:1 http://security.ubuntu.com/ubuntu xenial-security InRelease [102 kB]
Hit:2 https://cli-assets.heroku.com/branches/stable/apt ./ InRelease
Hit:3 http://archive.ubuntu.com/ubuntu xenial InRelease
Hit:4 https://deb.nodesource.com/node_6.x xenial InRelease
Get:5 http://archive.ubuntu.com/ubuntu xenial-updates InRelease [102 kB]
Fetched 204 kB in 1s (120 kB/s)
Reading package lists... Done
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  libegl1-mesa libgbm1 libgl1-mesa-dri libmirclient9 libwayland-egl1-mesa
  nodejs
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.

======= My node version:

$ nodejs -v
v6.11.2

======= My global npm update status:

$ sudo npm update -g
{blank response since everything was up to date}

======= My global npm packages and their versions:

$ sudo npm list -g --depth=0
/usr/lib
---- [email protected]
---- [email protected]

======= What I am getting when I run nodemon:

/mnt/c/temp/myProject$ nodemon
[nodemon] 1.12.0
[nodemon] to restart at any time, enter `rs`
[nodemon] watching: *.*
[nodemon] starting `node ./bin/www`
Listening on port 3001

@stale
Copy link

stale bot commented Dec 5, 2017

This issue has been automatically marked as idle and stale because it hasn't had any recent activity. It will be automtically closed if no further activity occurs. If you think this is wrong, or the problem still persists, just pop a reply in the comments and @remy will (try!) to follow up.
Thank you for contributing <3

@stale stale bot added the stale no activity for 2 weeks label Dec 5, 2017
@stale stale bot closed this as completed Dec 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale no activity for 2 weeks
Projects
None yet
Development

No branches or pull requests