From owner-freebsd-stable@FreeBSD.ORG Thu Nov 29 14:01:12 2012 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 3070BD60; Thu, 29 Nov 2012 14:01:12 +0000 (UTC) (envelope-from gpalmer@freebsd.org) Received: from noop.in-addr.com (mail.in-addr.com [IPv6:2001:470:8:162::1]) by mx1.freebsd.org (Postfix) with ESMTP id EC7018FC14; Thu, 29 Nov 2012 14:01:11 +0000 (UTC) Received: from gjp by noop.in-addr.com with local (Exim 4.80.1 (FreeBSD)) (envelope-from ) id 1Te4fn-000Ofe-5Z; Thu, 29 Nov 2012 09:01:03 -0500 Date: Thu, 29 Nov 2012 09:01:03 -0500 From: Gary Palmer To: Doug Hardie Subject: Re: Library Problem Message-ID: <20121129140103.GA27849@in-addr.com> References: <4AA267EA-8FC8-42E8-A885-F22F4DC524D0@lafn.org> <997CEAC4-4F57-4C33-BDCE-EE21AD607DC0@fisglobal.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: gpalmer@freebsd.org X-SA-Exim-Scanned: No (on noop.in-addr.com); SAEximRunCond expanded to false Cc: Devin Teske , FreeBSD-STABLE Mailing List , Devin Teske X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Nov 2012 14:01:12 -0000 On Wed, Nov 28, 2012 at 10:46:51PM -0800, Doug Hardie wrote: > > On 28 November 2012, at 20:01, Devin Teske wrote: > > > > > On Nov 28, 2012, at 7:36 PM, Doug Hardie wrote: > > > >> I have installed 4 systems from the same FreeBSD 9.1-RC3 disk. Three of them worked just fine. The last one is causing a problem. It will not look in /usr/local/lib/ for shared libraries. I did the standard install, moved in some source, compiled it and tried to run it. The library is there. On the working systems ktrace shows: > >> > >> 2259 intro CALL access(0x28066000,0) > >> 2259 intro NAMI "/lib/libsermons.so" > >> 2259 intro RET access -1 errno 2 No such file or directory > >> 2259 intro CALL access(0x28066000,0) > >> 2259 intro NAMI "/usr/lib/libsermons.so" > >> 2259 intro RET access -1 errno 2 No such file or directory > >> 2259 intro CALL access(0x28066000,0) > >> 2259 intro NAMI "/usr/lib/compat/libsermons.so" > >> 2259 intro RET access -1 errno 2 No such file or directory > >> 2259 intro CALL access(0x28066000,0) > >> 2259 intro NAMI "/usr/local/lib/libsermons.so" > >> 2259 intro RET access 0 > >> > >> > >> On the failing system ktrace shows: > >> > >> 6746 intro NAMI "/lib/libsermons.so" > >> 6746 intro RET access -1 errno 2 No such file or directory > >> 6746 intro CALL access(0x28066000,0) > >> 6746 intro NAMI "/usr/lib/libsermons.so" > >> 6746 intro RET access -1 errno 2 No such file or directory > >> 6746 intro CALL access(0x28066000,0) > >> 6746 intro NAMI "/usr/lib/compat/libsermons.so" > >> 6746 intro RET access -1 errno 2 No such file or directory > >> 6746 intro CALL access(0x28066000,0) > >> 6746 intro NAMI "/lib/libsermons.so" > >> 6746 intro RET access -1 errno 2 No such file or directory > >> 6746 intro CALL access(0x28066000,0) > >> 6746 intro NAMI "/usr/lib/libsermons.so" > >> 6746 intro RET access -1 errno 2 No such file or directory > >> 6746 intro CALL write(0x2,0x28060080,0x3c) > >> 6746 intro GIO fd 2 wrote 60 bytes > >> "Shared object "libsermons.so" not found, required by "intro"" > >> > >> > >> It never attempts to check /usr/local/lib. I can't find any configuration item that affects that. How can this be fixed? > >> > > > > What's the value of "ldconfig_paths" in rc.conf(5)? > > > > That includes: > > /etc/rc.conf > > /etc/rc.conf.local (if it exists) > > /etc/defaults/rc.conf > > > > Here on my 9.0-R system it has the following in /etc/defaults/rc.conf: > > /usr/lib/compat /usr/local/lib /usr/local/lib/compat/pkg > > > /etc/defaults/rc.conf has: > > ldconfig_paths="/usr/lib/compat /usr/local/lib /usr/local/lib/compat/pkg" > > > /etc/rc.conf has nothing for ldconfig_paths. Check that /usr/local/lib doesn't have group or other write perms. ldconfig ignores directories that are group/world writable. To fix: chmod go-w /usr/local/lib sh /etc/rc.d/ldconfig start Gary