Date: Mon, 13 Sep 2004 14:30:29 -0600 From: Scott Long <scottl@samsco.org> To: Sam <sah@softcardsystems.com> Cc: freebsd-arch@freebsd.org Subject: Re: 4.x device failure? Message-ID: <41460365.50508@samsco.org> In-Reply-To: <Pine.LNX.4.60.0409131505220.6275@athena> References: <82341.1095101771@critter.freebsd.dk> <Pine.LNX.4.60.0409131505220.6275@athena>
next in thread | previous in thread | raw e-mail | index | archive | help
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 <Pine.LNX.4.60.0409131202270.6275@athena>, 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"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?41460365.50508>