step 1: first check network connectivity using ping
step 3: kill process which is using port 12345
kill -9 $(lsof -t -i:"Port Number") kill -9 $(lsof -t -i:"12345")
# get the PID of the process sudo lsof -i:3000 # use the PID from above command and stop the process sudo kill PID
Some times the process does not terminate by simply using kill. Use -9 flag to force stop the process as sudo kill -9 PID
NOW,it is acessible
what do you mean by port are listening or established.
Find a Process That Is Using a Particular Port*(IMP).
what do you mean by local and foreighn address.
syntax to list All Ports and Connections,List All TCP Ports,List All UDP Ports,List Only TCP or UDP Listening Ports,Display statistics for all ports regardless of the protocol,Statistics for UDP/TCP Ports.
Display Numerical Addresses, Host Addresses, Port Numbers.
Display PID to specific port connection .
how to print netstat information every second.
how to List All netstat Commands
Show Specific Connections Only
Show Active TCP Connections and Process Identifiers