Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 7 Oct 2011 14:26:41 -0400
From:      Arnaud Lacombe <lacombar@gmail.com>
To:        Warren Block <wblock@wonkity.com>
Cc:        Poul-Henning Kamp <phk@phk.freebsd.dk>, freebsd-current@freebsd.org, Benjamin Kaduk <kaduk@mit.edu>
Subject:   Re: aliasing (or renaming) kern.geom.debugflags
Message-ID:  <CACqU3MXtCF2u7SLYs8Fg3oqyzpS=GTVMTXx_9E6zYhfVEpRNow@mail.gmail.com>
In-Reply-To: <alpine.BSF.2.00.1110071210040.2450@wonkity.com>
References:  <80750.1318010551@critter.freebsd.dk> <alpine.BSF.2.00.1110071210040.2450@wonkity.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi,

On Fri, Oct 7, 2011 at 2:13 PM, Warren Block <wblock@wonkity.com> wrote:
> On Fri, 7 Oct 2011, Poul-Henning Kamp wrote:
>
>> In message <alpine.GSO.1.10.1110071341430.882@multics.mit.edu>, 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 <phk@FreeBSD.org>
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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CACqU3MXtCF2u7SLYs8Fg3oqyzpS=GTVMTXx_9E6zYhfVEpRNow>