From owner-freebsd-hackers@FreeBSD.ORG Sun Jul 20 17:10:50 2008 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 88A2B1065679 for ; Sun, 20 Jul 2008 17:10:50 +0000 (UTC) (envelope-from thierry.herbelot@laposte.net) Received: from smtp4-g19.free.fr (smtp4-g19.free.fr [212.27.42.30]) by mx1.freebsd.org (Postfix) with ESMTP id 2193D8FC1F for ; Sun, 20 Jul 2008 17:10:49 +0000 (UTC) (envelope-from thierry.herbelot@laposte.net) Received: from smtp4-g19.free.fr (localhost.localdomain [127.0.0.1]) by smtp4-g19.free.fr (Postfix) with ESMTP id 7A84F3EA0AF for ; Sun, 20 Jul 2008 19:10:48 +0200 (CEST) Received: from mail.herbelot.nom (bne75-4-82-227-159-103.fbx.proxad.net [82.227.159.103]) by smtp4-g19.free.fr (Postfix) with ESMTP id 3F5663EA112 for ; Sun, 20 Jul 2008 19:10:48 +0200 (CEST) Received: from diversion.herbelot.nom (diversion.herbelot.nom [192.168.2.6]) by mail.herbelot.nom (8.14.1/8.14.1) with ESMTP id m6KHAkUo021034 for ; Sun, 20 Jul 2008 19:10:47 +0200 (CEST) From: Thierry Herbelot To: freebsd-hackers@freebsd.org Date: Sun, 20 Jul 2008 19:10:39 +0200 User-Agent: KMail/1.9.7 References: <200807190723.47208.thierry.herbelot@laposte.net> In-Reply-To: <200807190723.47208.thierry.herbelot@laposte.net> X-Warning: Windows can lose your files X-Op-Sys: Le FriBi de la mort qui tue X-Org: TfH&Co X-MailScanner: Found to be clean MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit Content-Disposition: inline Message-Id: <200807201910.40171.thierry.herbelot@laposte.net> Subject: Re: NFS locking from a qemu machine ? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jul 2008 17:10:50 -0000 Le Saturday 19 July 2008, Thierry Herbelot a écrit : > Hello, > > I'm trying to use NFS locking from an NFS client running in a qemu virtual > PC to an NFS server running on the host machine, but with no success so far > : > > configuration for the host PC (server) : > operating system : FreeBSD 7.0-Stable > > % cat /etc/exports > /shared/ 127.0.0.1 > > and in /etc/rc.conf : > nfs_server_enable="YES" > weak_mountd_authentication="YES" # Allow non-root mount requests to be > served. rpcbind_enable="YES" # Run the portmapper service > (YES/NO). rpc_lockd_enable="YES" # Run NFS rpc.lockd needed for > client/server. rpc_statd_enable="YES" # Run NFS rpc.statd needed > for client/server. > > configuration for the qemu machine (client) : > operating system : FreeBSD 7.0-Stable > > in /etc/fstab : > 10.0.2.2:/shared /shared nfs rw 0 0 > > in /etc/rc.conf : > nfs_client_enable="YES" # This host is an NFS client (or NO). > rpcbind_enable="YES" # Run the portmapper service (YES/NO). > rpc_lockd_enable="YES" # Run NFS rpc.lockd needed for > client/server. rpc_statd_enable="YES" # Run NFS rpc.statd needed > for client/server. > > > I'm using tools/regression/file/flock to check the correct file locking : > $ ./flock ../../shared > > and the client machine seems locked > > the ethernet traffic between the client and the server when the client is > blocked is the following : > > (the "tunnel" port is the one used by the lockmanager according to rpcinfo) this is most likely due to misconfiguration, as the nat-ed configuration used for the qemu client does not allow back communication from the server lockd to the client rpcbind. TfH