Gentoo Archives: gentoo-server

From: Brian Kroth <bpkroth@×××××.com>
To: Tim Schumacher <tim@××××××××××××.org>
Cc: gentoo-server@l.g.o
Subject: Re: [gentoo-server] Checking a block device
Date: Fri, 06 Aug 2010 15:04:56
Message-Id: 20100806143308.GY605@gmail.com
In Reply to: Re: [gentoo-server] Checking a block device by Tim Schumacher
Tim Schumacher <tim@××××××××××××.org> 2010-08-04 12:19:
> At Wed, 04 Aug 2010 08:11:40 +0100, > Tom Grace wrote: > > On 08/04/2010 01:13 AM, GNUbie wrote: > > > How can I check if a block device (partition) has one or any of the > > > following characteristics: > > > > > > [1] raw > > > > > > [2] has content > > > > > > [3] formatted > > > > > > but without actually mounting it? > > > > testdisk (http://www.cgsecurity.org/wiki/TestDisk) will tell you that. > > This works also as root: > > file -s /dev/sda1 > > greetings > > Tim
Having just cranked out something where I needed similar info [1] I found that the file command doesn't understand all blockdev/filesystem types. The blkid command is a little bit better at that. Brian [1] http://cae.wisc.edu/~bpkroth/src/san-snapshots/

Attachments

File name MIME type
signature.asc application/pgp-signature