Menu

#20 Followforks, output file and summary aren't compatible

None
closed
nobody
None
5
2018-04-08
2006-04-01
Larry Lile
No

Okay, I know this is a bit pathological, but it's
useful and works as expected without -o.

strace -c, will produce a summary for the parent
process, excluding forked children.

strace -c -ff, will produce a summary for the parent
and children combined.

strace -c -o <foo> places the summary output in <foo>
for the parent, excluding children.

strace -c -ff -o <foo> creates <foo> and <foo>.pid for
the parent and children, but they are all empty. This
behaviour doesn't follow the established pattern, and
besides a buch of empty files aren't all that helpful.

This patch will produce the same output as strace -c
-ff, but the output will go to the file specified by
-o, it could be easily argued that it should be by
.pid, but the math doesn't really work and it would
require some serious work to fix. It also wouldn't
match the output of the non -o execution.

Anyway, questions, comments?

Discussion

  • Larry Lile

    Larry Lile - 2006-04-03

    Logged In: YES
    user_id=839907

    I must have missed the checkbox to upload the patch file.

     
  • Larry Lile

    Larry Lile - 2006-04-03

    Follow forks summary with specified output file patch

     
  • Eugene Syromyatnikov

    • status: open --> closed
    • Group: -->