2 .\" Copyright (c) 2004, Sun Microsystems, Inc. All Rights Reserved
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH RMMOUNT 8 "Mar 1, 2007"
8 rmmount \- removable media mounter for CD-ROM, floppy, Jaz drive, and others
12 \fB/usr/sbin/rmmount\fR [\fB-D\fR]
18 The \fBrmmount\fR utility is a removable media mounter that is executed by
19 volume management whenever a removable medium, such as a \fBCD-ROM\fR or a
20 floppy, is inserted. Removable media is managed by an application or a volume
21 manager. \fBrmmount\fR can also be called by using \fBvolrmmount\fR(1).
24 Upon insertion of a medium and following invocation of the \fBvolcheck\fR(1)
25 command, \fBrmmount\fR determines what type of file system (if any) is on that
26 medium. If a file system is present, \fBrmmount\fR mounts the file system in
27 one of the locations listed below.
30 For a diskette (floppy):
34 \fB\fB/floppy/floppy0\fR\fR
37 symbolic link to mounted floppy in local floppy drive
43 \fB\fB/floppy/floppy_name\fR\fR
52 \fB\fB/floppy/unnamed_floppy\fR\fR
55 mounted unnamed floppy
60 For a CD-ROM or a DVD-ROM:
64 \fB\fB/cdrom/cdrom0\fR\fR
68 symbolic link to mounted \fBCD-ROM\fR in local \fBCD-ROM\fR drive
74 \fB\fB/cdrom/CD-ROM_name\fR\fR
78 mounted named \fBCD-ROM\fR
84 \fB\fB/cdrom/CD-ROM_name/partition\fR\fR
88 mounted named \fBCD-ROM\fR with partitioned file system
94 \fB\fB/cdrom/unnamed_cdrom\fR\fR
98 mounted unnamed \fBCD-ROM\fR
107 \fB\fB/rmdisk/zip0\fR\fR
110 symbolic link to mounted Zip medium in local Zip drive
116 \fB\fB/rmdisk/\fIZip_name\fR\fR\fR
119 mounted named Zip medium
125 \fB\fB/rmdisk/\fIZip_name\fR/partition\fR\fR
128 mounted named Zip medium with partitioned file system
134 \fB\fB/rmdisk/unnamed_zip\fR\fR
137 mounted unnamed Zip medium
146 \fB\fB/rmdisk/jaz0\fR\fR
149 symbolic link to mounted Jaz medium in local Jaz drive
155 \fB\fB/rmdisk/\fIJaz_name\fR\fR\fR
158 mounted named Jaz medium
164 \fB\fB/rmdisk/\fIJaz_name\fR/partition\fR\fR
167 mounted named Jaz medium with partitioned file system
173 \fB\fB/rmdisk/unnamed_Jaz\fR\fR
176 mounted unnamed Jaz medium
181 For a generic "rmdisk" drive:
185 \fB\fB/rmdisk/rmdisk0\fR\fR
189 symbolic link to mounted removable medium in local removable medium drive
195 \fB\fB/rmdisk/\fIrmdisk_name\fR\fR\fR
199 mounted named removable medium
205 \fB\fB/rmdisk/\fIrmdisk_name\fR/partition\fR\fR
209 mounted named removable medium with partitioned file system
215 \fB\fB/rmdisk/unnamed_rmdisk\fR\fR
219 mounted unnamed removable medium
224 If the media is read-only (for example, a \fBCD-ROM\fR or a floppy with
225 write-protect tab set), the file system is mounted read-only.
228 If a file system is not identified, \fBrmmount\fR does not mount a file system.
229 See the \fI\fR for more information on the location of \fBCD-ROM\fR, floppy,
230 and other media without file systems.
233 If a file system type has been determined, it is then checked to see that it is
234 "clean." If the file system is "dirty," \fBfsck\fR \fB-p\fR (see
235 \fBfsck\fR(8)) is run in an attempt to clean it. If \fBfsck\fR fails, the file
236 system is mounted read-only.
239 After the mount is complete, "actions" associated with the media type are
240 executed. These actions allow for the notification to other programs that new
244 Actions are executed in the order in which they appear in the configuration
245 file. The action function can return either \fB1\fR or \fB0\fR. If it returns
246 \fB0\fR, no further actions will be executed. This allows the function to
247 control which applications are executed.
250 In order to execute an action, \fBrmmount\fR performs a \fBdlopen\fR(3C) on the
251 shared object and calls the action function defined within it. The definition
252 of the interface to actions can be found in \fB/usr/include/rmmount.h\fR.
255 File systems mounted by \fBrmmount\fR are always mounted with the \fBnosuid\fR
256 flag set, thereby disabling setuid programs and access to block or character
257 devices in that file system. Upon ejection, \fBrmmount\fR unmounts mounted file
258 systems and executes actions associated with the media type. If a file system
259 is "busy" (that is, it contains the current working directory of a live
260 process), the ejection will fail.
268 Turn on the debugging output from the \fBrmmount\fR \fBdprintf\fR calls.
275 \fB\fB/usr/lib/rmmount/*.so.1\fR\fR
278 shared objects used by \fBrmmount\fR.
284 \fBvolcheck\fR(1), \fBvolrmmount\fR(1), \fBfsck\fR(8), \fBdlopen\fR(3C),