Main question
I see following line in netstat. Does it means this socket doesn't belong to any process?
#>netstat -tpn|grep TIME_WAIT| head -1
tcp 0 0 ::ffff:127.0.0.1:5555 ::ffff:127.0.0.1:45845 TIME_WAIT -
Extra question
In an multithread program can thread responsible for dealing with socket be already gone? (It's NOT in 'sleep' or 'uninterpretable sleep')?
Best Answer
No process owns that socket, the kernel keeps it around for possible cleanup. This answer and this IBM article explain more about the TIME_WAIT state.