[Question] Supporting target-root path resolution in containerized applications (dwfl_linux_proc_find_elf)
pramod kumbhar
pramod.s.kumbhar@gmail.com
Mon Aug 10 09:26:07 GMT 2026
Hello,
Apologies for the previous registration related email noise, I used wrong
email address.
I am checking tools such as PyStack (github.com/bloomberg/pystack) with
containerized applications (e.g. Enroot). The tool uses libdwfl and ine
issue I ran into appears to be in the
dwfl_linux_proc_report/dwfl_linux_proc_find_elf path for live process
inspection. As I understand it, dwfl_linux_proc_report records absolute
module paths from /proc/<pid>/maps, and dwfl_linux_proc_find_elf then tries
to open those paths directly from the host filesystem. For containerized
targets, there are two possible issues:
- the host cannot open the mapped path at all, or
- the host can open the same absolute pathname, but it resolves to the
wrong file from the host filesystem.
I was wondering whether this scenario should be supported in libdwfl. One
possible approach would be for normal absolute paths coming from
dwfl_linux_proc_report, resolve them through /proc/<pid>/root/<mapped-path>
so lookup follows the target process root for live proc-maps modules.
Does this seem like the right direction for supporting this container
scenario in `libdwfl`? Or are there other caveats around container-related
process inspection that should be considered here? (and hence better to
have downstream applications to take care of this?)
Thanks,
Pramod
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://sourceware.org/pipermail/elfutils-devel/attachments/20260810/147e6a26/attachment.htm>
More information about the Elfutils-devel
mailing list