xref: /freebsd/sbin/mount_msdosfs/mount_msdosfs.8 (revision 1a720cbec513210fa2e85c3882741ef2f6dc5f35)
1.\"	$NetBSD: mount_msdos.8,v 1.13 1998/02/06 05:57:00 perry Exp $
2.\"
3.\" Copyright (c) 1993,1994 Christopher G. Demetriou
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. Redistributions in binary form must reproduce the above copyright
12.\"    notice, this list of conditions and the following disclaimer in the
13.\"    documentation and/or other materials provided with the distribution.
14.\" 3. All advertising materials mentioning features or use of this software
15.\"    must display the following acknowledgment:
16.\"      This product includes software developed by Christopher G. Demetriou.
17.\" 3. The name of the author may not be used to endorse or promote products
18.\"    derived from this software without specific prior written permission
19.\"
20.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
21.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
22.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
23.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
24.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
25.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
26.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
27.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
28.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
29.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30.\"
31.Dd May 28, 2017
32.Dt MOUNT_MSDOSFS 8
33.Os
34.Sh NAME
35.Nm mount_msdosfs
36.Nd mount an MS-DOS file system
37.Sh SYNOPSIS
38.Nm
39.Op Fl 9ls
40.Op Fl D Ar DOS_codepage
41.Op Fl g Ar gid
42.Op Fl L Ar locale
43.Op Fl M Ar mask
44.Op Fl m Ar mask
45.Op Fl o Ar options
46.Op Fl u Ar uid
47.Op Fl W Ar table
48.Ar special node
49.Sh DESCRIPTION
50The
51.Nm
52utility attaches the MS-DOS file system residing on
53the device
54.Pa special
55to the global file system namespace at the location
56indicated by
57.Pa node .
58This command is normally executed by
59.Xr mount 8
60at boot time, but can be used by any user to mount an
61MS-DOS file system on any directory that they own (provided,
62of course, that they have appropriate access to the device that
63contains the file system).
64.Pp
65The options are as follows:
66.Bl -tag -width Ds
67.It Fl o Ar options
68Use the specified mount
69.Ar options ,
70as described in
71.Xr mount 8 .
72The following MSDOS file system-specific options are available:
73.Bl -tag -width indent
74.It Cm longnames
75Force Windows 95 long filenames to be visible.
76.It Cm shortnames
77Force only the old MS-DOS 8.3 style filenames to be visible.
78.It Cm nowin95
79Completely ignore Windows 95 extended file information.
80.El
81.It Fl u Ar uid
82Set the owner of the files in the file system to
83.Ar uid .
84The default owner is the owner of the directory
85on which the file system is being mounted.
86.It Fl g Ar gid
87Set the group of the files in the file system to
88.Ar gid .
89The default group is the group of the directory
90on which the file system is being mounted.
91.It Fl m Ar mask
92Specify the maximum file permissions for files
93in the file system.
94(For example, a
95.Ar mask
96of
97.Li 755
98specifies that, by default, the owner should have
99read, write, and execute permissions for files, but
100others should only have read and execute permissions.
101See
102.Xr chmod 1
103for more information about octal file modes.
104Only the nine low-order bits of
105.Ar mask
106are used.
107The value of
108.Ar -M
109is used if it is supplied and
110.Ar -m
111is omitted.
112The default
113.Ar mask
114is taken from the
115directory on which the file system is being mounted.
116.It Fl M Ar mask
117Specify the maximum file permissions for directories
118in the file system.
119The value of
120.Ar -m
121is used if it is supplied and
122.Ar -M
123is omitted.
124See the previous option's description for details.
125.It Fl s
126Force behaviour to
127ignore and not generate Win'95 long filenames.
128.It Fl l
129Force listing and generation of
130Win'95 long filenames
131and separate creation/modification/access dates.
132.Pp
133If neither
134.Fl s
135nor
136.Fl l
137are given,
138.Fl l
139is the default.
140.It Fl 9
141Ignore the special Win'95 directory entries even
142if deleting or renaming a file.
143This forces
144.Fl s .
145.\".It Fl G
146.\"This option causes the file system to be interpreted as an Atari-Gemdos
147.\"file system.
148.\"The differences to the MS-DOS file system are minimal and
149.\"limited to the boot block.
150.\"This option enforces
151.\".Fl s .
152.It Fl L Ar locale
153Specify locale name used for file name conversions
154for DOS and Win'95 names.
155By default ISO 8859-1 assumed as local character set.
156.It Fl D Ar DOS_codepage
157Specify the MS-DOS code page (aka IBM/OEM code page) name used for
158file name conversions for DOS names.
159.It Fl W Ar table
160.Bf Em
161This option is preserved for backward compatibility purpose only,
162and will be removed in the future.
163Please avoid using this option.
164.Ef
165.Pp
166Specify text file name with conversion table:
167.Pa iso22dos , iso72dos , koi2dos , koi8u2dos .
168.El
169.Sh EXAMPLES
170To mount a Russian MS-DOS file system located in
171.Pa /dev/ada1s1 :
172.Pp
173.Dl "mount_msdosfs -L ru_RU.KOI8-R -D CP866 /dev/ada1s1 /mnt"
174.Pp
175To mount a Japanese MS-DOS file system located in
176.Pa /dev/ada1s1 :
177.Pp
178.Dl "mount_msdosfs -L ja_JP.eucJP -D CP932 /dev/ada1s1 /mnt"
179.Sh SEE ALSO
180.Xr mount 2 ,
181.Xr unmount 2 ,
182.Xr msdosfs 4 ,
183.Xr fstab 5 ,
184.Xr mount 8
185.Pp
186List of Localized MS Operating Systems:
187.Pa http://www.microsoft.com/globaldev/reference/oslocversion.mspx .
188.Sh HISTORY
189The predecessor to
190.Nm mount_msdos
191utility named
192.Nm mount_pcfs
193appeared in
194.Nx 0.8 .
195It was rewritten in
196.Nx 1.0
197and first appeared in
198.Fx 2.0 .
199.Nm mount_msdos
200was renamed to the more aptly-named
201.Nm
202in
203.Fx 5.0 .
204The character code conversion routine was added in 2003.
205.Sh AUTHORS
206Initial implementation as
207.Nm mount_pcfs
208was written by
209.An -nosplit
210.An Paul Popelka Aq Mt paulp@uts.amdahl.com .
211It was rewritten by
212.An Christopher G. Demetriou Aq Mt cgd@NetBSD.org .
213The character code conversion routine was added by
214.An Ryuichiro Imura Aq Mt imura@ryu16.org .
215.Sh CAVEATS
216The use of the
217.Fl 9
218flag could result in damaged file systems,
219albeit the damage is in part taken care of by
220procedures similar to the ones used in Win'95.
221