So I'm trying to install socket.io on my machine, and I'm coming across this little gem:
[ME ~]$ sudo npm install socket.io
npm ERR! Error: ENOTFOUND, Domain name not found
npm ERR! at IOWatcher.callback (dns.js:74:15)
npm ERR! Report this *entire* log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR!
npm ERR! System Linux 2.6.35.13-92.fc14.x86_64
npm ERR! command "node" "/usr/bin/npm" "install" "socket.io"
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/ME/npm-debug.log
npm not ok
[ME ~]$
I can't tell if it has to do with my firewall, my npm that I have installed, or some other such issue...has anyone encountered a similar issue?
Related
I am having trouble installing electron in Ubuntu 14.04. I'm receiving this error code
install Couldn't read dependencies
npm ERR! Error: ENOENT, open '/home/vinitas/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 Linux 4.2.0-36-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /home/vinitas
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /home/vinitas/package.json
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/vinitas/npm-debug.log
npm ERR! not ok code 0
Are you installing it globally? You can use
npm install -g electron
Ubuntu 14.04 with newly installed nodejs npm mongodb
Install cube by npm install cube and it throws the errors:
npm ERR! Error: No dist in websocket-server package
npm ERR! at next (/usr/share/npm/lib/cache.js:746:26)
npm ERR! at /usr/share/npm/lib/cache.js:739:5
npm ERR! at RegClient.get_ (/usr/share/npm/node_modules/npm-registry-client/lib/get.js:105:14)
npm ERR! at RegClient.<anonymous> (/usr/share/npm/node_modules/npm-registry-client/lib/get.js:41:12)
npm ERR! at fs.js:268:14
npm ERR! at /usr/lib/nodejs/graceful-fs/graceful-fs.js:103:5
npm ERR! at Object.oncomplete (fs.js:107:15)
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 Linux 3.13.0-32-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /home/me/cube
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/me/cube/npm-debug.log
npm ERR! not ok code 0
I've tried sudo npm install cube, but it doesn't work too.
I've search the error info by google and sf, I got nothing.
I've found the error:
the official source is not available:
https://www.npmjs.com/package/websocket-server
It's seems the developer's website is closed...
I found the solution by browse the ResqueBoard Issues
Try this:
cd node_modules/
git clone https://github.com/miksago/node-websocket-server
mv node-websocket-server websocket-server
cd..
npm install cube
use the node-websocket-server to replace websocket-server.
hello i try to run npm install -g yo but i have got error :
npm install -g yo
npm http GET https://registry.npmjs.org/yo
npm http 304 https://registry.npmjs.org/yo
npm ERR! Error: No compatible version found: yo
npm ERR! No valid targets found.
npm ERR! Perhaps not compatible with your version of node?
npm ERR! at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:486:10)
npm ERR! at next_ (/usr/local/lib/node_modules/npm/lib/cache.js:436:17)
npm ERR! at next (/usr/local/lib/node_modules/npm/lib/cache.js:413:44)
npm ERR! at /usr/local/lib/node_modules/npm/lib/cache.js:406:5
npm ERR! at saved (/usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/get.js:151:7)
npm ERR! at Object.oncomplete (/usr/local/lib/node_modules/npm/node_modules/graceful-fs/graceful-fs.js:230:7)
npm ERR! 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!
npm ERR! System Linux 3.13.0-36-generic
npm ERR! command "node" "/usr/local/bin/npm" "install" "-g" "yo"
npm ERR! cwd /home
npm ERR! node -v v0.6.18
npm ERR! npm -v 1.1.21
npm ERR! message No compatible version found: yo
npm ERR! message No valid targets found.
npm ERR! message Perhaps not compatible with your version of node?
npm ERR! Error: EACCES, open 'npm-debug.log'
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
npm ERR!
npm ERR! System Linux 3.13.0-36-generic
npm ERR! command "node" "/usr/local/bin/npm" "install" "-g" "yo"
npm ERR! cwd /home
npm ERR! node -v v0.6.18
npm ERR! npm -v 1.1.21
npm ERR! path npm-debug.log
npm ERR! code EACCES
npm ERR! message EACCES, open 'npm-debug.log'
npm ERR! errno {}
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/npm-debug.log
I havent got any idea what is wrong my npm version is 1.1.21 my node version is v0.6.18
Can you give me some advice what is wrong with that configuration ?
You need to upgrade your version of Node.js and npm.
From the Yeoman website:
Install prerequisites
Before installing Yeoman, you will need the following:
Node.js v0.10.x+
npm (which comes bundled with Node) v1.4.3+
git
I don't know what I did wrong, but trying to install a module using npm returns errors. My concrete example (same results, no matter which module I would like to install):
npm install socket.io
Returns:
npm ERR! TypeError: Cannot call method 'replace' of undefined
npm ERR! at /usr/local/lib/node_modules/npm/node_modules/read-package-json/read-json.js:332:45
npm ERR! at fs.js:117:20
npm ERR! at /usr/local/lib/node_modules/npm/node_modules/graceful-fs/graceful-fs.js:53:5
npm ERR! at /usr/local/lib/node_modules/npm/node_modules/graceful-fs/graceful-fs.js:62:5
npm ERR! at Object.oncomplete (fs.js:297:15)
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 Darwin 11.4.2
npm ERR! command "node" "/usr/local/bin/npm" "install" "socket.io"
npm ERR! cwd /Users/Hassen/www/node/btask
npm ERR! node -v v0.8.16
npm ERR! npm -v 1.1.69
npm ERR! type non_object_property_call
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /Users/Hassen/www/node/btask/npm-debug.log
npm ERR! not ok code 0
Any idea? Thanks in advance :)
This error is usually caused by a .git directory in current directory on which no commit has been made.
Either remove the directory or make at least one commit before trying npm again.
EDIT: From this npm issue page;
This issue has been fixed in the latest release. Please update to the latest node and npm (v0.8.17 and v1.2.0, respectively)
Here is my node and npm version:
node -v v0.4.11
npm -v 1.0.27
When I tried to install a module for example express, I get the following error:
[root#localhost npm]# npm install express
npm ERR! Error: First argument needs to be a number, array or string.
npm ERR! at new Buffer (buffer.js:156:15)
npm ERR! at regRequest (/usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/request.js:82:17)
npm ERR! at GET (/usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/request.js:211:3)
npm ERR! at get_ (/usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/get.js:121:3)
npm ERR! at /usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/get.js:46:10
npm ERR! at cb (/usr/local/lib/node_modules/npm/node_modules/graceful-fs/graceful-fs.js:37:9)
npm ERR! Report this *entire* log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR!
npm ERR! System Linux 2.6.40.3-0.fc15.i686.PAE
npm ERR! command "node" "/usr/local/bin/npm" "install" "express"
npm ERR! cwd /home/kelvin/Downloads/npm
npm ERR! node -v v0.4.11
npm ERR! npm -v 1.0.27
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/kelvin/Downloads/npm/npm-debug.log
npm not ok
Looks like your auth is set to something that doesn't work. Not clear how that happened -- perhaps check your /home/kelvin/.npmrc for a stray config? Shooting in the dark a bit. I would try npm mailing list if you don't find something in the rc.
https://github.com/isaacs/npm/issues/1372#issuecomment-2036919
isaacs: "The master branch from git is often unstable. This is fixed in HEAD already."
Solved after git pull, and make install.