1 More Discussions You Might Find Interesting
1. Programming
Hello everybody!
I wrote the following code:
...
int main()
{
pid_t pid;
for (int i=0;i<100;i++)
{
pid=fork();
if(pid==0)
{execl("md5sum","myprog",NULL);exit(1)}
else if(pid>0)
{ waitpid(pid,&status,0);getrusage(RUSAGE_CHILDREN,&usage);}
The... (3 Replies)
Discussion started by: nicos
3 Replies
LEARN ABOUT DEBIAN
runstat
RUNSTAT(1) General Commands Manual RUNSTAT(1)
NAME
runstat - collect statistics about execution of a process
SYNOPSYS
runstat [ -h ]
runstat [ -d ] [ -f pathname ] command [ args ]
DESCRIPTION
runstat tries to execute a command in a subprocess, and upon termination of the subprocess collects some statistics about that subprocess,
and writes them to a file.
These statistics include time of execution, exit status, and elapsed time to execute, as well as use of various OS resources.
USAGE
-d
Debug mode; send log messages to standard error as well as to the system log.
-f pathname
Specifies the pathname of the file to save the statistics to. The default is to create a file in /tmp/cronutils-$USER with the name
of the command, and suffix ".stat".
-h
Prints some basic help.
SEE ALSO
runalarm(1), runlock(1), getrusage(2)
AUTHOR
runstat was written by Jamie Wilkinson <jaq@google.com>.
COPYRIGHT
This program is copyright (C) 2010 Google, Inc.
It is licensed under the Apache License, Version 2.0
Google, Inc. October 18, 2010 RUNSTAT(1)