Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

PID exists in netstat but does not exist in task manager

I have discovered a running process with PID 26376 listening on port 9001 and 9002 as when I try to run my program(as a service) which binds to that port it fails.

But when I try to kill it using taskkill /PID it says that the process 26376 is not found. Similarly when I try to find the process in task manager with "Show processes from all users" selected, I couldn't find it anywhere.

Can anyone explain this? Is it a defunct zombie process? I suspect that the process listening on that port is a previous instance of my program running but what could have caused this?

EDIT: Sysinternals TCPView shows the process as non-existent. Sysinternals Process Explorer does not show the process. Tasklist does not show the process.

like image 319
shawn Avatar asked Mar 05 '13 06:03

shawn


People also ask

How do I find PID process details?

Task Manager can be opened in a number of ways, but the simplest is to select Ctrl+Alt+Delete, and then select Task Manager. In Windows, first click More details to expand the information displayed. From the Processes tab, select Details to see the process ID listed in the PID column.

What is PID in Services Task Manager?

Short for process identifier, a PID is a unique number that identifies each running processes in an operating system, such as Linux, Unix, macOS, and Microsoft Windows. The output below shows a few of the processes running in Windows and their associated PIDs listed in the PID column.

What is PID in netstat command?

The Netstat.exe command has a switch, that can display the process identifier (PID) that is associated with each connection to identify port conflicts. This information can be used to determine which process (program) listens on a given port.

How do I show PID in Windows?

How to get PID using Task Manager. Press Ctrl+Shift+Esc on the keyboard. Go to the Processes tab. Right-click the header of the table and select PID in the context menu.


2 Answers

You don't need Task Manager for tracking this. Just run netstat -b which will display the exe associated with the PID..

like image 69
Parth Mody Avatar answered Oct 07 '22 09:10

Parth Mody


Well, in my case killing all the conhost.exe instances owned by the same user as the initial process released the port.

like image 28
mfck Avatar answered Oct 07 '22 09:10

mfck