[patch 0/3] Live PIDs with deleted files by /dev/PID/mem

Mark Wielaard mjw at redhat.com
Tue Mar 4 10:40:21 UTC 2014


On Mon, 2014-03-03 at 16:48 +0100, Mark Wielaard wrote:
> Lets see how to combine the approaches most effectively.
> I'll try and cleanup my patch to linux-proc-maps.c to make it possible
> to use elf_from_remote_memory for "(deleted)" files to make it easier to
> test things out.

Attached is a patch that does this. I'll push it to the mjw/pending
branch. For now only tested on a RHEL6 x86_64 2.6.32 kernel. It does
seem to work at least for that setup. I'll try on some other setups
later.

$ src/stack -1 -m -p `pidof firefox`
TID 25950:
#0  0x0000003ea8cdf343 __poll - /lib64/libc.so.6
#1  0x00007f16813680dc PollWrapper(_GPollFD*, unsigned int, int) - /usr/lib64/firefox/libxul.so (deleted)
#2  0x0000003eb3843ac9 g_main_context_iterate - /lib64/libglib-2.0.so.0.2600.1
#3  0x0000003eb3843f1c g_main_context_iteration - /lib64/libglib-2.0.so.0.2600.1
#4  0x00007f1681367f39 nsAppShell::ProcessNextNativeEvent(bool) - /usr/lib64/firefox/libxul.so (deleted)
#5  0x00007f168138e711 nsBaseAppShell::DoProcessNextNativeEvent(bool, unsigned int) - /usr/lib64/firefox/libxul.so (deleted)
#6  0x00007f168138e890 nsBaseAppShell::OnProcessNextEvent(nsIThreadInternal*, bool, unsigned int) - /usr/lib64/firefox/libxul.so (deleted)
#7  0x00007f1681762240 nsThread::ProcessNextEvent(bool, bool*) - /usr/lib64/firefox/libxul.so (deleted)
#8  0x00007f16817319bc NS_ProcessNextEvent(nsIThread*, bool) - /usr/lib64/firefox/libxul.so (deleted)
#9  0x00007f16813f10b3 mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate*) - /usr/lib64/firefox/libxul.so (deleted)
#10 0x00007f1681788cb2 MessageLoop::Run() - /usr/lib64/firefox/libxul.so (deleted)
#11 0x00007f168138e9c1 nsBaseAppShell::Run() - /usr/lib64/firefox/libxul.so (deleted)
#12 0x00007f1681245e42 nsAppStartup::Run() - /usr/lib64/firefox/libxul.so (deleted)
#13 0x00007f168085aeee XREMain::XRE_mainRun() - /usr/lib64/firefox/libxul.so (deleted)
#14 0x00007f168085eb6e XREMain::XRE_main(int, char**, nsXREAppData const*) - /usr/lib64/firefox/libxul.so (deleted)
#15 0x00007f168085edc6 XRE_main - /usr/lib64/firefox/libxul.so (deleted)
#16 0x0000000000403bf6 do_main(int, char**, nsIFile*) - /usr/lib64/firefox/firefox (deleted)
#17 0x0000000000403d3b main - /usr/lib64/firefox/firefox (deleted)
#18 0x0000003ea8c1ed1d __libc_start_main - /lib64/libc.so.6
#19 0x0000000000403469 _start - /usr/lib64/firefox/firefox (deleted)

Cheers,

Mark
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-libdwfl-dwfl_linux_proc_find_elf-use-elf_from_remote.patch
Type: text/x-patch
Size: 10941 bytes
Desc: not available
URL: <https://lists.fedorahosted.org/pipermail/elfutils-devel/attachments/20140304/a9f61055/attachment-0001.bin>


More information about the elfutils-devel mailing list