From owner-freebsd-current Tue Jan 21 14: 6:38 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D9AEF37B401 for ; Tue, 21 Jan 2003 14:06:36 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0D42843F18 for ; Tue, 21 Jan 2003 14:06:36 -0800 (PST) (envelope-from phk@freebsd.org) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.6/8.12.6) with ESMTP id h0LM656Z018700; Tue, 21 Jan 2003 23:06:05 +0100 (CET) (envelope-from phk@freebsd.org) To: Joerg Wunsch Cc: freebsd-current@freebsd.org Subject: Re: I want a sysctl kern.allow_shooting_into_my_foot! From: phk@freebsd.org In-Reply-To: Your message of "Tue, 21 Jan 2003 22:59:40 +0100." <20030121225940.G37868@uriah.heep.sax.de> Date: Tue, 21 Jan 2003 23:06:05 +0100 Message-ID: <18699.1043186765@critter.freebsd.dk> Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <20030121225940.G37868@uriah.heep.sax.de>, Joerg Wunsch writes: >As phk@freebsd.org wrote: > >> Hang on. >> >> If no disk partitions of any kind are open, there is nothing which >> prevents you from doing a "dd if=/dev/zero of=/dev/da0 bs=64k". > >My guess is that vinum scanned the disks when starting, but found >nothing on it. And forgot to close them again ? Well, you know where to look for that bug then :-) (If you look in the "sysctl -b kern.geom.confxml" output, you will be able to see the read/write/exclusive open counts, look for "r%dw%de%d" strings.) >However, my really concern is what i wrote in the subject: i do want >something like an option -f for all of this. GEOM will not allow you to do things which will panic your kernel, and I'm not going to add that facility, we already have enough panic(8) implementations if you want one. >> Now, if you tell me you tried >> dd if=/dev/zero of=/dev/da0c bs=64k >> it would stop you (notice ^) > >Sorry, this was too unexpected to me, and meanwhile i've found a way >to trash and relabel that disk, so i cannot reproduce it anymore. Why >the sudden `c' partition for it? I thought this is rather considered >obsolete, and was merely a historical feature used in a time when >there was no such method like accessing /dev/da0 directly? This >sounds like a step 5 years backwards to me. I tried to say that if you tried da0c it should stop you, not that it should work. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message