From owner-freebsd-current@FreeBSD.ORG Fri Jun 12 13:16:31 2009 Return-Path: Delivered-To: freebsd-current@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6BB90106568D for ; Fri, 12 Jun 2009 13:16:31 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id AC3938FC4B for ; Fri, 12 Jun 2009 13:16:29 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id QAA09658; Fri, 12 Jun 2009 16:16:26 +0300 (EEST) (envelope-from avg@icyb.net.ua) Message-ID: <4A325529.5000409@icyb.net.ua> Date: Fri, 12 Jun 2009 16:16:25 +0300 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.21 (X11/20090406) MIME-Version: 1.0 To: Alexander Best References: In-Reply-To: X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-current@FreeBSD.org Subject: Re: strange newfs results X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Jun 2009 13:16:33 -0000 on 12/06/2009 11:08 Alexander Best said the following: > hi there, > > i was surprised to see the following: > > 1. pax -w -f /dev/ad0p2 . > 2. file -s /dev/ad0p2 -> POSIX tar archive > 3. newfs -U -L usr /dev/ad0p2 > 4. file -s /dev/ad0p2 -> POSIX tar archive > > mounting/reading/writing ad0p2 however works like one expects from a ufs > partition. i added a `dd if=/dev/zero of=/dev/ad0p2 bs=1m count=10` between > step 2 and 3 and now ad0p2 is recognised by `file -s` as "Unix Fast File > system". > > is this a bug or a feature? i'm running r193846M. Neither - I wonder why you didn't write the subject as "strange file results" :-) Did you try pax -r after newfs? You see, newfs doesn't wipe the whole media, it just writes out the blocks that it UFS needs, so some (many many) blocks written by pax remain unchanged. And it's a matter of file's internal tasting order which blocks with "magic" byte pattern it would detect first. -- Andriy Gapon