Date: Sat, 21 Apr 2007 12:11:37 +0200 From: Pawel Jakub Dawidek <pjd@FreeBSD.org> To: Robert Watson <rwatson@FreeBSD.org> Cc: Greg Lewis <glewis@eyesbeyond.com>, freebsd-current@FreeBSD.org, "Stephane E. Potvin" <sepotvin@FreeBSD.org> Subject: Re: ZFS, procfs and java Message-ID: <20070421101137.GA46583@garage.freebsd.pl> In-Reply-To: <20070421110405.Y39377@fledge.watson.org> References: <46297494.5050104@FreeBSD.org> <20070421110405.Y39377@fledge.watson.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--ReaqsoxgOBHFXBhH Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Apr 21, 2007 at 11:08:21AM +0100, Robert Watson wrote: >=20 > On Fri, 20 Apr 2007, Stephane E. Potvin wrote: >=20 > >It seems that the ZFS cache (dnlc) doesn't update the VSF_namecache fiel= ds in the vnodes (v_cache_src, v_cache_dst and v_dd). This unfortunately ca= uses the file link in=20 > >/proc/curproc to return "unknown" as it uses vn_fullpath which relies on= the namecache fields to be set correctly. > > > >Java uses /proc/curproc/file to know where to find its libraries and doe= sn't expect the "unknown" return value returned when using ZFS (due to vn_f= ullpath failing). The=20 > >attached patches to the java/jdk15 port fixes this issue but it doesn't = fix the root of the problem. > > > >Would it be possible to add support in dnlc for updating the VFS namecac= he fields or to add knowledge of dnlc into vn_fullpath? >=20 > No application should rely on the correctness and usefulness of /proc/cur= proc/file -- the conversion from a vnode to a pathname is inherently unreli= able. Likewise,=20 > properly ported applications should not rely on the availability of procf= s, as its use is deprecated. My advice would be to talk to the Java porter= s about entirely=20 > eliminating this dependency. >=20 > As a matter of debugging/logging convenience, it would be nice if ZFS imp= lemented the name cache hooks, since using vn_fullpath is useful for procfs= monitoring of process=20 > address space, audit, etc. I tried to teach ZFS about our namecache (the code is under FREEBSD_NAMECACHE define), but it didn't worked stable, I'm probably still missing something. On the other hand it was rather easy to use namecache from OpenSolaris with ZFS (DNLC). --=20 Pawel Jakub Dawidek http://www.wheel.pl pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --ReaqsoxgOBHFXBhH Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (FreeBSD) iD8DBQFGKeNZForvXbEpPzQRArM6AKDqcjh7iPTuKDjLJRv0W2SNLyJNHgCgsaNn lcfPxj4ajci/24OrJCk7aGU= =yhaC -----END PGP SIGNATURE----- --ReaqsoxgOBHFXBhH--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070421101137.GA46583>