I have a process where multiple threads open multiple socket connection. I want to view this information and map what thread has opened which socket port.
lsof -i
Once the file descriptor is open, it "belongs" equally to all the threads in the process (as far as the kernel is concerned), you can't see which thread opened it.