Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Stuck at npm install at fechMetadata checking installable status

Suddently I can't install angular I get stuck at the npm install command "npm install -g @angular/cli" It stays forever on this "checking installable status".

my node version is 8.11.3 (yes I already tried to uninstall node and double checked to see it was really uninstalled) this was the version I had before and was working fine my npm -v gives 5.6.0

then I run the angular command to install angular and it seems to freezing or very very very slow....

like image 570
AnaCS Avatar asked Jan 28 '19 07:01

AnaCS


3 Answers

npm install -g @angular/cli --verbose

After running this command I realized npm was having problems with the connection with registry.npmjs.org

To solve this:

  1. npm config set registry "http://registry.npmjs.org"
  2. npm set maxsockets 3

Viewed here

like image 134
Carherpi Avatar answered Nov 04 '22 01:11

Carherpi


In my case I had to wait for a few minutes and npm finally installed by package. Also I suggest to use --verbose flag to see what's actually is going.

like image 30
atereshkov Avatar answered Nov 04 '22 00:11

atereshkov


Try this: npm install -g --no-optional pm2 This will ignore all the dependencies specified in the package.json file (if present). Hope this helps.

like image 28
Samarth Saxena Avatar answered Nov 04 '22 02:11

Samarth Saxena