Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Jan 2003 17:43:42 -0200
From:      "Daniel C. Sobral" <dcs@tcoip.com.br>
To:        phk@FreeBSD.ORG
Cc:        freebsd-current@FreeBSD.ORG
Subject:   Re: I want a sysctl kern.allow_shooting_into_my_foot!
Message-ID:  <3E2EF46E.20600@tcoip.com.br>
In-Reply-To: <25074.1043238359@critter.freebsd.dk>
References:  <25074.1043238359@critter.freebsd.dk>

next in thread | previous in thread | raw e-mail | index | archive | help
phk@FreeBSD.ORG wrote:
> 
> Hmm, since this happens during boot, you cannot set the debug flag
> with sysctl in time, so you have to compile a custom kernel for it:
> 
> in sys/geom/geom_kern.c change:
> 
> 	int g_debugflags;
> 
> to
> 	int g_debugflags = G_T_ACCESS;
> 
> and recompile + reboot.
> 
> This will make GEOM printf all "access" (ie: open/close) changes and
> you should hopefully be able to deduce where the open of your MO comes
> from.
> 
> If this is not enough, you can try to set
> 
> 	int g_debugflags = G_T_ACCESS | G_T_TOPOLOGY;
> 
> But that will result in much more debugging output.
> 
> You can turn this debugging off from userland with:
> 	sysctl kern.geom.debugflags=0

Why not make it a loader tunable?

-- 
Daniel C. Sobral                   (8-DCS)
Gerencia de Operacoes
Divisao de Comunicacao de Dados
Coordenacao de Seguranca
TCO
Fones: 55-61-313-7654/Cel: 55-61-9618-0904
E-mail: Daniel.Capo@tco.net.br
         Daniel.Sobral@tcoip.com.br
         dcs@tcoip.com.br

Outros:
	dcs@newsguy.com
	dcs@freebsd.org
	capo@notorious.bsdconspiracy.net

Art is anything you can get away with.
		-- Marshall McLuhan.


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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3E2EF46E.20600>