johnlemonse / homebridge-telldus

36 stars 22 forks source link

Error: listen EADDRINUSE :::51826 #48

Closed SubZane closed 6 years ago

SubZane commented 6 years ago

Any idea what this can be about? (I'm not 100% sure if this is related to your plugin) but I'm only using it in the config

My config: https://gist.github.com/SubZane/c559ddf5e5d49d0ce9ffcadf8cb9cae5

events.js:163 throw er; // Unhandled 'error' event ^

Error: listen EADDRINUSE :::51826 at Object.exports._errnoException (util.js:1050:11) at exports._exceptionWithHostPort (util.js:1073:20) at Server.setupListenHandle [as _listen2] (net.js:1259:14) at listenInCluster (net.js:1307:12) at Server.listen (net.js:1406:7) at EventedHTTPServer.listen (/usr/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/util/eventedhttp.js:60:19) at HAPServer.listen (/usr/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/HAPServer.js:158:20) at Bridge.Accessory.publish (/usr/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/Accessory.js:486:16) at Server._publish (/usr/lib/node_modules/homebridge/lib/server.js:114:16) at Server. (/usr/lib/node_modules/homebridge/lib/server.js:372:14) at /usr/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/util/once.js:16:19 at TelldusLive.loginAsync.then.then.accessories (/usr/lib/node_modules/homebridge-telldus/index.js:121:6) at tryCatcher (/usr/lib/node_modules/homebridge-telldus/node_modules/bluebird/js/release/util.js:16:23) at Promise._settlePromiseFromHandler (/usr/lib/node_modules/homebridge-telldus/node_modules/bluebird/js/release/promise.js:512:31) at Promise._settlePromise (/usr/lib/node_modules/homebridge-telldus/node_modules/bluebird/js/release/promise.js:569:18) at Promise._settlePromise0 (/usr/lib/node_modules/homebridge-telldus/node_modules/bluebird/js/release/promise.js:614:10)

SubZane commented 6 years ago

I just learned that EADDRINUSE means that homebridge is already running on the same address.

thifabri commented 6 years ago

Hi all,

I have the same problem here and i have no idea to solve it. I use just one instance and I don't have process to start the homebridge.

I can execute the homebridge perfectly only one time. If I need stop and restart the homebridge occurred this issue. So, I need reboot the RBP and start the service again.

How can I solve it?

Best, Thiago

SubZane commented 6 years ago

Do you run homebridge as a system service?

What does it say when you type "systemctl status homebridge?

Can you shutdown the service with sudo systemctl stop homebridge?