Vaidesh Shankar
Vaidesh Shankar

Reputation: 101

events.js 183 error in node js

While working with node.js as a beginner, I was facing a trouble with the code i've made for displaying the different parts of my url on the localhost:8080. Check the code mentioned below, correct me if any error is found:- code of the node.js file

Corresponding to the above mentioned code i was getting this error. enter image description here This is not only happening for one code but with every code that i try to make. Please provide an appropriate solution.

Upvotes: 0

Views: 5340

Answers (3)

Heavytik
Heavytik

Reputation: 1

With this command you can see process names with ip and port (linux/ubuntu).

sudo lsof -i -P -n

Then you can kill process with

kill <ip>

Upvotes: 0

node_modules
node_modules

Reputation: 4925

The error code EADDRINUSE indicates that the port you are using for your NodeJS application already is in use. Therefore your NodeJS application can't connect to this port anymore. Close all applications that is using that port or use a port that is not in use.

Check all running node processes by using the command in Windows:

tasklist

And kill the process by using:

taskkill /F /PID <ID of process>

Or kill the entire node.exe process by using the command:

taskkill /F /IM node.exe

If you are using linux, you can try the following:

ps -ef | grep node
sudo kill -9 <PID>

Upvotes: 6

StefanBD
StefanBD

Reputation: 354

i know this error when the port is already used, try another port or kill the node process

Upvotes: 0

Related Questions