Actions
Bug #1245
closedfile descriptor statedump should iterate over all processes/threads, not just processes
Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
03/10/2020
Due date:
% Done:
100%
Estimated time:
Description
If we look at the output of lsof, we observe that it prints file descriptors for all processes/threads, not just processes.
Currently the LTTng-modules statedump simply iterates over all processes in the system and assumes all threads share the same file descriptor table, which is only true if threads were created with clone CLONE_FILES.
Directly invoking clone without the CLONE_FILES creates threads which belong to the same process, but have their own file descriptor table.
Therefore, model-wise, we cannot assume that all threads in a process have the same fd table content.
Fixing this would involve changing the statedump to iterate on all processes/threads, and dump the fd tables for each tid.
Actions