xref: /netbsd-src/sbin/fsck_msdos/fsck_msdos.8 (revision c6b9fd96014ccb64707628f54d82d2fa9a3a1d3b)
1*c6b9fd96Ssevan.\"	$NetBSD: fsck_msdos.8,v 1.18 2016/09/11 04:12:08 sevan Exp $
26ae4c91aSws.\"
36ae4c91aSws.\" Copyright (C) 1995 Wolfgang Solfrank
46ae4c91aSws.\" Copyright (c) 1995 Martin Husemann
56ae4c91aSws.\"
66ae4c91aSws.\" Redistribution and use in source and binary forms, with or without
76ae4c91aSws.\" modification, are permitted provided that the following conditions
86ae4c91aSws.\" are met:
96ae4c91aSws.\" 1. Redistributions of source code must retain the above copyright
106ae4c91aSws.\"    notice, this list of conditions and the following disclaimer.
116ae4c91aSws.\" 2. Redistributions in binary form must reproduce the above copyright
126ae4c91aSws.\"    notice, this list of conditions and the following disclaimer in the
136ae4c91aSws.\"    documentation and/or other materials provided with the distribution.
146ae4c91aSws.\"
156ae4c91aSws.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR
166ae4c91aSws.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
176ae4c91aSws.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
186ae4c91aSws.\" IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY DIRECT, INDIRECT,
196ae4c91aSws.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
206ae4c91aSws.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
216ae4c91aSws.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
226ae4c91aSws.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
236ae4c91aSws.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
246ae4c91aSws.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
256ae4c91aSws.\"
266ae4c91aSws.\"
27*c6b9fd96Ssevan.Dd September 11, 2016
286ae4c91aSws.Dt FSCK_MSDOS 8
2973f545bbSwiz.Os
306ae4c91aSws.Sh NAME
316ae4c91aSws.Nm fsck_msdos
326ae4c91aSws.Nd DOS/Windows (FAT) filesystem consistency checker
336ae4c91aSws.Sh SYNOPSIS
34990562bfSwiz.Nm
356ae4c91aSws.Fl p
36313e12deScgd.Op Fl f
37f6590b22Smycroft.Ar filesystem ...
38990562bfSwiz.Nm
39313e12deScgd.Op Fl fny
40738a97caShannken.Op Fl x Ar snap-backup
41f6590b22Smycroft.Ar filesystem ...
426ae4c91aSws.Sh DESCRIPTION
43313e12deScgdThe
44313e12deScgd.Nm
45313e12deScgdutility verifies and repairs
46313e12deScgd.Tn FAT
47313e12deScgdfilesystems (more commonly known
48313e12deScgdas
49313e12deScgd.Tn DOS
50313e12deScgdfilesystems).
51313e12deScgd.Pp
526ae4c91aSwsThe first form of
536ae4c91aSws.Nm
546ae4c91aSwspreens the specified filesystems.
556ae4c91aSwsIt is normally started by
566ae4c91aSws.Xr fsck 8
576ae4c91aSwsrun from
586ae4c91aSws.Pa /etc/rc
596ae4c91aSwsduring automatic reboot, when a FAT filesystem is detected.
60313e12deScgdWhen preening file systems,
61313e12deScgd.Nm
622fb4b1dbSwizwill fix common inconsistencies non-interactively.
632fb4b1dbSwizIf more serious problems are found,
64313e12deScgd.Nm
65313e12deScgddoes not try to fix them, indicates that it was not
66313e12deScgdsuccessful, and exits.
676ae4c91aSws.Pp
68313e12deScgdThe second form of
69313e12deScgd.Nm
70313e12deScgdchecks the specified file systems and tries to repair all
71313e12deScgddetected inconsistencies, requesting confirmation before
72313e12deScgdmaking any changes.
736ae4c91aSws.Pp
74313e12deScgdThe options are as follows:
75c4f8f360Swiz.Bl -tag -width XxXsnapXbackupXX
76313e12deScgd.It Fl f
77313e12deScgdThis option is ignored by
78990562bfSwiz.Nm ,
79313e12deScgdand is present only for compatibility with programs that
80313e12deScgdcheck other file system types for consistency, such as
81313e12deScgd.Xr fsck_ffs 8 .
82313e12deScgd.It Fl n
83313e12deScgdCauses
84313e12deScgd.Nm
85313e12deScgdto assume no as the answer to all operator
86313e12deScgdquestions, except
87313e12deScgd.Dq CONTINUE? .
88313e12deScgd.It Fl p
89313e12deScgdPreen the specified filesystems.
90738a97caShannken.It Fl x Ar snap-backup
91738a97caShannkenUse a snapshot with
92738a97caShannken.Ar snap-backup
93c4f8f360Swizas backup to check a read-write mounted filesystem.
94c4f8f360SwizMust be used with
95738a97caShannken.Fl n .
96738a97caShannkenSee
97738a97caShannken.Xr fss 4
98738a97caShannkenfor more details.
99738a97caShannkenThe point is to check an internally-consistent version of the
100738a97caShannkenfilesystem to find out if it is damaged; on failure one should unmount
101738a97caShannkenthe filesystem and repair it.
102313e12deScgd.It Fl y
103313e12deScgdCauses
104313e12deScgd.Nm
105313e12deScgdto assume yes as the answer to all operator questions.
1066ae4c91aSws.El
1076ae4c91aSws.Sh SEE ALSO
108c4f8f360Swiz.Xr fss 4 ,
1096ae4c91aSws.Xr fsck 8 ,
110313e12deScgd.Xr fsck_ffs 8 ,
1116ae4c91aSws.Xr mount_msdos 8
112*c6b9fd96Ssevan.Sh HISTORY
113*c6b9fd96SsevanA
114*c6b9fd96Ssevan.Nm
115*c6b9fd96Ssevanutility appeared in
116*c6b9fd96Ssevan.Nx 1.2 .
1176ae4c91aSws.Sh BUGS
1185a94f674Slukem.Nm
1196ae4c91aSwsis still under construction.
120