[lttng-dev] Problem in Tracing C Program

MMM e.morovati at yahoo.com
Thu Nov 30 17:51:20 UTC 2017


 Dear Julien,
Thanks for your response. Is the mentioned task easier in Java or C program?indeed, I think it can be easier in Java program. If it is true, I can switch to Java language.
    On Thursday, November 30, 2017, 7:15:21 PM GMT+3:30, Julien Desfossez <jdesfossez at efficios.com> wrote:  
 
 On 2017-11-30 10:13 AM, MMM via lttng-dev wrote:
> Dear Users,
> 
> I have posted a couple of email about my problem in the past, while
> nobody response those. It may be true that my question is amateurish,
> but due to the fact that I am a beginner, I can not find the sufficient
> document for solving my problem. I am going to trace a C program that
> read from a file and show the ratio of reads from page cache vs reads
> from disk. I read document of LTTng website, but I can not find
> appropriate explanation for this task. I just need a simple guidance to
> show me the right way for doing it. Could you please help me.
> 
> Regards,
> Mehdi.

Hi,

This is a really non-trivial task to do. Basically, you need to
distinguish the read() syscalls that lead to FS/disk access with the
ones that don't (for the same FD).
The main difficulty is to make the link between the syscall and the
lower-level events and I am not sure we have all the data needed to
establish this link from the payload of the events we have (something
like FD -> FS inode -> block).

I added Houssem to this thread because I think I remember he did some
work around that, he may have more information.

Julien  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.lttng.org/pipermail/lttng-dev/attachments/20171130/db2a665c/attachment.html>


More information about the lttng-dev mailing list