1 '\" te 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 1M "Mar 1, 2007" 7 .SH NAME 8 rmmount \- removable media mounter for CD-ROM, floppy, Jaz drive, and others 9 .SH SYNOPSIS 10 .LP 11 .nf 12 \fB/usr/sbin/rmmount\fR [\fB-D\fR] 13 .fi 14 15 .SH DESCRIPTION 16 .sp 17 .LP 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). 22 .sp 23 .LP 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. 28 .sp 29 .LP 30 For a diskette (floppy): 31 .sp 32 .ne 2 33 .na 34 \fB\fB/floppy/floppy0\fR\fR 35 .ad 36 .RS 26n 37 symbolic link to mounted floppy in local floppy drive 38 .RE 39 40 .sp 41 .ne 2 42 .na 43 \fB\fB/floppy/floppy_name\fR\fR 44 .ad 45 .RS 26n 46 mounted named floppy 47 .RE 48 49 .sp 50 .ne 2 51 .na 52 \fB\fB/floppy/unnamed_floppy\fR\fR 53 .ad 54 .RS 26n 55 mounted unnamed floppy 56 .RE 57 58 .sp 59 .LP 60 For a CD-ROM or a DVD-ROM: 61 .sp 62 .ne 2 63 .na 64 \fB\fB/cdrom/cdrom0\fR\fR 65 .ad 66 .sp .6 67 .RS 4n 68 symbolic link to mounted \fBCD-ROM\fR in local \fBCD-ROM\fR drive 69 .RE 70 71 .sp 72 .ne 2 73 .na 74 \fB\fB/cdrom/CD-ROM_name\fR\fR 75 .ad 76 .sp .6 77 .RS 4n 78 mounted named \fBCD-ROM\fR 79 .RE 80 81 .sp 82 .ne 2 83 .na 84 \fB\fB/cdrom/CD-ROM_name/partition\fR\fR 85 .ad 86 .sp .6 87 .RS 4n 88 mounted named \fBCD-ROM\fR with partitioned file system 89 .RE 90 91 .sp 92 .ne 2 93 .na 94 \fB\fB/cdrom/unnamed_cdrom\fR\fR 95 .ad 96 .sp .6 97 .RS 4n 98 mounted unnamed \fBCD-ROM\fR 99 .RE 100 101 .sp 102 .LP 103 For a Zip drive: 104 .sp 105 .ne 2 106 .na 107 \fB\fB/rmdisk/zip0\fR\fR 108 .ad 109 .RS 30n 110 symbolic link to mounted Zip medium in local Zip drive 111 .RE 112 113 .sp 114 .ne 2 115 .na 116 \fB\fB/rmdisk/\fIZip_name\fR\fR\fR 117 .ad 118 .RS 30n 119 mounted named Zip medium 120 .RE 121 122 .sp 123 .ne 2 124 .na 125 \fB\fB/rmdisk/\fIZip_name\fR/partition\fR\fR 126 .ad 127 .RS 30n 128 mounted named Zip medium with partitioned file system 129 .RE 130 131 .sp 132 .ne 2 133 .na 134 \fB\fB/rmdisk/unnamed_zip\fR\fR 135 .ad 136 .RS 30n 137 mounted unnamed Zip medium 138 .RE 139 140 .sp 141 .LP 142 For a Jaz drive: 143 .sp 144 .ne 2 145 .na 146 \fB\fB/rmdisk/jaz0\fR\fR 147 .ad 148 .RS 30n 149 symbolic link to mounted Jaz medium in local Jaz drive 150 .RE 151 152 .sp 153 .ne 2 154 .na 155 \fB\fB/rmdisk/\fIJaz_name\fR\fR\fR 156 .ad 157 .RS 30n 158 mounted named Jaz medium 159 .RE 160 161 .sp 162 .ne 2 163 .na 164 \fB\fB/rmdisk/\fIJaz_name\fR/partition\fR\fR 165 .ad 166 .RS 30n 167 mounted named Jaz medium with partitioned file system 168 .RE 169 170 .sp 171 .ne 2 172 .na 173 \fB\fB/rmdisk/unnamed_Jaz\fR\fR 174 .ad 175 .RS 30n 176 mounted unnamed Jaz medium 177 .RE 178 179 .sp 180 .LP 181 For a generic "rmdisk" drive: 182 .sp 183 .ne 2 184 .na 185 \fB\fB/rmdisk/rmdisk0\fR\fR 186 .ad 187 .sp .6 188 .RS 4n 189 symbolic link to mounted removable medium in local removable medium drive 190 .RE 191 192 .sp 193 .ne 2 194 .na 195 \fB\fB/rmdisk/\fIrmdisk_name\fR\fR\fR 196 .ad 197 .sp .6 198 .RS 4n 199 mounted named removable medium 200 .RE 201 202 .sp 203 .ne 2 204 .na 205 \fB\fB/rmdisk/\fIrmdisk_name\fR/partition\fR\fR 206 .ad 207 .sp .6 208 .RS 4n 209 mounted named removable medium with partitioned file system 210 .RE 211 212 .sp 213 .ne 2 214 .na 215 \fB\fB/rmdisk/unnamed_rmdisk\fR\fR 216 .ad 217 .sp .6 218 .RS 4n 219 mounted unnamed removable medium 220 .RE 221 222 .sp 223 .LP 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. 226 .sp 227 .LP 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. 231 .sp 232 .LP 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(1M)) is run in an attempt to clean it. If \fBfsck\fR fails, the file 236 system is mounted read-only. 237 .sp 238 .LP 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 241 media are available. 242 .sp 243 .LP 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. 248 .sp 249 .LP 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. 253 .sp 254 .LP 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. 261 .SH OPTIONS 262 .sp 263 .ne 2 264 .na 265 \fB\fB-D\fR\fR 266 .ad 267 .RS 6n 268 Turn on the debugging output from the \fBrmmount\fR \fBdprintf\fR calls. 269 .RE 270 271 .SH FILES 272 .sp 273 .ne 2 274 .na 275 \fB\fB/usr/lib/rmmount/*.so.1\fR\fR 276 .ad 277 .RS 27n 278 shared objects used by \fBrmmount\fR. 279 .RE 280 281 .SH SEE ALSO 282 .sp 283 .LP 284 \fBvolcheck\fR(1), \fBvolrmmount\fR(1), \fBfsck\fR(1M), \fBdlopen\fR(3C), 285 \fBattributes\fR(5) 286 .sp 287 .LP 288 \fI\fR