While installing angular CLI on Red hat linux I'm getting below errors. Though I can see ng -v output. But due to below error I'm not able to do the ng build or ng serve.
**[root@VMEEPADV07 /]# npm install -g @angular/cli --force**
npm WARN using --force I sure hope you know what you are doing.
/usr/bin/ng -> /usr/lib/node_modules/@angular/cli/bin/ng
enter code here
> [email protected] install /usr/lib/node_modules/@angular/cli/node_modules/fsevents
> node install
internal/modules/cjs/loader.js:573
throw err;
^
Error: Cannot find module '/usr/lib/node_modules/@angular/cli/node_modules/fsevents/install'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:571:15)
at Function.Module._load (internal/modules/cjs/loader.js:497:25)
at Function.Module.runMain (internal/modules/cjs/loader.js:719:10)
at startup (internal/bootstrap/node.js:228:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:576:3)
> @angular/[email protected] postinstall /usr/lib/node_modules/@angular/cli
> node ./bin/ng-update-message.js
internal/modules/cjs/loader.js:573
throw err;
^
Error: Cannot find module '/usr/lib/node_modules/@angular/cli/bin/ng-update-message.js'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:571:15)
at Function.Module._load (internal/modules/cjs/loader.js:497:25)
at Function.Module.runMain (internal/modules/cjs/loader.js:719:10)
at startup (internal/bootstrap/node.js:228:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:576:3)
+ @angular/[email protected]
added 320 packages from 209 contributors in 10.148s
npm cache clean --forceOtherwiserm -rf node_modules/and thennpm install