U
U
unixwz2017-12-07 11:31:59
Windows
unixwz, 2017-12-07 11:31:59

Why doesn't npm install work in Vagrant?

Hello, I installed Vagrant on Windows 10, created a virtual machine with Ubuntu 16.04, installed NodeJS and vue-cli, created a new project:
vue init webpack test
Then I went to the project folder and started installing dependencies:
npm install
The installation went fine, but at one moment an error appeared:

npm ERR! path /home/ubuntu/data/test/node_modules/fsevents/build/Release/.deps/Users/eshanker/Code/fsevents/lib
npm ERR! code ETXTBSY
npm ERR! errno -26
npm ERR! syscall rmdir
npm ERR! ETXTBSY: text file is busy, rmdir '/home/ubuntu/data/test/node_modules/fsevents/build/Release/.deps/Users/eshanker/Code/fsevents/lib'

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/ubuntu/.npm/_logs/2017-12-07T08_22_39_819Z-debug.log

I googled and found several solutions, it is to add the --no-bin-links option and run the terminal emulator as admin, I tried these two ways and nothing changed. Also, through Edit group policy , I allowed the use of symlinks for the user, and this also turned out to be unsuccessful.
What to do? How to solve this problem? Maybe someone has come across something similar?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
de1m, 2017-12-07
@de1m

".deps/Users/eshanker/Code/fsevents/lib" - this part looks like it was linked from the host machine. This is true?
When installing modules in such a folder, an error often occurs, since npm in Linux does hardlinks or something like that.
And virtualbox does not support this, it seems that there is an option for this, but it somehow worked for me once.

V
Vitaly, 2017-12-07
@allposts_vitali

Good afternoon, what kind of virtual machine are we talking about WSL?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question