Error: listen EADDRINUSE


Hi there!

My workspace:

This is my app.js:

var express = require("express");
var app = express();
app.get("/", function(req, res){
app.get("/fallinlovewith/:thing", function(req, res){
    var thing = req.params.thing;
    res.render("love.ejs", {thingVar: thing});
app.listen(process.env.PORT, process.env.IP, function(){
    console.log("Server is listening!!!");

I start the server:

antalmega:~/workspace/MoreExpress/EJSDemo $ node app.js
Server is listening!!!

But I can’t see the preview. If I click Run:

Your code is running at
Important: use process.env.PORT as the port and process.env.IP as the host in your scripts!
Debugger listening on [::]:15454
      throw er; // Unhandled 'error' event
Error: listen EADDRINUSE
    at Object.exports._errnoException (util.js:1020:11)
    at exports._exceptionWithHostPort (util.js:1043:20)
    at Server._listen2 (net.js:1258:14)
    at listen (net.js:1294:10)
    at net.js:1404:9
    at _combinedTickCallback (internal/process/next_tick.js:83:11)
    at process._tickCallback (internal/process/next_tick.js:104:9)
    at Timeout.Module.runMain [as _onTimeout] (module.js:606:11)
    at ontimeout (timers.js:386:14)
    at tryOnTimeout (timers.js:250:5)
Process exited with code: 1

I tried:

antalmega:~/workspace/MoreExpress/EJSDemo $ killall node
node: no process found
antalmega:~/workspace/MoreExpress/EJSDemo $ 

And restarted my workspace several times with the same result… any idea?


Working now!

I don’t know what was doing wrong. I didn’t changed anything apparently… But I finally can go on!