1 '\" te 2 .\" Copyright (c) 2004, Sun Microsystems, Inc. All Rights Reserved 3 .\" Copyright 2014 Andrew Stormont. 4 .\" 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. 5 .\" 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. 6 .\" 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] 7 .TH RMMOUNT 1M "May 2, 2014" 8 .SH NAME 9 rmmount \- removable media mounter for CD-ROM, floppy, Jaz drive, and others 10 .SH SYNOPSIS 11 .LP 12 .nf 13 \fB/usr/sbin/rmmount\fR [\fB-D\fR] 14 .fi 15 16 .SH DESCRIPTION 17 .sp 18 .LP 19 The \fBrmmount\fR utility is a removable media mounter that is executed by 20 volume management whenever a removable medium, such as a \fBCD-ROM\fR or a 21 floppy, is inserted. Removable media is managed by an application or a volume 22 manager. 23 .sp 24 .LP 25 Upon insertion of a medium and following invocation of the \fBvolcheck\fR(1) 26 command, \fBrmmount\fR determines what type of file system (if any) is on that 27 medium. If a file system is present, \fBrmmount\fR mounts the file system in 28 one of the locations listed below. 29 .sp 30 .LP 31 For a diskette (floppy): 32 .sp 33 .ne 2 34 .na 35 \fB\fB/floppy/floppy0\fR\fR 36 .ad 37 .RS 26n 38 symbolic link to mounted floppy in local floppy drive 39 .RE 40 41 .sp 42 .ne 2 43 .na 44 \fB\fB/floppy/floppy_name\fR\fR 45 .ad 46 .RS 26n 47 mounted named floppy 48 .RE 49 50 .sp 51 .ne 2 52 .na 53 \fB\fB/floppy/unnamed_floppy\fR\fR 54 .ad 55 .RS 26n 56 mounted unnamed floppy 57 .RE 58 59 .sp 60 .LP 61 For a CD-ROM or a DVD-ROM: 62 .sp 63 .ne 2 64 .na 65 \fB\fB/cdrom/cdrom0\fR\fR 66 .ad 67 .sp .6 68 .RS 4n 69 symbolic link to mounted \fBCD-ROM\fR in local \fBCD-ROM\fR drive 70 .RE 71 72 .sp 73 .ne 2 74 .na 75 \fB\fB/cdrom/CD-ROM_name\fR\fR 76 .ad 77 .sp .6 78 .RS 4n 79 mounted named \fBCD-ROM\fR 80 .RE 81 82 .sp 83 .ne 2 84 .na 85 \fB\fB/cdrom/CD-ROM_name/partition\fR\fR 86 .ad 87 .sp .6 88 .RS 4n 89 mounted named \fBCD-ROM\fR with partitioned file system 90 .RE 91 92 .sp 93 .ne 2 94 .na 95 \fB\fB/cdrom/unnamed_cdrom\fR\fR 96 .ad 97 .sp .6 98 .RS 4n 99 mounted unnamed \fBCD-ROM\fR 100 .RE 101 102 .sp 103 .LP 104 For a Zip drive: 105 .sp 106 .ne 2 107 .na 108 \fB\fB/rmdisk/zip0\fR\fR 109 .ad 110 .RS 30n 111 symbolic link to mounted Zip medium in local Zip drive 112 .RE 113 114 .sp 115 .ne 2 116 .na 117 \fB\fB/rmdisk/\fIZip_name\fR\fR\fR 118 .ad 119 .RS 30n 120 mounted named Zip medium 121 .RE 122 123 .sp 124 .ne 2 125 .na 126 \fB\fB/rmdisk/\fIZip_name\fR/partition\fR\fR 127 .ad 128 .RS 30n 129 mounted named Zip medium with partitioned file system 130 .RE 131 132 .sp 133 .ne 2 134 .na 135 \fB\fB/rmdisk/unnamed_zip\fR\fR 136 .ad 137 .RS 30n 138 mounted unnamed Zip medium 139 .RE 140 141 .sp 142 .LP 143 For a Jaz drive: 144 .sp 145 .ne 2 146 .na 147 \fB\fB/rmdisk/jaz0\fR\fR 148 .ad 149 .RS 30n 150 symbolic link to mounted Jaz medium in local Jaz drive 151 .RE 152 153 .sp 154 .ne 2 155 .na 156 \fB\fB/rmdisk/\fIJaz_name\fR\fR\fR 157 .ad 158 .RS 30n 159 mounted named Jaz medium 160 .RE 161 162 .sp 163 .ne 2 164 .na 165 \fB\fB/rmdisk/\fIJaz_name\fR/partition\fR\fR 166 .ad 167 .RS 30n 168 mounted named Jaz medium with partitioned file system 169 .RE 170 171 .sp 172 .ne 2 173 .na 174 \fB\fB/rmdisk/unnamed_Jaz\fR\fR 175 .ad 176 .RS 30n 177 mounted unnamed Jaz medium 178 .RE 179 180 .sp 181 .LP 182 For a generic "rmdisk" drive: 183 .sp 184 .ne 2 185 .na 186 \fB\fB/rmdisk/rmdisk0\fR\fR 187 .ad 188 .sp .6 189 .RS 4n 190 symbolic link to mounted removable medium in local removable medium drive 191 .RE 192 193 .sp 194 .ne 2 195 .na 196 \fB\fB/rmdisk/\fIrmdisk_name\fR\fR\fR 197 .ad 198 .sp .6 199 .RS 4n 200 mounted named removable medium 201 .RE 202 203 .sp 204 .ne 2 205 .na 206 \fB\fB/rmdisk/\fIrmdisk_name\fR/partition\fR\fR 207 .ad 208 .sp .6 209 .RS 4n 210 mounted named removable medium with partitioned file system 211 .RE 212 213 .sp 214 .ne 2 215 .na 216 \fB\fB/rmdisk/unnamed_rmdisk\fR\fR 217 .ad 218 .sp .6 219 .RS 4n 220 mounted unnamed removable medium 221 .RE 222 223 .sp 224 .LP 225 If the media is read-only (for example, a \fBCD-ROM\fR or a floppy with 226 write-protect tab set), the file system is mounted read-only. 227 .sp 228 .LP 229 If a file system is not identified, \fBrmmount\fR does not mount a file system. 230 See the \fI\fR for more information on the location of \fBCD-ROM\fR, floppy, 231 and other media without file systems. 232 .sp 233 .LP 234 If a file system type has been determined, it is then checked to see that it is 235 "clean." If the file system is "dirty," \fBfsck\fR \fB-p\fR (see 236 \fBfsck\fR(1M)) is run in an attempt to clean it. If \fBfsck\fR fails, the file 237 system is mounted read-only. 238 .sp 239 .LP 240 After the mount is complete, "actions" associated with the media type are 241 executed. These actions allow for the notification to other programs that new 242 media are available. 243 .sp 244 .LP 245 Actions are executed in the order in which they appear in the configuration 246 file. The action function can return either \fB1\fR or \fB0\fR. If it returns 247 \fB0\fR, no further actions will be executed. This allows the function to 248 control which applications are executed. 249 .sp 250 .LP 251 In order to execute an action, \fBrmmount\fR performs a \fBdlopen\fR(3C) on the 252 shared object and calls the action function defined within it. The definition 253 of the interface to actions can be found in \fB/usr/include/rmmount.h\fR. 254 .sp 255 .LP 256 File systems mounted by \fBrmmount\fR are always mounted with the \fBnosuid\fR 257 flag set, thereby disabling setuid programs and access to block or character 258 devices in that file system. Upon ejection, \fBrmmount\fR unmounts mounted file 259 systems and executes actions associated with the media type. If a file system 260 is "busy" (that is, it contains the current working directory of a live 261 process), the ejection will fail. 262 .SH OPTIONS 263 .sp 264 .ne 2 265 .na 266 \fB\fB-D\fR\fR 267 .ad 268 .RS 6n 269 Turn on the debugging output from the \fBrmmount\fR \fBdprintf\fR calls. 270 .RE 271 272 .SH FILES 273 .sp 274 .ne 2 275 .na 276 \fB\fB/usr/lib/rmmount/*.so.1\fR\fR 277 .ad 278 .RS 27n 279 shared objects used by \fBrmmount\fR. 280 .RE 281 282 .SH SEE ALSO 283 .sp 284 .LP 285 \fBvolcheck\fR(1), \fBfsck\fR(1M), \fBdlopen\fR(3C), 286 \fBattributes\fR(5) 287 .sp 288 .LP 289 \fI\fR