What Port is that Service using


What Port is that Service using
netstat.exe –a –n –o


  • -a: listing of all connections and listening ports
  • -n: display address and port numbers in numerical form
  • -o: display the owning PID associated with each connection
Then find PID value using tasklist.exe.
Example to find pid for SVhost server running in tasklist.

tasklist /svc /FI "PID eq 4784"

tasklist /SVC /FI "IMAGENAME eq svchost.exe"

Get-Process -Id (Get-NetTCPConnection -LocalPort 443).OwningProcess

We can view same in Process Monitor (resmon.exe)


Now open the task manager
Go to “View” and “Select Columns”


Put a Tick mark on “PID (Process identifier)”

Comments

Popular posts from this blog

Troubleshooting Netlogon Error Codes

Service Principal Names (SPNs) SetSPN Syntax (Setspn.exe)

Troubleshooting SCEP certificate profile deployment to Android devices in Microsoft Intune