Can't install ionic. npm errors


#1

I ran npm install -g cordova ionic but I get several npm error:

C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\vinyl-fs\node_modules\glob-watcher\node_modules\gaze>node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild
npm http 200 https://registry.npmjs.org/bytes/0.2.1
npm http GET https://registry.npmjs.org/bytes/-/bytes-0.2.1.tgz
npm http 200 https://registry.npmjs.org/methods
npm http GET https://registry.npmjs.org/methods/-/methods-0.1.0.tgz
npm http GET https://registry.npmjs.org/batch/0.5.0
npm http GET https://registry.npmjs.org/negotiator/0.4.2
npm http 200 https://registry.npmjs.org/cookie/0.1.0
npm http GET https://registry.npmjs.org/cookie/-/cookie-0.1.0.tgz
npm http 200 https://registry.npmjs.org/negotiator/0.3.0
npm http GET https://registry.npmjs.org/negotiator/-/negotiator-0.3.0.tgz
npm http 200 https://registry.npmjs.org/bytes
gyp ERR! configure error
gyp ERR! stack Error: spawn ENOENT
gyp ERR! stack     at errnoException (child_process.js:980:11)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:771:34)
gyp ERR! System Windows_NT 6.2.9200
gyp ERR! command "node" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\vinyl-fs\node_modules\glob-watcher\node_modules\gaze
gyp ERR! node -v v0.10.13
gyp ERR! node-gyp -v v0.10.2
gyp ERR! not ok
unbuild gaze@0.6.4

npm http 200 https://registry.npmjs.org/negotiator/-/negotiator-0.3.0.tgz
npm ERR! Error: ENOENT, chmod 'C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\npm\node_modules\glob\examples'
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>

npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "ionic"
npm ERR! cwd K:\home\projects\tmp\ionic\blank
npm ERR! node -v v0.10.13
npm ERR! npm -v 1.3.2
npm ERR! path C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\npm\node_modules\glob\examples
npm ERR! fstream_path C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\npm\node_modules\glob\examples\g.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! fstream_finish_call setupMadeDir
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack end (C:\Program Files\nodejs\node_modules\npm\node_modules\fstream\lib\writer.js:319:21)
npm ERR! fstream_stack C:\Program Files\nodejs\node_modules\npm\node_modules\fstream\lib\writer.js:336:20
npm ERR! fstream_stack next (C:\Program Files\nodejs\node_modules\npm\node_modules\fstream\lib\writer.js:366:20)
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm http 200 https://registry.npmjs.org/uid2/0.0.3
npm http 200 https://registry.npmjs.org/debug/0.7.4
npm http 200 https://registry.npmjs.org/utils-merge/1.0.0
npm http 200 https://registry.npmjs.org/batch/0.5.0
npm http 200 https://registry.npmjs.org/buffer-crc32/0.2.1
npm ERR! error rolling back Error: ENOTEMPTY, rmdir 'C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\connect\node_modules\multiparty\test\fixture\http\encoding'
npm ERR! error rolling back  ionic@1.0.9 { [Error: ENOTEMPTY, rmdir 'C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\connect\node_modules\multiparty\test\fixture\http\encoding']
npm ERR! error rolling back   errno: 53,
npm ERR! error rolling back   code: 'ENOTEMPTY',
npm ERR! error rolling back   path: 'C:\\Users\\Owner\\AppData\\Roaming\\npm\\node_modules\\ionic\\node_modules\\connect\\node_modules\\multiparty\\test\\fixture\\http\\encoding' }
npm ERR! weird error 1
npm http GET https://registry.npmjs.org/compressible/-/compressible-1.0.0.tgz
npm http GET https://registry.npmjs.org/scmp/-/scmp-0.0.3.tgz
npm http GET https://registry.npmjs.org/parseurl/-/parseurl-1.0.1.tgz
npm http GET https://registry.npmjs.org/debug/-/debug-0.7.4.tgz
npm http GET https://registry.npmjs.org/send/-/send-0.3.0.tgz
npm http GET https://registry.npmjs.org/uid2/-/uid2-0.0.3.tgz
npm http GET https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.0.tgz
npm ERR! Error: ENOENT, lstat 'C:\Users\Owner\AppData\Local\Temp\npm-1672\1399211215936-0.21980593772605062\package\.npmignore'
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>

npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "ionic"
npm ERR! cwd K:\home\projects\tmp\ionic\blank
npm ERR! node -v v0.10.13
npm ERR! npm -v 1.3.2
npm ERR! path C:\Users\Owner\AppData\Local\Temp\npm-1672\1399211215936-0.21980593772605062\package\.npmignore
npm ERR! fstream_path C:\Users\Owner\AppData\Local\Temp\npm-1672\1399211215936-0.21980593772605062\package\.npmignore
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack C:\Program Files\nodejs\node_modules\npm\node_modules\fstream\lib\writer.js:284:26
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! Error: ENOENT, chmod 'C:\Users\Owner\AppData\Local\Temp\npm-1672\1399211216029-0.940924720140174\package\package.json'
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>

npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "ionic"
npm ERR! cwd K:\home\projects\tmp\ionic\blank
npm ERR! node -v v0.10.13
npm ERR! npm -v 1.3.2
npm ERR! path C:\Users\Owner\AppData\Local\Temp\npm-1672\1399211216029-0.940924720140174\package\package.json
npm ERR! fstream_path C:\Users\Owner\AppData\Local\Temp\npm-1672\1399211216029-0.940924720140174\package\package.json
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! fstream_finish_call chmod
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack C:\Program Files\nodejs\node_modules\npm\node_modules\fstream\lib\writer.js:305:19
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm http GET https://registry.npmjs.org/batch/-/batch-0.5.0.tgz
npm http 200 https://registry.npmjs.org/negotiator/0.4.2
npm http GET https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.1.tgz
npm http 200 https://registry.npmjs.org/compressible/-/compressible-1.0.0.tgz
npm http 200 https://registry.npmjs.org/scmp/-/scmp-0.0.3.tgz
npm http 200 https://registry.npmjs.org/parseurl/-/parseurl-1.0.1.tgz
npm http 200 https://registry.npmjs.org/debug/-/debug-0.7.4.tgz
npm http 200 https://registry.npmjs.org/send/-/send-0.3.0.tgz
npm http 200 https://registry.npmjs.org/uid2/-/uid2-0.0.3.tgz
npm http 200 https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.0.tgz
npm http 200 https://registry.npmjs.org/batch/-/batch-0.5.0.tgz
npm http 200 https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.1.tgz
npm http GET https://registry.npmjs.org/negotiator/-/negotiator-0.4.2.tgz
unbuild compression@1.0.0
unbuild csurf@1.1.0
unbuild express-session@1.0.2
unbuild serve-static@1.1.0
unbuild connect@2.14.5
unbuild method-override@1.0.0
npm ERR! error rolling back Error: EPERM, rmdir 'C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\connect\node_modules\multiparty\test\fixture\http\encoding\pf1y5.png.http'
npm ERR! error rolling back  connect@2.14.5 { [Error: EPERM, rmdir 'C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\connect\node_modules\multiparty\test\fixture\http\encoding\pf1y5.png.http']
npm ERR! error rolling back   errno: 50,
npm ERR! error rolling back   code: 'EPERM',
npm ERR! error rolling back   path: 'C:\\Users\\Owner\\AppData\\Roaming\\npm\\node_modules\\ionic\\node_modules\\connect\\node_modules\\multiparty\\test\\fixture\\http\\encoding\\pf1y5.png.http' }
unbuild cookie-parser@1.0.1
npm ERR! Error: ENOENT, lstat 'C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\connect\node_modules\multiparty\test\fixture\http\encoding\pf1y5.png.http'
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>

npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "ionic"
npm ERR! cwd K:\home\projects\tmp\ionic\blank
npm ERR! node -v v0.10.13
npm ERR! npm -v 1.3.2
npm ERR! path C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\connect\node_modules\multiparty\test\fixture\http\encoding\pf1y5.png.http
npm ERR! fstream_path C:\Users\Owner\AppData\Roaming\npm\node_modules\ionic\node_modules\connect\node_modules\multiparty\test\fixture\http\encoding\pf1y5.png.http
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack C:\Program Files\nodejs\node_modules\npm\node_modules\fstream\lib\writer.js:284:26
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm http 200 https://registry.npmjs.org/negotiator/-/negotiator-0.4.2.tgz
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     K:\home\projects\tmp\ionic\blank\npm-debug.log
npm ERR! not ok code 0

#2

I upgraded node and npm to the latest version, and it works.


#3

Glad to hear you got this resolved :smile: