等待进程这个包是一个简单的实用程序,它跟踪指定进程的执行并在它们终止后立即退出。或者,它可以报告有关退出状态和信号的详细信息。这个包带有两个程序:waitpid和waitall。第一个可用于等待指定的PID,后者可用于等待具有指定名称的进程。
例子:
$ waitpid -v 5323
5323: waiting
5266: waiting
5323: received SIGINT
5323: exited with status 0
5266: received SIGSEGV
5266: killed by SIGSEGV (core dumped)
$ waitall -v bash
27012: waiting
26911: waiting
25610: waiting
5543: waiting
5485: waiting
2960: waiting
暂无评论