Namespace fd easily exhausts ulimit
- Dominant language
- C
- Stars
- 22.7k
- Forks
- 4.1k
- Avg merge
- 10d 4h
- Merged PRs (30d)
- 3
Description
A ProcMountNS basically exists for every process we've traced. Their fds are not reused due to the underlying ebpf::FileDesc while we can. This makes the bcc's fd number > the # of processes we look at, which can be many in extreme cases.
I think we can share the mnt namespace fds based on their actual mnt ns inode, with a reference count.
Any objections?
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by locating the ProcMountNS implementation and its use of ebpf::FileDesc. Trace how mount-namespace inode values are represented and how descriptors are retained across processes. Done means mount namespace descriptors are shared by inode with reference counting, preventing descriptor growth with the number of traced processes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, linux
- Domain
- operating-systems, performance
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100