xref: /netbsd/usr.bin/ipcrm/ipcrm.1 (revision c4a72b64)
1.\"	$NetBSD: ipcrm.1,v 1.9 2002/09/30 11:09:03 grant 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.9 2002/09/30 11:09:03 grant Exp $
27.\""
28.Dd June 17, 2002
29.Dt IPCRM 1
30.Os
31.Sh NAME
32.Nm ipcrm
33.Nd remove the specified message queues, semaphore sets,
34and shared memory segments
35.Sh SYNOPSIS
36.Nm
37.Bk -words
38.Op Fl q Ar msqid
39.Ek
40.Bk -words
41.Op Fl m Ar shmid
42.Ek
43.Bk -words
44.Op Fl s Ar semid
45.Ek
46.Bk -words
47.Op Fl Q Ar msgkey
48.Ek
49.Bk -words
50.Op Fl M Ar shmkey
51.Ek
52.Bk -words
53.Op Fl S Ar semkey
54.Ek
55.Ar ...
56.Sh DESCRIPTION
57.Nm
58removes the specified message queues, semaphores and shared memory
59segments.
60These System V IPC objects can be specified by their
61creation id or any associated key.
62.Pp
63The following options are used to specify which IPC objects will be removed.
64Any number and combination of these options can be used:
65.Bl -tag -width indent
66.It Fl q Ar msqid
67Remove the message queue associated with the id
68.Ar msqid
69from the system.
70.It Fl m Ar shmid
71Mark the shared memory segment associated with id
72.Ar shmid
73for removal.
74This marked segment will be destroyed after the last detach.
75.It Fl s Ar semid
76Removes the semaphore set associated with id
77.Ar semid
78from the system.
79.It Fl Q Ar msgkey
80Remove the message queue associated with key
81.Ar msgkey
82from the system.
83.It Fl M Ar shmkey
84Mark the shared memory segment associated with key
85.Ar shmkey
86for removal.
87This marked segment will be destroyed after the last detach.
88.It Fl S Ar semkey
89Remove the semaphore set associated with key
90.Ar semkey
91from the system.
92.El
93.Pp
94The identifiers and keys associated with these System V IPC objects can be
95determined by using
96.Xr ipcs 1 .
97.Sh SEE ALSO
98.Xr ipcs 1 ,
99.Xr shmat 2 ,
100.Xr shmctl 2 ,
101.Xr shmdt 2 ,
102.Xr shmget 2
103