From owner-freebsd-current@FreeBSD.ORG Fri Oct 7 18:26:43 2011 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 10BD4106566B for ; Fri, 7 Oct 2011 18:26:43 +0000 (UTC) (envelope-from lacombar@gmail.com) Received: from mail-wy0-f182.google.com (mail-wy0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id 9CB2F8FC08 for ; Fri, 7 Oct 2011 18:26:42 +0000 (UTC) Received: by wyj26 with SMTP id 26so5741707wyj.13 for ; Fri, 07 Oct 2011 11:26:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=7D8ruvpF0XCTRP6NNioDkJK7/ZDd3tWGOmdChnyTnlg=; b=HXOsEhN0guUDPz2K7TzbCcpWlpWS3Xj2jrH5mcmJ8qKIrCIjAY/7fvWXkcfbe6ivj5 QqSPj6CFcjIJjb7GcON08mCi3cldV4kKZIvJXhMVZp72ZxnOeTk1B5Ysy1hzsxINaeE/ UVNADvvjI7B7fNA3AHjhm3SIVDrYUx4xNGMDs= MIME-Version: 1.0 Received: by 10.227.135.130 with SMTP id n2mr2748908wbt.51.1318012001734; Fri, 07 Oct 2011 11:26:41 -0700 (PDT) Received: by 10.180.103.33 with HTTP; Fri, 7 Oct 2011 11:26:41 -0700 (PDT) In-Reply-To: References: <80750.1318010551@critter.freebsd.dk> Date: Fri, 7 Oct 2011 14:26:41 -0400 Message-ID: From: Arnaud Lacombe To: Warren Block Content-Type: text/plain; charset=ISO-8859-1 Cc: Poul-Henning Kamp , freebsd-current@freebsd.org, Benjamin Kaduk Subject: Re: aliasing (or renaming) kern.geom.debugflags 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, 07 Oct 2011 18:26:43 -0000 Hi, On Fri, Oct 7, 2011 at 2:13 PM, Warren Block wrote: > On Fri, 7 Oct 2011, Poul-Henning Kamp wrote: > >> In message , Benjamin >> Kaduk >> writes: >> >>> Now, an ordinary user who is >>> doing this for the first time might ask, "why do I need to do something >>> with 'debugflags' in order to make a USB stick? >> >> Which is the exactly right question to ask. >> >> The procedure documented is clearly flawed. > > Probably a misunderstanding on my part, since I suggested it to Glen. Can't > recall the circumstances exactly. > > The next question would be: what is the correct procedure? > I'd guess the procedure involves shooting your feet: from `sys/geom/geom_subr.c': /* If foot-shooting is enabled, any open on rank#1 is OK */ if ((g_debugflags & 16) && pp->geom->rank == 1) ; this was introduced by phk@ himself in: commit 641a10a0cb4ca86785ef13fce9343bc34c30f326 Author: phk Date: Wed Feb 12 09:48:27 2003 +0000 Implement a handle for efficient implementation of perforations in lower extremities. Setting bit 4 in debugflags (sysctl kern.geom.debugflags=16) will allow any open to succeed on rank#1 providers. This will generally correspond to the physical disk devices: ad0, da0, md0 etc. This fundamentally violates the mechanics of GEOMs autoconfiguration, and is only provided as a debugging facility, so obviously error reports on GEOM where this bit is or has been set will not be accepted. - Arnaud