1551c4c36STomohiro Kusumi.\" Copyright (c) 2016 The DragonFly Project 2551c4c36STomohiro Kusumi.\" Copyright (c) 2014 The FreeBSD Foundation 3551c4c36STomohiro Kusumi.\" All rights reserved. 4551c4c36STomohiro Kusumi.\" 5551c4c36STomohiro Kusumi.\" This software was developed by Edward Tomasz Napierala under sponsorship 6551c4c36STomohiro Kusumi.\" from the FreeBSD Foundation. 7551c4c36STomohiro Kusumi.\" 8551c4c36STomohiro Kusumi.\" Redistribution and use in source and binary forms, with or without 9551c4c36STomohiro Kusumi.\" modification, are permitted provided that the following conditions 10551c4c36STomohiro Kusumi.\" are met: 11551c4c36STomohiro Kusumi.\" 1. Redistributions of source code must retain the above copyright 12551c4c36STomohiro Kusumi.\" notice, this list of conditions and the following disclaimer. 13551c4c36STomohiro Kusumi.\" 2. Redistributions in binary form must reproduce the above copyright 14551c4c36STomohiro Kusumi.\" notice, this list of conditions and the following disclaimer in the 15551c4c36STomohiro Kusumi.\" documentation and/or other materials provided with the distribution. 16551c4c36STomohiro Kusumi.\" 17551c4c36STomohiro Kusumi.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND 18551c4c36STomohiro Kusumi.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19551c4c36STomohiro Kusumi.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 20551c4c36STomohiro Kusumi.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE 21551c4c36STomohiro Kusumi.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22551c4c36STomohiro Kusumi.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23551c4c36STomohiro Kusumi.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24551c4c36STomohiro Kusumi.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25551c4c36STomohiro Kusumi.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26551c4c36STomohiro Kusumi.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27551c4c36STomohiro Kusumi.\" SUCH DAMAGE. 28551c4c36STomohiro Kusumi.\" 29551c4c36STomohiro Kusumi.\" $FreeBSD$ 30551c4c36STomohiro Kusumi.\" 3127ded0eaSTomohiro Kusumi.Dd February 12, 2018 32551c4c36STomohiro Kusumi.Dt FSTYP 8 33551c4c36STomohiro Kusumi.Os 34551c4c36STomohiro Kusumi.Sh NAME 35551c4c36STomohiro Kusumi.Nm fstyp 36551c4c36STomohiro Kusumi.Nd determine filesystem type 37551c4c36STomohiro Kusumi.Sh SYNOPSIS 38551c4c36STomohiro Kusumi.Nm 39551c4c36STomohiro Kusumi.Op Fl l 40551c4c36STomohiro Kusumi.Op Fl s 41551c4c36STomohiro Kusumi.Op Fl u 42551c4c36STomohiro Kusumi.Ar special 43551c4c36STomohiro Kusumi.Sh DESCRIPTION 44551c4c36STomohiro KusumiThe 45551c4c36STomohiro Kusumi.Nm 46551c4c36STomohiro Kusumiutility is used to determine the filesystem type on a given device. 4727ded0eaSTomohiro KusumiIt can recognize ISO-9660, exFAT, Ext2, FAT, NTFS, UFS, HAMMER, and HAMMER2 filesystems. 48551c4c36STomohiro KusumiWhen the 49551c4c36STomohiro Kusumi.Fl u 50551c4c36STomohiro Kusumiflag is specified, 51551c4c36STomohiro Kusumi.Nm 52551c4c36STomohiro Kusumialso recognizes certain additional metadata formats that cannot be 53551c4c36STomohiro Kusumihandled using 54551c4c36STomohiro Kusumi.Xr mount 8 . 55551c4c36STomohiro Kusumi.Pp 56551c4c36STomohiro KusumiThe filesystem name is printed to the standard output 57551c4c36STomohiro Kusumias, respectively: 58551c4c36STomohiro Kusumi.Bl -item -offset indent -compact 59551c4c36STomohiro Kusumi.It 60551c4c36STomohiro Kusumicd9660 61551c4c36STomohiro Kusumi.It 6227ded0eaSTomohiro Kusumiexfat 6327ded0eaSTomohiro Kusumi.It 64551c4c36STomohiro Kusumiext2fs 65551c4c36STomohiro Kusumi.It 66551c4c36STomohiro Kusumimsdosfs 67551c4c36STomohiro Kusumi.It 68551c4c36STomohiro Kusumintfs 69551c4c36STomohiro Kusumi.It 70551c4c36STomohiro Kusumiufs 71551c4c36STomohiro Kusumi.It 72551c4c36STomohiro Kusumihammer 73030fdd8aSTomohiro Kusumi.It 74030fdd8aSTomohiro Kusumihammer2 75551c4c36STomohiro Kusumi.El 76551c4c36STomohiro Kusumi.Pp 77551c4c36STomohiro KusumiNote that HAMMER filesystem consists of more than one volumes requires a path in blkdevs format. 78551c4c36STomohiro KusumiSee 79551c4c36STomohiro Kusumi.Xr hammer 8 80551c4c36STomohiro Kusumifor blkdevs format. 81551c4c36STomohiro Kusumi.Nm 82551c4c36STomohiro Kusumidoesn't recognize partially specified block devices as HAMMER filesystem volumes unless 83551c4c36STomohiro Kusumi.Fl u 84551c4c36STomohiro Kusumiflag is specified. 85551c4c36STomohiro Kusumi.Pp 86551c4c36STomohiro KusumiBecause 87551c4c36STomohiro Kusumi.Nm 88551c4c36STomohiro Kusumiis built specifically to detect filesystem types, it differs from 89551c4c36STomohiro Kusumi.Xr file 1 90551c4c36STomohiro Kusumiin several ways. 91551c4c36STomohiro KusumiThe output is machine-parsable, filesystem labels are supported, 92551c4c36STomohiro Kusumiand does not try to recognize any file format other than filesystems. 93551c4c36STomohiro Kusumi.Pp 94551c4c36STomohiro KusumiThese options are available: 95551c4c36STomohiro Kusumi.Bl -tag -width ".Fl l" 96551c4c36STomohiro Kusumi.It Fl l 97551c4c36STomohiro KusumiIn addition to filesystem type, print filesystem label if available. 98551c4c36STomohiro Kusumi.It Fl s 99551c4c36STomohiro KusumiIgnore file type. 100551c4c36STomohiro KusumiBy default, 101551c4c36STomohiro Kusumi.Nm 102551c4c36STomohiro Kusumionly works on regular files and disk-like device nodes. 103551c4c36STomohiro KusumiTrying to read other file types might have unexpected consequences or hang 104551c4c36STomohiro Kusumiindefinitely. 105551c4c36STomohiro Kusumi.It Fl u 106551c4c36STomohiro KusumiInclude filesystems and devices that cannot be mounted directly by 107551c4c36STomohiro Kusumi.Xr mount 8 . 108551c4c36STomohiro Kusumi.El 109551c4c36STomohiro Kusumi.Sh EXIT STATUS 110551c4c36STomohiro KusumiThe 111551c4c36STomohiro Kusumi.Nm 112551c4c36STomohiro Kusumiutility exits 0 on success, and >0 if an error occurs or the filesystem 113551c4c36STomohiro Kusumitype is not recognized. 114551c4c36STomohiro Kusumi.Sh SEE ALSO 115551c4c36STomohiro Kusumi.Xr file 1 , 116551c4c36STomohiro Kusumi.Xr autofs 5 , 11771990c18SSascha Wildner.Xr hammer 8 , 118030fdd8aSTomohiro Kusumi.Xr hammer2 8 , 11971990c18SSascha Wildner.Xr mount 8 120551c4c36STomohiro Kusumi.Sh HISTORY 121551c4c36STomohiro KusumiThe 122551c4c36STomohiro Kusumi.Nm 123551c4c36STomohiro Kusumicommand appeared in 124551c4c36STomohiro Kusumi.Fx 10.2 . 125551c4c36STomohiro KusumiThe 126551c4c36STomohiro Kusumi.Nm 127551c4c36STomohiro Kusumicommand appeared in 128551c4c36STomohiro Kusumi.Dx 4.5 . 129551c4c36STomohiro Kusumi.Sh AUTHORS 130cc05af1eSTomohiro Kusumi.An -nosplit 131551c4c36STomohiro KusumiThe 132551c4c36STomohiro Kusumi.Nm 133551c4c36STomohiro Kusumiutility was developed by 134551c4c36STomohiro Kusumi.An Edward Tomasz Napierala Aq Mt trasz@FreeBSD.org 135551c4c36STomohiro Kusumiunder sponsorship from the FreeBSD Foundation. 136551c4c36STomohiro KusumiZFS and GELI support was added by 137cc05af1eSTomohiro Kusumi.An Allan Jude Aq Mt allanjude@FreeBSD.org . 138551c4c36STomohiro Kusumi.Pp 139551c4c36STomohiro KusumiThe 140551c4c36STomohiro Kusumi.Nm 141551c4c36STomohiro Kusumiutility was ported to 142551c4c36STomohiro Kusumi.Dx 143551c4c36STomohiro Kusumiby 144*49837aefSTomohiro Kusumi.An Tomohiro Kusumi Aq Mt tkusumi@netbsd.org . 145b99c9975STomohiro KusumiDonated to DragonFlyBSD by PeerCorps Trust Fund. 146551c4c36STomohiro Kusumi.Sh BUGS 147551c4c36STomohiro KusumiThe 148551c4c36STomohiro Kusumi.Nm 149551c4c36STomohiro Kusumiutility on 150551c4c36STomohiro Kusumi.Dx 151551c4c36STomohiro Kusumicurrently doesn't support 152551c4c36STomohiro Kusumi.Xr zfs 8 153551c4c36STomohiro Kusumipool and 154551c4c36STomohiro Kusumi.Xr geli 8 155551c4c36STomohiro Kusumiproviders supported on 156551c4c36STomohiro Kusumi.Fx . 157