Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Oct 2000 23:32:29 +1100 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        Greg Lehey <grog@lemis.com>
Cc:        "Karsten W. Rohrbach" <karsten@rohrbach.de>, Andre Albsmeier <andre@akademie3000.de>, Marc Tardif <intmktg@CAM.ORG>, freebsd-fs@FreeBSD.ORG, freebsd-scsi@FreeBSD.ORG
Subject:   Re: ccd with other filesystems
Message-ID:  <Pine.BSF.4.21.0010012311270.5871-100000@besplex.bde.org>
In-Reply-To: <20001001114540.G43885@wantadilla.lemis.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 1 Oct 2000, Greg Lehey wrote:

> On Sunday,  1 October 2000 at  4:09:37 +0200, Karsten W. Rohrbach wrote:
> > i dont quite know why it is still possible doing a newfs on a 'c'
> > partition, since the partition type is 'unused' and not
> > '4.2BSD'. newfs should check this and throw an error while providing
> > an expert-only-feature command line option to explicitly override
> > it.
> 
> I think this is a bug in newfs.

This is a feature of newfs.  It is almost device-independent.  E.g., to
create a filesystem in a regular file with no label in sight:

    dd if=/dev/zero of=foo oseek=2779 count=1
    # -v and ./foo work around device dependence.
    # -T floppy is so that I don't have to type a lot of args for this example.
    newfs -v -T floppy ./foo

> It should only create file systems on
> partitions of type 4.2BSD.  Does anybody disagree?  Otherwise I'll fix
> it.

Disagree.  The filesystem type field is normally an output of newfs, not
an input.

> > it is a bad thing[tm] to be able to wedge every single blockdev in your
> > system by (ab)using newfs.
> 
> Agreed.

Disagree.  It is a feature that write(2) works on disk devices (block
devices went away) no matter how it is (ab)used.  (There should be
more write protection for mounted partitions, but a disk without any
of its partitions mounted should be almost just a file.)

Bruce



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-fs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0010012311270.5871-100000>