Node.js express NPM start error, Exit-Status 8
ich gerade installiert node.js auf Amazon EC2, und alles war in Ordnung arbeiten, dann habe ich aufgehört, die server, und habe versucht ihn neu zu starten, und jetzt bin ich immer dieser Fehler:
events.js:72
throw er; //Unhandled 'error' event
^
Error: listen EADDRINUSE
at errnoException (net.js:904:11)
at Server._listen2 (net.js:1042:14)
at listen (net.js:1064:10)
at Server.listen (net.js:1138:5)
at Object.<anonymous> (/home/CloudChat/server.js:34:24)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Function.Module.runMain (module.js:497:10)
npm ERR! application-name@0.0.1 start: `node server.js`
npm ERR! Exit status 8
npm ERR!
npm ERR! Failed at the application-name@0.0.1 start script.
npm ERR! This is most likely a problem with the application-name package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node server.js
npm ERR! You can get their info via:
npm ERR! npm owner ls application-name
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 3.4.73-64.112.amzn1.x86_64
npm ERR! command "node" "/usr/local/bin/npm" "start"
npm ERR! cwd /home/CloudChat
npm ERR! node -v v0.10.26
npm ERR! npm -v 1.4.4
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/CloudChat/npm-debug.log
npm ERR! not ok code 0
npm-debug.Protokoll enthält:
0 info it worked if it ends with ok
1 verbose cli [ 'node', '/usr/local/bin/npm', 'start' ]
2 info using npm@1.4.4
3 info using node@v0.10.26
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info prestart application-name@0.0.1
6 info start application-name@0.0.1
7 verbose unsafe-perm in lifecycle true
8 info application-name@0.0.1 Failed to exec start script
9 error application-name@0.0.1 start: `node server.js`
9 error Exit status 8
10 error Failed at the application-name@0.0.1 start script.
10 error This is most likely a problem with the application-name package,
10 error not with npm itself.
10 error Tell the author that this fails on your system:
10 error node server.js
10 error You can get their info via:
10 error npm owner ls application-name
10 error There is likely additional logging output above.
11 error System Linux 3.4.73-64.112.amzn1.x86_64
12 error command "node" "/usr/local/bin/npm" "start"
13 error cwd /home/CloudChat
14 error node -v v0.10.26
15 error npm -v 1.4.4
16 error code ELIFECYCLE
17 verbose exit [ 1, true ]
Alles, was ich Tat, war umbenennen app.js zu server.js ich wechselte auch im Paket.json, aber es funktionierte nach rechts, bis ich stoppte den server?
**EDIT**
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address Stat e
tcp 0 0 *:webcache *:* LIST EN
tcp 0 0 *:ssh *:* LIST EN
tcp 0 0 *:hbci *:* LIST EN
tcp 0 0 localhost:smtp *:* LIST EN
tcp 0 320 ip-172-31-34-214.us-wes:ssh 78-143-78-51-customer.:6639 ESTA BLISHED
tcp 0 0 ip-172-31-34-214.us-wes:ssh 78-143-78-51-customer.:8846 ESTA BLISHED
tcp 0 0 ip-172-31-34-214.us-wes:ssh 78-143-78-51-customer.:8212 ESTA BLISHED
tcp 429 0 ip-172-31-34-214.u:webcache 78-143-78-51-customer.:8048 CLOS E_WAIT
tcp 0 0 ip-172-31-34-214.us-wes:ssh 78-143-78-51-custom:fs-mgmt ESTA BLISHED
tcp 0 0 *:ssh *:* LIST EN
udp 0 0 *:bootpc *:*
udp 0 0 ip-172-31-34-214.us-west:ntp *:*
udp 0 0 localhost:ntp *:*
udp 0 0 *:ntp *:*
Active UNIX domain sockets (servers and established)
Proto RefCnt Flags Type State I-Node Path
unix 2 [ ACC ] STREAM LISTENING 6526 /var/run/dbus/system_bu s_socket
unix 2 [ ACC ] STREAM LISTENING 5537 @/com/ubuntu/upstart
unix 12 [ ] DGRAM 6469 /dev/log
unix 2 [ ACC ] SEQPACKET LISTENING 5611 @/org/kernel/udev/udevd
unix 3 [ ] STREAM CONNECTED 52862
unix 3 [ ] STREAM CONNECTED 52861
unix 2 [ ] DGRAM 52858
unix 2 [ ] DGRAM 44741
unix 2 [ ] DGRAM 44722
unix 3 [ ] STREAM CONNECTED 41225
unix 3 [ ] STREAM CONNECTED 41224
unix 2 [ ] DGRAM 41221
unix 3 [ ] STREAM CONNECTED 40807
unix 3 [ ] STREAM CONNECTED 40806
unix 2 [ ] DGRAM 40803
unix 2 [ ] DGRAM 40121
unix 3 [ ] STREAM CONNECTED 38240
unix 3 [ ] STREAM CONNECTED 38239
unix 2 [ ] DGRAM 38236
unix 2 [ ] DGRAM 11231
unix 2 [ ] DGRAM 7465
unix 2 [ ] DGRAM 7446
unix 2 [ ] DGRAM 7428
unix 2 [ ] DGRAM 7347
unix 3 [ ] STREAM CONNECTED 6535 /var/run/dbus/system_bu s_socket
unix 3 [ ] STREAM CONNECTED 6534
unix 3 [ ] STREAM CONNECTED 6530
unix 3 [ ] STREAM CONNECTED 6529
unix 3 [ ] DGRAM 5627
unix 3 [ ] DGRAM 5626
[root@ip-172-31-34-214 CloudChat]#
Ändern Sie es zurück?
Noch immer die Fehler
Noch immer die Fehler
InformationsquelleAutor Ivan Ristic | 2014-02-22
Du musst angemeldet sein, um einen Kommentar abzugeben.
Das problem ist, dass der port bereits belegt ist oder Sie nicht über die Berechtigung zum binden, port.
Ändern Sie den listening-port des HTTP-Servers oder läuft der server als root mit
sudo node app.js
haben Sie überprüft, was ist mit diesem port?
netstat -a
Ich habe die app auf port 8080 lauschen, die Umleitung auf port 80, der port scheint nicht in Benutzung zu sein, habe ich den output auf die Frage
sudo Knoten app.js gibt mir den gleichen Fehler
InformationsquelleAutor Pedro Nasser
Hier ist, wie Herunterfahren express, wenn Sie geschehen, um die gleiche situation wie ich:
InformationsquelleAutor Ivan Ristic
Mit Express 4 das start-script befindet sich in ./bin/www
Wenn Sie haben diese Fehler (wie mich) einfach zu Bearbeiten und ersetzen
durch
InformationsquelleAutor MaximeK