syscalls per process ?
Konstantin Belousov
kostikbel at gmail.com
Tue Mar 26 06:57:37 UTC 2013
On Tue, Mar 26, 2013 at 11:58:02AM +1000, Paul Koch wrote:
> Hi,
>
> At the start of all our programs, we set up a SIGALRM signal handler
> to retrieve rusage stats each second and log this info for analysis.
> It is useful for long running programs. One of the things we
> would really really like to get is the number of system calls the
> process has performed.
>
> Is there a simple way for a process to retrieve its own number of
> syscalls it has performed ? Pity it's not available via getrusage().
>
> We don't want to run an external program (eg. truss/dtrace) on each
> program.
AFAIR, the per-threads syscalls are not accounted. The accounting was
performed for some short time, but it was only used as a workaround for
some nfs client issue, and since the alternate approach was used, the
td_syscalls was removed.
Only global system count of the syscalls is maintained.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 834 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-hackers/attachments/20130326/cd922f37/attachment.sig>
More information about the freebsd-hackers
mailing list