xref: /freebsd/bin/pwait/pwait.1 (revision 9a14aa017b21c292740c00ee098195cd46642730)
1.\"
2.\" Copyright (c) 2004-2009, Jilles Tjoelker
3.\" All rights reserved.
4.\"
5.\" Redistribution and use in source and binary forms, with
6.\" or without modification, are permitted provided that the
7.\" following conditions are met:
8.\"
9.\" 1. Redistributions of source code must retain the above
10.\"    copyright notice, this list of conditions and the
11.\"    following disclaimer.
12.\" 2. Redistributions in binary form must reproduce the
13.\"    above copyright notice, this list of conditions and
14.\"    the following disclaimer in the documentation and/or
15.\"    other materials provided with the distribution.
16.\"
17.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
18.\" CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
19.\" WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
20.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
21.\" PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
22.\" COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY
23.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
24.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
25.\" PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
26.\" USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
27.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
29.\" NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
30.\" USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
31.\" OF SUCH DAMAGE.
32.\"
33.\" $FreeBSD$
34.\"
35.Dd November 1, 2009
36.Dt PWAIT 1
37.Os
38.Sh NAME
39.Nm pwait
40.Nd wait for processes to terminate
41.Sh SYNOPSIS
42.Nm
43.Op Fl v
44.Ar pid
45\&...
46.Sh DESCRIPTION
47The
48.Nm
49utility will wait until each of the given processes has terminated.
50.Pp
51The following option is available:
52.Bl -tag -width indent
53.It Fl v
54Print the exit status when each process terminates.
55.El
56.Sh DIAGNOSTICS
57.Pp
58The
59.Nm
60utility returns 0 on success, and >0 if an error occurs.
61.Pp
62Invalid pids elicit a warning message but are otherwise ignored.
63.Sh SEE ALSO
64.Xr kill 1 ,
65.Xr pkill 1 ,
66.Xr ps 1 ,
67.Xr wait 1 ,
68.Xr kqueue 2
69.Sh NOTES
70.Nm
71is not a substitute for the
72.Xr wait 1
73builtin
74as it will not clean up any zombies or state in the parent process.
75.Sh HISTORY
76A
77.Nm
78command first appeared in SunOS 5.8.
79