NEWS
Raspberrypi install iobroker - node.js 8.12
-
Hi to all
Try to install iobroker on Raspberrypi 3
Install not possible, cause node.js version
How can i update node.js to the 8.12 version?
Thanks for you support :geek:
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ioBroker needs at least Node.JS 8.12\. You have installed 8.11.1 Please update your Node.JS version! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! npm WARN This failure might be due to the use of legacy binary "node" npm WARN For further explanations, please read /usr/share/doc/nodejs/README.Debian npm ERR! iobroker@1.3.1 install: `node lib/checkVersions.js` npm ERR! Exit status 2 npm ERR! npm ERR! Failed at the iobroker@1.3.1 install script. npm ERR! This is most likely a problem with the iobroker package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node lib/checkVersions.js npm ERR! You can get their info via: npm ERR! npm owner ls iobroker npm ERR! There is likely additional logging output above. npm ERR! System Linux 4.14.79-v7+ npm ERR! command "/usr/bin/node" "/usr/bin/npm" "install" "iobroker" npm ERR! cwd /home/pi npm ERR! node -v v8.11.1 npm ERR! npm -v 1.4.21 npm ERR! code ELIFECYCLE npm ERR! npm ERR! Additional logging details can be found in: npm ERR! /home/pi/npm-debug.log npm ERR! not ok code 0 -
I used this instructions
http://www.iobroker.net/docu/?page_id=5090&lang=en
Installation of Node.js 1\. Kernel Update: sudo apt-get update && sudo apt-get upgrade 2\. Deinstall old node.je Version (not required by Jessie Light) 1.apt-get --purge remove node 2.apt-get --purge remove nodejs 3.apt-get autoremove 4.reboot 3\. login as root via Putty 4\. Install Node.js anew for Raspbery 2/3 1.curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash - 2.sudo apt-get install -y build-essential python-rpi.gpio python nodejs 3.reboot 5\. login as root via Putty sudo su (now is Root Mode active) 6\. After installation of node.js the command “node -v” should show the node.js version. if not, create alias to bin file:: sudo ln -s /usr/local/bin/nodejs /usr/bin/nodenpm is up to date?
pi@panel:~ $ npm -v 1.4.21 (node:2450) [DEP0022] DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpd ir() instead. pi@panel:~ $ node -v v8.11.1 pi@panel:~ $ nodejs -v v8.11.1Thank you
-
please remove node and nodejs again
sudo apt-get purge node sudo apt-get purge nodejsand check the versions again
node -v nodejs -v npm -vthe actual npm version is very strange
looks like ther was a nodejs already installed by the OS
Greets
Rainer
-
> Error: EACCES: permission denied, scandir '/root/.npm/_logs'
Runsudo chown -R $(whoami) ~/.npmand try again.
And try
npm rebuildwithout sudo before resorting tosudo npm rebuild. sudo is known to cause problems. `hm…
just to clarity first...
sudo chown -R $(whoami) ~/.npmmeans that the ohnership of all files and subdirectories are transferred to user "pi"?
and I have to set this commad at /opt/iobroker ?
and what is with iobroker? do I have to stop it first?
-
just to clarity first…
sudo chown -R $(whoami) ~/.npmmeans that the ohnership of all files and subdirectories are transferred to user "pi"? `
Newer npm versions have the tendency to change the ownership of the .npm folder in the current user's homedir (~). So when you execute npm install with sudo and later without, it won't be able to access ~/.npm (e.g. /home/pi/.npm) because it now belongs to root.
The above command changes the ownership back to whomever it belonged in the first place.
And no, you don't need to do anything with iobroker or change folder to execute that command.
-
I tryed n
sudo chown -R $(whoami) ~/.npm
==> no output, cursor prompt returns within miliseconds
then
npm rebuild
from the root directory shows this
! pi@ioBroker-Pi:~ $ npm rebuild
! ajv@6.5.5 /home/pi/node_modules/ajv
! fast-deep-equal@2.0.1 /home/pi/node_modules/fast-deep-equal
! fast-json-stable-stringify@2.0.0 /home/pi/node_modules/fast-json-stable-stringify
! json-schema-traverse@0.4.1 /home/pi/node_modules/json-schema-traverse
! uri-js@4.2.2 /home/pi/node_modules/uri-js
! punycode@2.1.1 /home/pi/node_modules/punycode
! asap@2.0.6 /home/pi/node_modules/asap
! asn1@0.2.4 /home/pi/node_modules/asn1
! safer-buffer@2.1.2 /home/pi/node_modules/safer-buffer
! assert-plus@1.0.0 /home/pi/node_modules/assert-plus
! asynckit@0.4.0 /home/pi/node_modules/asynckit
! aws-sign2@0.7.0 /home/pi/node_modules/aws-sign2
! aws4@1.8.0 /home/pi/node_modules/aws4
! bcrypt-pbkdf@1.0.2 /home/pi/node_modules/bcrypt-pbkdf
! tweetnacl@0.14.5 /home/pi/node_modules/tweetnacl
! caseless@0.12.0 /home/pi/node_modules/caseless
! combined-stream@1.0.7 /home/pi/node_modules/combined-stream
! delayed-stream@1.0.0 /home/pi/node_modules/delayed-stream
! core-util-is@1.0.2 /home/pi/node_modules/core-util-is
! dashdash@1.14.1 /home/pi/node_modules/dashdash
! debug@2.6.9 /home/pi/node_modules/debug
! ms@2.0.0 /home/pi/node_modules/ms
! ecc-jsbn@0.1.2 /home/pi/node_modules/ecc-jsbn
! jsbn@0.1.1 /home/pi/node_modules/jsbn
! extend@3.0.2 /home/pi/node_modules/extend
! extsprintf@1.3.0 /home/pi/node_modules/extsprintf
! forever-agent@0.6.1 /home/pi/node_modules/forever-agent
! form-data@2.3.3 /home/pi/node_modules/form-data
! mime-types@2.1.21 /home/pi/node_modules/mime-types
! mime-db@1.37.0 /home/pi/node_modules/mime-db
! getpass@0.1.7 /home/pi/node_modules/getpass
! har-schema@2.0.0 /home/pi/node_modules/har-schema
! har-validator@5.1.3 /home/pi/node_modules/har-validator
! http-signature@1.2.0 /home/pi/node_modules/http-signature
! jsprim@1.4.1 /home/pi/node_modules/jsprim
! json-schema@0.2.3 /home/pi/node_modules/json-schema
! verror@1.10.0 /home/pi/node_modules/verror
! sshpk@1.15.2 /home/pi/node_modules/sshpk
! ip@1.1.5 /home/pi/node_modules/ip
! is-absolute@0.2.6 /home/pi/node_modules/is-absolute
! is-relative@0.2.1 /home/pi/node_modules/is-relative
! is-unc-path@0.1.2 /home/pi/node_modules/is-unc-path
! unc-path-regex@0.1.2 /home/pi/node_modules/unc-path-regex
! is-windows@0.2.0 /home/pi/node_modules/is-windows
! is-typedarray@1.0.0 /home/pi/node_modules/is-typedarray
! isstream@0.1.2 /home/pi/node_modules/isstream
! json-stringify-safe@5.0.1 /home/pi/node_modules/json-stringify-safe
! lodash@4.17.11 /home/pi/node_modules/lodash
! minimist@0.0.8 /home/pi/node_modules/minimist
! mkdirp@0.5.1 /home/pi/node_modules/mkdirp
! node-persist@2.1.0 /home/pi/node_modules/node-persist
! q@1.1.2 /home/pi/node_modules/q
! node-red-contrib-alexa-local@0.3.12 /home/pi/node_modules/node-red-contrib-alexa-local
! peer-ssdp@0.0.5 /home/pi/node_modules/peer-ssdp
! stoppable@1.0.5 /home/pi/node_modules/stoppable
! node-red-contrib-bool-gate@1.0.2 /home/pi/node_modules/node-red-contrib-bool-gate
! node-red-contrib-wemo-emulator@0.6.0 /home/pi/node_modules/node-red-contrib-wemo-emulator
! wemore@0.6.0 /home/pi/node_modules/wemore
! node-ssdp@2.9.1 /home/pi/node_modules/node-ssdp
! q@2.0.3 /home/pi/node_modules/wemore/node_modules/q
! pop-iterate@1.0.1 /home/pi/node_modules/pop-iterate
! weak-map@1.0.5 /home/pi/node_modules/weak-map
! request@2.88.0 /home/pi/node_modules/request
! oauth-sign@0.9.0 /home/pi/node_modules/oauth-sign
! performance-now@2.1.0 /home/pi/node_modules/performance-now
! qs@6.5.2 /home/pi/node_modules/qs
! safe-buffer@5.1.2 /home/pi/node_modules/safe-buffer
! tough-cookie@2.4.3 /home/pi/node_modules/tough-cookie
! psl@1.1.29 /home/pi/node_modules/psl
! punycode@1.4.1 /home/pi/node_modules/tough-cookie/node_modules/punycode
! tunnel-agent@0.6.0 /home/pi/node_modules/tunnel-agent
! uuid@3.3.2 /home/pi/node_modules/uuid
! xml2js@0.4.19 /home/pi/node_modules/xml2js
! sax@1.2.4 /home/pi/node_modules/sax
! xmlbuilder@9.0.7 /home/pi/node_modules/xmlbuilderbut with starting point /opt/iobroker all the same sh… again