Understanding the timestamp of ltrace
Pavel Kazlenka
panya_qwert at tut.by
Wed Jul 17 15:59:23 UTC 2013
Hi Franck,
Please find some answers in-lined:
On 07/15/2013 09:15 PM, Franck Youssef wrote:
> Hello,
>
> I am trying to generate log traces of err_xact.count myself, using the polygraph-ltrace --objects.
>
> I would like to sample these values with a sampling interval of 20 seconds.
>
> To my understanding, that should be feasible with the --time_unit option. However, when running ltrace with different --time_unit values] I always obtain the same output.
> Furthermore, when printing the 'time' object using --time_unit 1s, I obtain some kind of a funny timestamp prefixed with a dash: "-2147483620.50" (= Fri Dec 13 21:46:19 MET 1901 using date -d @…).
This seems like a bug. What polygraph version do you use?
> What does that timestamp mean, how could I obtain a "natural" unix timestamp and how could I modify the sampling interval?
You could modify sampling interval using '--win_len' option. Do not use
'--time_unit' option if you want unix timestamps.
e.g.
$ polygraph-ltrace --objects time, err_xact.count --win_len 20sec <lo
> Best,
> Franck
>
Best wishes,
Pavel
More information about the Users
mailing list