xref: /minix/usr.bin/ipcrm/ipcrm.1 (revision e1cdaee1)
1.\"	$NetBSD: ipcrm.1,v 1.11 2008/06/01 10:25:29 wiz Exp $
2.\"
3.\" Copyright (c) 1994 Adam Glass
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright
10.\"    notice, this list of conditions and the following disclaimer.
11.\" 2. The name of the Author may not be used to endorse or promote products
12.\"    derived from this software without specific prior written permission.
13.\"
14.\" THIS SOFTWARE IS PROVIDED BY Adam Glass ``AS IS'' AND
15.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17.\" ARE DISCLAIMED.  IN NO EVENT SHALL Adam Glass BE LIABLE
18.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24.\" SUCH DAMAGE.
25.\"
26.\" $NetBSD: ipcrm.1,v 1.11 2008/06/01 10:25:29 wiz Exp $
27.\"
28.Dd May 31, 2008
29.Dt IPCRM 1
30.Os
31.Sh NAME
32.Nm ipcrm
33.Nd remove the specified message queues, semaphore sets, and shared memory segments
34.Sh SYNOPSIS
35.Nm
36.Op Fl M Ar shmkey
37.Op Fl m Ar shmid
38.Op Fl Q Ar msgkey
39.Op Fl q Ar msqid
40.Op Fl S Ar semkey
41.Op Fl s Ar semid
42.Ar ...
43.Sh DESCRIPTION
44.Nm
45removes the specified message queues, semaphores, and shared memory
46segments.
47These System V IPC objects can be specified by their
48creation ID or any associated key.
49.Pp
50The following options are used to specify which IPC objects will be removed.
51Any number and combination of these options can be used:
52.Bl -tag -width indent
53.It Fl M Ar shmkey
54Mark the shared memory segment associated with key
55.Ar shmkey
56for removal.
57This marked segment will be destroyed after the last detach.
58.It Fl m Ar shmid
59Mark the shared memory segment associated with ID
60.Ar shmid
61for removal.
62This marked segment will be destroyed after the last detach.
63.It Fl Q Ar msgkey
64Remove the message queue associated with key
65.Ar msgkey
66from the system.
67.It Fl q Ar msqid
68Remove the message queue associated with the ID
69.Ar msqid
70from the system.
71.It Fl S Ar semkey
72Remove the semaphore set associated with key
73.Ar semkey
74from the system.
75.It Fl s Ar semid
76Removes the semaphore set associated with ID
77.Ar semid
78from the system.
79.El
80.Pp
81If the
82.Ar id
83or
84.Ar key
85argument is
86.Dq all
87then all entries of the appropriate type are removed.
88.Pp
89The identifiers and keys associated with these System V IPC objects can be
90determined by using
91.Xr ipcs 1 .
92.Sh SEE ALSO
93.Xr ipcs 1 ,
94.Xr shmat 2 ,
95.Xr shmctl 2 ,
96.Xr shmdt 2 ,
97.Xr shmget 2
98