Subject: Re: special-casing access to image files
To: Hubert Feyrer <hubert.feyrer@informatik.fh-regensburg.de>
From: Luke Mewburn <lukem@wasabisystems.com>
List: tech-userlevel
Date: 08/20/2001 09:15:12
On Sun, Aug 19, 2001 at 05:07:34PM +0200, Hubert Feyrer wrote:
> On Sun, 19 Aug 2001, Luke Mewburn wrote:
> > Modified Files:
> > 	basesrc/sbin/fsirand: fsirand.8 fsirand.c
> > 
> > Log Message:
> > - add -F - manipulate a file system image in a regular file (instead of
> >   a special device).
> 
> I see this -F added to ~all filesystem utilities. Is that really
> necessary? IIRC there's the Unix philosophy of "everything is a file", so
> why is there a difference when giving a filename over /dev/somedisk?
> Can't the fools be at least made auto-detect if th eunderlying thing is a
> disk image over a real disk?

Many of those tools complain if they're not given a block or character
special device, and some also access the disklabel of the underlying
device. An image in a regular file satisfies neither of these
properties.

As supporting file system images in regular files is useful
functionality, yet not necessarily something we want on by default
because it changes existing behaviour, I'm adding an explicit flag
(-F) which allows specific control over the new functionality for
safety and compatibility reasons.

Luke.