NEWS
Upgrad js-controller 1.2.3 -> 1.2.6 = Fehler
-
Hallo zusammen,
eigentlich wollte ich einfach nur den js-controller auf die neueste Version aktualisieren, jedoch erhalte ich Fehler.
Ich hab es wie beschrieben durchgeführt:
cd /opt/iobroker
iobroker stop
iobroker update
iobroker upgrade self
Leider kann ich auf die ganz alten Ausgaben nicht mehr zugreifen. Wenn ich versuche iobroker zu starten, erhalte ich folgende Meldung:
root@iobroker:/opt/iobroker# iobroker start module.js:442 throw err; ^ Error: Cannot find module 'yargs' at Function.Module._resolveFilename (module.js:440:15) at Function.Module._load (module.js:388:25) at Module.require (module.js:468:17) at require (internal/module.js:20:19) at initYargs (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup.js:28:13) at Object.module.exports.execute (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup.js:3097:18) at Object. <anonymous>(/opt/iobroker/node_modules/iobroker.js-controller/iobroker.js:1:100) at Module._compile (module.js:541:32) at Object.Module._extensions..js (module.js:550:10) at Module.load (module.js:458:32)</anonymous>
root@iobroker:/opt/iobroker# iobroker update module.js:442 throw err; ^ Error: Cannot find module 'yargs' at Function.Module._resolveFilename (module.js:440:15) at Function.Module._load (module.js:388:25) at Module.require (module.js:468:17) at require (internal/module.js:20:19) at initYargs (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup.js:28:13) at Object.module.exports.execute (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup.js:3097:18) at Object. <anonymous>(/opt/iobroker/node_modules/iobroker.js-controller/iobroker.js:1:100) at Module._compile (module.js:541:32) at Object.Module._extensions..js (module.js:550:10) at Module.load (module.js:458:32)</anonymous>
root@iobroker:/opt/iobroker# npm cache clean root@iobroker:/opt/iobroker# npm install iobroker.js-controller --production npm WARN deprecated localhost.daplie.me-certificates@1.3.5: this package has been deprecated iobroker@1.0.0 /opt/iobroker +-- iobroker.admin@3.2.4 extraneous +-- mime@1.6.0 extraneous +-- tar@4.4.0 extraneous +-- winston-syslog@2.0.0 extraneous `-- yargs@11.0.0 extraneous npm WARN optional Skipping failed optional dependency /iobroker.radar/noble/xpc-connection: npm WARN notsup Not compatible with your operating system or architecture: xpc-connection@0.1.4 npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/cliui/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/cross-spawn/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/execa/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/gauge/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/lru-cache/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/node-pre-gyp/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/tar-pack/package.json' npm ERR! Linux 4.1.18-v7+ npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "iobroker.js-controller" "--production" npm ERR! node v6.3.1 npm ERR! npm v3.10.3 npm ERR! path /opt/iobroker/node_modules/.staging/abbrev-bc1a4de2 npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall rename npm ERR! enoent ENOENT: no such file or directory, rename '/opt/iobroker/node_modules/.staging/abbrev-bc1a4de2' -> '/opt/iobroker/node_modules/npm/node_modules/abbrev' npm ERR! enoent ENOENT: no such file or directory, rename '/opt/iobroker/node_modules/.staging/abbrev-bc1a4de2' -> '/opt/iobroker/node_modules/npm/node_modules/abbrev' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent npm ERR! Please include the following file with any support request: npm ERR! /opt/iobroker/npm-debug.log
Ich weiß nicht mehr weiter. Wer hat Ideen?
-
ich habe über folgenden Befehl:
npm i yargs
das Paket wieder installiert. Danach meckert iobroker stop auch nciht mehr:
root@iobroker:/opt/iobroker# iobroker stop iobroker controller daemon is not running
also nochmal ein iobroker upgrade self:
root@iobroker:/opt/iobroker# iobroker upgrade self Update js-controller from @1.2.3 to @1.2.6 npm install iobroker.js-controller@1.2.6 --production --prefix "/opt/iobroker" (System call) npm WARN deprecated localhost.daplie.me-certificates@1.3.5: this package has been deprecated npm WARN optional Skipping failed optional dependency /iobroker.radar/noble/xpc-connection: npm WARN notsup Not compatible with your operating system or architecture: xpc-connection@0.1.4 npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/cliui/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/cross-spawn/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/execa/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/gauge/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/lru-cache/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/node-pre-gyp/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/tar-pack/package.json' npm ERR! Linux 4.1.18-v7+ npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "iobroker.js-controller@1.2.6" "--production" "--prefix" "/opt/iobroker" npm ERR! node v6.3.1 npm ERR! npm v3.10.3 npm ERR! path /opt/iobroker/node_modules/.staging/ansi-be95de54 npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall rename npm ERR! enoent ENOENT: no such file or directory, rename '/opt/iobroker/node_modules/.staging/ansi-be95de54' -> '/opt/iobroker/node_modules/npm/node_modules/ansi' npm ERR! enoent ENOENT: no such file or directory, rename '/opt/iobroker/node_modules/.staging/ansi-be95de54' -> '/opt/iobroker/node_modules/npm/node_modules/ansi' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent npm ERR! Please include the following file with any support request: npm ERR! /opt/iobroker/npm-debug.log host.iobroker Cannot install iobroker.js-controller@1.2.6: 254
-
mach zuerst ein update node v6.3.1 auf 6.12.x oder 6.13.x
-
Habe das gleiche Problem an einem von drei Systemen.
Alle 3 mit Jessie, an allen vor dem JS-Controller upgrade ein apt update & apt upgrade gemacht.
Alle drei mit
root@openmediavault /opt/iobroker > node -v v6.13.1 root@openmediavault /opt/iobroker > npm -v 3.10.10 root@openmediavault /opt/iobroker >
Auf den beiden Slave lief es ohne Probleme.
Der Master bringt das:
sudo iobroker upgrade self Update js-controller from @1.2.3 to @1.2.6 npm install iobroker.js-controller@1.2.6 --production --prefix "/opt/iobroker" (System call) npm WARN deprecated localhost.daplie.me-certificates@1.3.5: this package has been deprecated npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/iobroker.enigma2/package.json' npm WARN enoent ENOENT: no such file or directory, open '/opt/iobroker/node_modules/iobroker.vis-mywidgets/package.json' npm ERR! Linux 4.9.0-0.bpo.5-amd64 npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "install" "iobroker.js-controller@1.2.6" "--production" "--prefix" "/opt/iobroker" npm ERR! node v6.13.1 npm ERR! npm v3.10.10 npm ERR! path /opt/iobroker/node_modules/.staging/abbrev-bc1a4de2 npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall rename npm ERR! enoent ENOENT: no such file or directory, rename '/opt/iobroker/node_modules/.staging/abbrev-bc1a4de2' -> '/opt/iobroker/node_modules/npm/node_modules/abbrev' npm ERR! enoent ENOENT: no such file or directory, rename '/opt/iobroker/node_modules/.staging/abbrev-bc1a4de2' -> '/opt/iobroker/node_modules/npm/node_modules/abbrev' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent npm ERR! Please include the following file with any support request: npm ERR! /opt/iobroker/npm-debug.log host.openmediavault Cannot install iobroker.js-controller@1.2.6: 254 Cannot save /opt/iobroker/node_modules/iobroker.js-controller/lib/states/../../../../iobroker-data/states.json: Error: ENOENT: no such file or directory, open '/opt/iobroker/node_modules/iobroker.js-controller/lib/states/../../../../iobroker-data/states.json'
EDIT: hiermit gelöst
cd /opt/iobroker iobroker stop npm install iobroker.js-controller --production iobroker start
-
mach zuerst ein update node v6.3.1 auf 6.12.x oder 6.13.x `
Ich schaffe es leider nicht auf die neueste Version zu aktualisieren…ich glaube irgendetwas ist ganz vermurkst...
Ich bin auch irgendwann von nodejs 4.x auf 6.x gewechselt...vielleicht hat das damit zutun.
Ich werde wohl die SD Karte mit einem aktuellen Image bespielen, mit neuestem nodejs usw. und dann das Backup einspielen.
-
cd /opt/iobroker iobroker stop npm install iobroker.js-controller --production iobroker start ```` `
Hatte ich auch schon versucht…leider ohne Erfolg.
Dennoch danke für Eure Ideen.
-
Wie hast du denn versucht den Upgrade von Node zu machen?
Bei mir war das bei
apt update apt upgrade
Mit dabei
-
ich habe gestern ein Upgrade vom Node gemacht.
Habe jetzt:
node v6.13.1 npm v3.10.10
so bin ich vorgegangen.
iobroker stop sudo apt-get --purge remove node sudo apt-get --purge remove nodejs sudo apt-get autoremove curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash - sudo apt-get update && sudo apt-get upgrade sudo apt-get install -y build-essential libavahi-compat-libdnssd-dev libudev-dev nodejs cd /opt/iobroker sudo ./reinstall.sh iobroker start
Mit dem ./reinstall.sh dauerte es ewigkeiten…. Lässt sich Node irgendwie einfacher installieren? Vom Gefühl wurde alles erneut installiert. Dabei wollte ich nur den Node upgraden!
-
de reinstall würde ich erst dann ausführen wenn irgendwas nicht läuft
bzw bei ersionssprung von 4 auf 6 von 6 auf 8
-
Ich habe den Node Upgrade gestern auch gemacht.
Version von 4 auf 6…
da ich scheinbar keine Adapter nutze die mit 6 noch nicht klar kommen lief bei mir alles und reinstall.sh war bisher nicht notwendig.
Wenn du schon eine Node 6.x drauf hast sollte ein upgrade wie schon geschrieben mit
apt update apt upgrade
auf die aktuelle Node 6.x gehen.
War zumindest bei meinen zwei älteren Node 6 Systemen so.
-
Fragt mich nicht was ich gemacht habe. Ich dachte schon ich hab das ganze System zerschossen.
Irgendwann hab ich den raspi einfach neugestartet und dann habe ich gesehen, dass er plötzlich alle Adapter wieder neuinstalliert.
Nach 20-30 Minuten war er fertig und es läuft wieder….
js-controller mit 1.2.6
Mir ist das trotzdem sehr koscher. Ich werde am Wochenende den Raspi neu installieren mit aktuellsten Versionen und spiele das Backup wieder ein.
-
Na dann
Kannst du das bitte noch im Titel als [Gelöst] markieren.
-
Da es auch bei mir Probleme gab mit dem Update auf 1.2.6.
Dort wurden dann einfach einige Adapter nicht mehr gestartet oder einfach beendet habe ich nun nach der Anleitung hier die Node aktualisiert.
Nun läuft es auf 1.2.6 so wie es scheint, jedoch kann ich kein Update auf 1.2.7 machen dann bekomme ich diese Meldung.
` > Update js-controller from @1.2.6 to @1.2.7
NPM version: 5.6.0
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
NPM 5 is only supported starting with version 5.7.1!
Please use "npm install -g npm@4" to downgrade npm to 4.x or
use to install a supported version of npm 5!
You need to make sure to repeat this step after installing an update to NodeJS and/or npm
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! `
Ok dachte ich schau ich mal welche Version von NPM ich habe raus kam 3.10.10.
Dann habe ich der Anweisung im dortigen Text gefolgt aber ohne Erfolg.
Ich habe "npm install -g npm@>=5.7.1" ausgeführt aber das führte zu folgendem Fehler.
` > npm install -g npm@=>5.7.1
npm ERR! Linux 4.9.0-3-amd64
npm ERR! argv "/usr/local/bin/node" "/usr/bin/npm" "install" "-g" "npm@="
npm ERR! node v9.8.0
npm ERR! npm v3.10.10
npm ERR! code ETARGET
npm ERR! notarget No compatible version found: npm@=
npm ERR! notarget Valid install targets:
npm ERR! notarget 5.7.1, 5.7.0, 5.6.0, 5.5.1, 5.5.0, 5.4.2, 5.4.1, 5.4.0, 5.3.0, 5.2.0, 5.1.0, 5.0.4, 5.0.3, 5.0.2, 5.0.1, 5.0.0, 4.6.1, 4.6.0, 4.5.0, 4.4.4, 4.4.3, 4.4.2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2.2.0, 2.1.18, 2.1.17, 2.1.16, 2.1.15, 2.1.14, 2.1.13, 2.1.12, 2.1.11, 2.1.10, 2.1.9, 2.1.8, 2.1.7, 2.1.6, 2.1.5, 2.1.4, 2.1.3, 2.1.2, 2.1.1, 2.1.0, 2.0.2, 2.0.1, 2.0.0, 2.0.0-beta.3, 2.0.0-beta.2, 2.0.0-beta.1, 2.0.0-beta.0, 2.0.0-alpha-5, 2.0.0-alpha.7, 2.0.0-alpha.6.0, 2.0.0-alpha.6, 1.5.0-alpha-4, 1.5.0-alpha-3, 1.5.0-alpha-2, 1.5.0-alpha-1, 1.5.0-alpha-0, 1.4.29, 1.4.28, 1.4.27, 1.4.26, 1.4.25, 1.4.24, 1.4.23, 1.4.22, 1.4.21, 1.4.20, 1.4.19, 1.4.18, 1.4.17, 1.4.16, 1.4.15, 1.4.14, 1.4.13, 1.4.12, 1.4.11, 1.4.10, 1.4.9, 1.4.8, 1.4.7, 1.4.6, 1.4.5, 1.4.4, 1.4.3, 1.4.2, 1.4.1, 1.4.0, 1.3.26, 1.3.25, 1.3.24, 1.3.23, 1.3.22, 1.3.21, 1.3.20, 1.3.18, 1.3.17, 1.3.16, 1.3.15, 1.3.14, 1.3.13, 1.3.12, 1.3.11, 1.3.10, 1.3.9, 1.3.8, 1.3.7, 1.3.6, 1.3.5, 1.3.4, 1.3.2, 1.3.1, 1.3.0, 1.2.8000, 1.2.32, 1.2.31, 1.2.30, 1.2.28, 1.2.27, 1.2.25, 1.2.24, 1.2.23, 1.2.22, 1.2.21, 1.2.20, 1.2.19, 1.1.71, 1.1.70, 1.1.25
npm ERR! notarget
npm ERR! notarget This is most likely not a problem with npm itself.
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.
npm ERR! Please include the following file with any support request:
npm ERR! /home/io/npm-debug.log `
Hoffe ihr könnt mir da weiterhelfen.
Wie gesagt bisher scheint es mit der Versio 1.2.6 zu laufen aber wenn ich später noch updaten will ist es wohl unausweichlich die NPM upzudaten.
MFG Maggi
-
Moin!
Habe auf 2 Hosts keine Probleme gehabt und auf dem Raspi mit node8 ebenfalls die Warnmeldung.
Bei mir half:
npm i -g npm
(allerdings 2 mal…)
bis denne
Mr.Lee
-
Ich habe "npm install -g npm@>=5.7.1" ausgeführt aber das führte zu folgendem Fehler.
npm install -g npm@=>5.7.1 ```` `
Ne hast du nicht. Du hast > und = vertauscht
">=" ist richtig, "=>" falsch!
-
Ich Dusel, danke AlCalzone.
Wieder selbst zu schnell gewesen und nicht richtig gelesen.
MFG Maggi
-
Moin!
Habe auf 2 Hosts keine Probleme gehabt und auf dem Raspi mit node8 ebenfalls die Warnmeldung.
Bei mir half:
npm i -g npm
(allerdings 2 mal…)
bis denne
Mr.Lee `
Der Tipp war Gold Wert.
Nachdem ich gestern auf meinem Host auf 1.2.6 bin heute dann auf 1.2.7 aber wie zu erwarten nicht ohne Probleme.
Letztendlich bin ich dann auf diese Zeile aufmerksam geworden nachdem ich einmal````
npm -i -g npmnpm WARN npm@2.15.12 had bundled packages that do not match the required version(s). They have been replaced with non-bundled versions.
root@openmediavault /opt/iobroker > npm install iobroker.js-controller --production
npm WARN deprecated localhost.daplie.me-certificates@1.3.5: this package has been deprecated
npm WARN read-shrinkwrap This version of npm is compatible with lockfileVersion@1, but npm-shrinkwrap.json was generated for lockfileVersion@0. I'll try to do my best with it!
npm WARN npm@2.15.12 had bundled packages that do not match the required version(s). They have been replaced with non-bundled versions.
npm WARN winston-daily-rotate-file@1.7.2 requires a peer of winston@2.x but none is installed. You must install peer dependencies yourself.npm ERR! path /opt/iobroker/node_modules/npm/node_modules/abbrev
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall rename
npm ERR! enoent ENOENT: no such file or directory, rename '/opt/iobroker/node_modules/npm/node_modules/abbrev' -> '/opt/iobroker/node_modules/npm/node_modules/.abbrev.DELETE'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoentnpm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-03-09T19_31_13_963Z-debug.logObwohl ich bei der Abfrage nach Node und NPM wie auch im log zu sehen diese Versionen hatte:
npm ERR! node v6.13.1
npm ERR! npm v3.10.10Wird scheinbar bei der JS-Controller installation auf eine "globale" NPM installation zurück gegriffen!? Interessanter weise habe ich jetzt folgende Versionen:
root@openmediavault /opt/iobroker > npm -v
5.7.1
root@openmediavault /opt/iobroker > node -v
v6.13.1Wer weiß was das wieder für Probleme verursacht… :cry: EDIT: 22 Instanzen bleiben auf ROT Ich habe keine Lust mehr :roll:
-
Obwohl ich bei der Abfrage nach Node und NPM wie auch im log zu sehen diese Versionen hatte:
npm ERR! node v6.13.1 npm ERR! npm v3.10.10
Wird scheinbar bei der JS-Controller installation auf eine "globale" NPM installation zurück gegriffen!?
Interessanter weise habe ich jetzt folgende Versionen:
root@openmediavault /opt/iobroker > npm -v 5.7.1 root@openmediavault /opt/iobroker > node -v v6.13.1 ```` `
Hast du 2 NPM mit unterschiedlichen Versionen parallel installiert? Was gibt
which npm
aus?
> Wird scheinbar bei der JS-Controller installation auf eine "globale" NPM installation zurück gegriffen!?
npm sollte IMMER global installiert sein -
Guten Morgen,
bei der Installation von NPM und Node habe ich mich bisher immer an diese Anleitung gehalten:
http://www.iobroker.net/docu/?page_id=5106&lang=de
Abfrage ergibt das:
root@openmediavault ~ > which npm /usr/bin/npm
Was bedeutet das jetzt für mich?
Sollte ich passend zu NPM5 auch Node upgraden?
Danke
-
Ich wundere mich nur, dass du in deinen Logs sowohl 3.10.10 (von npm -v) als auch 5.7.1 (von js-controller erkant) hast.
Die Ausgabe stimmt mit meiner überein, das sagt erst mal nix.
Was ich gerade festgestellt habe…
Der empfohlene Befehl zum npm-Update hat einen Fehler. Es muss
sudo npm i -g "npm@>=5.7.1"
heißen (mit Anführungszeichen!), NICHT
sudo npm i -g npm@>=5.7.1
–-
Aber du bist ja schon einen Schritt weiter:
> EDIT: 22 Instanzen bleiben auf ROT
Was sagt der ioBroker-Log?