From cjohnson@galahad.camelot.com  Tue Feb 29 06:20:27 2000
Return-Path: <cjohnson@galahad.camelot.com>
Received: from galahad.camelot.com (Galahad.Camelot.com [192.55.203.135])
	by hub.freebsd.org (Postfix) with ESMTP id 68B6037BB52
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 29 Feb 2000 06:20:27 -0800 (PST)
	(envelope-from cjohnson@galahad.camelot.com)
Received: by galahad.camelot.com (Postfix, from userid 2455)
	id 30BEF12C2B; Tue, 29 Feb 2000 09:20:24 -0500 (EST)
Message-Id: <20000229142024.30BEF12C2B@galahad.camelot.com>
Date: Tue, 29 Feb 2000 09:20:24 -0500 (EST)
From: cjohnson@galahad.camelot.com
Reply-To: cjohnson@galahad.camelot.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: locate.updatedb fails when /root is 750
X-Send-Pr-Version: 3.2

>Number:         17074
>Category:       bin
>Synopsis:       locate.updatedb fails when /root is 750
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Feb 29 06:30:01 PST 2000
>Closed-Date:    Tue Feb 29 07:46:26 PST 2000
>Last-Modified:  Tue Feb 29 07:47:16 PST 2000
>Originator:     Christopher T. Johnson
>Release:        FreeBSD 4.0-CURRENT i386 And back to 3.1
>Organization:
Paladin Software
>Environment:
Repeatable in FreeBSD 3.1-STABLE Feb 1999 through FreeBSD 4.0-Current Feb 2000

>Description:
If the root's home directory is set such that "nobody" can not read it
then the locate.updatedb script will fail when run from
/etc/periodic/weekly/310.locate

Test:
	su
	cd
	chmod 750 .
	echo /usr/libexec/locate.updatedb | nice -5 su -fm nobody
	find .: permission denied

And the locate database is not updated.  This becomes a problem because
/etc/periodic/weekly/310.locate does run from the /root and does
do the locate as nobody.


	

>How-To-Repeat:

see description

>Fix:

Add a "cd /var/tmp" or "cd /tmp" in locate.updatedb


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: sheldonh 
State-Changed-When: Tue Feb 29 07:46:26 PST 2000 
State-Changed-Why:  
Already fixed in 310.locate rev1.3.  Update your installed periodic 
scripts. 
(mergemaster(1) will help with that, by the way) 
>Unformatted:
 If the root's home directory is set such that "nobody" can not read it
 then the locate.updatedb script will fail when run from
 /etc/periodic/weekly/310.locate
