From owner-freebsd-arch@FreeBSD.ORG Mon Sep 13 20:33:40 2004 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 20C1916A4CE for ; Mon, 13 Sep 2004 20:33:40 +0000 (GMT) Received: from pooker.samsco.org (pooker.samsco.org [168.103.85.57]) by mx1.FreeBSD.org (Postfix) with ESMTP id 57C8243D2F for ; Mon, 13 Sep 2004 20:33:37 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from [192.168.0.11] (junior-wifi.samsco.home [192.168.0.11]) (authenticated bits=0) by pooker.samsco.org (8.12.11/8.12.10) with ESMTP id i8DKYYMr030651; Mon, 13 Sep 2004 14:34:34 -0600 (MDT) (envelope-from scottl@samsco.org) Message-ID: <41460365.50508@samsco.org> Date: Mon, 13 Sep 2004 14:30:29 -0600 From: Scott Long User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.2) Gecko/20040831 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Sam References: <82341.1095101771@critter.freebsd.dk> In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, hits=0.0 required=3.8 tests=none autolearn=no version=2.63 X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on pooker.samsco.org cc: Poul-Henning Kamp cc: freebsd-arch@freebsd.org Subject: Re: 4.x device failure? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Sep 2004 20:33:40 -0000 It's not impossible to remove a disk object from a running system, you just have to be very careful about it. Like I mentioned before, keep a reference count on your disk, and only call disk_destroy() when it has gone to 0 (and prevent new opens while you are waiting to destroy). This isn't great, of course, since you can't destroy a disk with active references, but it's not impossible. Scott Sam wrote: > Ah. Well that answers it. I'll fail unloading of the > module if devices are open. > > This leads to a curiosity as to how the RAID > failover modules work at all. I guess if you abstract > the real disk(s) under a logical disk you can change > the bottom layer without affecting the top. I'll have > to look at that code a little closer. > > Thanks - > > Sam > > On Mon, 13 Sep 2004, Poul-Henning Kamp wrote: > >> In message , Sam writes: >> >>> >> >>> Surely there's a way to pull a disk out from under >>> those that have it open without a panic? Opinions? >> >> >> No, we're not quite there yet. I/O errors from disk devices very >> often leads to filesystem or buffer cache panics. We're working >> on it. >> >> -- >> 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. >> _______________________________________________ >> freebsd-arch@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-arch >> To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" >> > _______________________________________________ > freebsd-arch@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org"