[lttng-dev] Odd behaviour of lttng 2.0 kernel event listing

David Goulet david.goulet at polymtl.ca
Mon Jan 23 17:42:34 EST 2012


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

That's very interesting.

Quick fix, let see if it works:

diff --git a/src/common/sessiond-comm/sessiond-comm.c
b/src/common/sessiond-comm/sessiond-comm.c
index 03e8931..106041f 100644
- --- a/src/common/sessiond-comm/sessiond-comm.c
+++ b/src/common/sessiond-comm/sessiond-comm.c
@@ -257,7 +257,7 @@ ssize_t lttcomm_recv_unix_sock(int sock, void *buf, size_t len)
        msg.msg_iov = iov;
        msg.msg_iovlen = 1;

- -       ret = recvmsg(sock, &msg, 0);
+       ret = recvmsg(sock, &msg, MSG_WAITALL);
        if (ret < 0) {
                perror("recvmsg");
        }

Thanks!

Getting there :)

David

On 12-01-23 05:37 PM, Thibault, Daniel wrote:
>    I've narrowed it down to lttng-ctl.ask_sessiond(): the first recv_data_sessiond() call expects 16 bytes (sizeof(llm)) and gets 16 bytes.  llm.data_size holds the payload size (in bytes), which is what the second recv_data_sessiond() call expects...But it receives only 15 984 bytes of the expected 41 208.  The problem is that ask_sessiond() then reports the asked-for size as what it returned, without checking if they match.  15 984 bytes is 19 event records and 78% of a 20th record, which is exactly what we see in the session log (events 21 onward are blank).
> 
> Daniel U. Thibault
> R & D pour la défense Canada - Valcartier (RDDC Valcartier) / Defence R&D Canada - Valcartier (DRDC Valcartier)
> Système de systèmes (SdS) / System of Systems (SoS)
> Solutions informatiques et expérimentations (SIE) / Computing Solutions and Experimentations (CSE)
> 2459 Boul. Pie XI Nord
> Québec, QC  G3J 1X5
> CANADA
> Vox : (418) 844-4000 x4245
> Fax : (418) 844-4538
> NAC: 918V QSDJ
> Gouvernement du Canada / Government of Canada
> <http://www.valcartier.drdc-rddc.gc.ca/>
> 
> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
> 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)

iQEcBAEBAgAGBQJPHeJaAAoJEELoaioR9I02QxwIAJvUFBOatrFrh+jFu7SW032U
kZXgcnIlWn8u85Rz8D65n2lXH18+BsEEHuNFRNhb8/XxpWuZ718RHXQL0FTh0U10
NLHf55w0gDkywcw5JQRXjri2JuGEYh8TegKsZySbXI14CSZ4dKCOIMfFGzxBciBU
tGNVYjsxwbYPWukRTSPf0fmxnlCwcS8H8OL0u0zBqo6pn9oSR3mbo/WoVWZ16Bci
iHbKwb7WGbE07fF57iKr3srRBcg4qhDb76FlAIpcYOG7X5cNRnHgGcI7pYWbf2kC
PjIUQq/0bqm8GYuaUMyE53gFJSfDEk96eEydRI4ELLUtANKNmK4se9zQ0mPv+Fs=
=wDI/
-----END PGP SIGNATURE-----



More information about the lttng-dev mailing list