所以我想建立一個賭博網站,並希望用nodejs檢查價格,但這不是真的工作..任何人都可以幫助我嗎?EADDRINUSE錯誤nodejs
每次我嘗試網站的NodeJS這個彈出:
[email protected]:/var/www/html/Bot/BOT# nodejs site
[2017-05-04 14:50:45.177] [TRACE] [default] - Strange error
[2017-05-04 14:50:45.179] [DEBUG] [default] - { [Error: listen EADDRINUSE] code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen' }
Error: listen EADDRINUSE
at errnoException (net.js:901:11)
at Server._listen2 (net.js:1039:14)
at listen (net.js:1061:10)
at Server.listen (net.js:1135:5)
at Server.listen.Server.attach (/var/www/html/Bot/BOT/node_modules/socket.io/lib/index.js:228:9)
at new Server (/var/www/html/Bot/BOT/node_modules/socket.io/lib/index.js:52:17)
at Server (/var/www/html/Bot/BOT/node_modules/socket.io/lib/index.js:40:41)
at Object.<anonymous> (/var/www/html/Bot/BOT/site.js:3:30)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
[2017-05-04 14:50:45.195] [INFO] [default] - DB Connection ID: 184
[2017-05-04 14:50:45.197] [INFO] [default] - DB Connection ID: 185
[2017-05-04 14:50:45.197] [INFO] [default] - DB Connection ID: 186
[2017-05-04 14:50:45.198] [INFO] [default] - DB Connection ID: 187
[2017-05-04 14:50:45.199] [TRACE] [default] - Roll 1
[2017-05-04 14:50:45.200] [TRACE] [default] - Sucesfully updated history
[2017-05-04 14:50:45.200] [WARN] [default] - Loaded hash594b7214a8e846d02a0187421148940170d2fcf18199f81721c082ca84d93808
[2017-05-04 14:50:45.539] [WARN] [default] - Loaded fresh prices
[2017-05-04 14:50:45.548] [WARN] [default] - Prices loaded from cache
[2017-05-04 14:50:48.174] [TRACE] [default] - Strange error
[2017-05-04 14:50:48.174] [DEBUG] [default] - { [Error: listen EADDRINUSE] code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen' }
Error: listen EADDRINUSE
at errnoException (net.js:901:11)
at Server._listen2 (net.js:1039:14)
at listen (net.js:1061:10)
at Server.listen (net.js:1135:5)
at Server.listen.Server.attach (/var/www/html/Bot/BOT/node_modules/socket.io/lib/index.js:228:9)
at null._onTimeout (/var/www/html/Bot/BOT/site.js:618:29)
at Timer.listOnTimeout [as ontimeout] (timers.js:110:15)
也許你正試圖訪問一個已經在使用的端口? –
錯誤:地址在使用中。 –