From owner-freebsd-current@FreeBSD.ORG Mon Jun 29 09:56:13 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4A1A21065674 for ; Mon, 29 Jun 2009 09:56:13 +0000 (UTC) (envelope-from asmrookie@gmail.com) Received: from mail-fx0-f218.google.com (mail-fx0-f218.google.com [209.85.220.218]) by mx1.freebsd.org (Postfix) with ESMTP id 9AE858FC13 for ; Mon, 29 Jun 2009 09:56:12 +0000 (UTC) (envelope-from asmrookie@gmail.com) Received: by fxm18 with SMTP id 18so1764774fxm.43 for ; Mon, 29 Jun 2009 02:56:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:in-reply-to :references:date:x-google-sender-auth:message-id:subject:from:to:cc :content-type:content-transfer-encoding; bh=mIVQI17NOExRbSRmRK8ELiJp93MjRgCudWH9N7wy2HM=; b=U1BYC7EDyenimIek8btf+9DK3MyF1ds5RUCH4Vr8NJWTbXxKG5+pX5cQCS1t9Vd596 YNbRVK5fluod8lMJQLVvMENGFjYL87LwY6LTKcRhaM7jfLwZsPwy0rkss5TvEKzdKLtc qADjTnZcga9B78RMovkPy9SQxF1aXICpZCwao= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=EuWYtjmT4hlxQVMEHFcjLCQZZN0Vfs+i4Mc9LYpeXy5xnc9ApubaNa0CEB+fKdyqHS f6hVmZRJprkN66cwU9bMQmWS6feblBRBiUMMT8Lf6rcGsaEmDHvU+0cstA7VTEL3OZJL lojFzyUq8PTrEVJcvYCjZPi1E0Vji1Yhalnb0= MIME-Version: 1.0 Sender: asmrookie@gmail.com Received: by 10.223.113.9 with SMTP id y9mr4272783fap.19.1246269371623; Mon, 29 Jun 2009 02:56:11 -0700 (PDT) In-Reply-To: References: Date: Mon, 29 Jun 2009 11:56:11 +0200 X-Google-Sender-Auth: f51c70cf27ded9c1 Message-ID: <3bbf2fe10906290256x4bfbe263jccef017a557f9410@mail.gmail.com> From: Attilio Rao To: Rick Macklem Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: freebsd-fs@freebsd.org, freebsd-current@freebsd.org Subject: Re: umount -f implementation X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Jun 2009 09:56:13 -0000 2009/6/29 Rick Macklem : > I just noticed that when I do the following: > - start a large write to an NFS mounted fs > - network partition the server (unplug a net cable) > - do a "umount -f " on the machine > > that it gets stuck trying to write dirty blocks to the server. > > I had, in the past, assumed that a "umount -f" of an NFS mount would be > used to get rid of an NFS mount on an unresponsive server and that loss > of "writes in progress" would be expected to happen. > > Does that sound correct? (In other words, an I seeing a bug or a feature?) While that should be real in principle (immediate shutdown of the fs operation and unmounting of the partition) it is totally impossible to have it completely unsleeping, so it can happen that also umount -f sleeps / delays for some times (example: vflush). Currently, umount -f is one of the most complicated thing to handle in our VFS because it puts as requirement that vnodes can be reclaimed in any moment, adding complexity and possibility for races. What's the fix for your problem? Thanks, Attilio -- Peace can only be achieved by understanding - A. Einstein