Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 130435 - slocate 3.1 cron script chowns to group slocate which was changed to locate in 2.7-r8
Summary: slocate 3.1 cron script chowns to group slocate which was changed to locate i...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
: 130449 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-04-19 00:50 UTC by Vlastimil Babka (Caster) (RETIRED)
Modified: 2006-04-20 22:22 UTC (History)
11 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2006-04-19 00:50:15 UTC
This is what dispatch-conf shows after upgrading slocate 2.7-r8 to 3.1

--- /etc/cron.daily/slocate     2006-04-17 20:16:22.000000000 +0200
+++ /etc/cron.daily/._cfg0000_slocate   2006-04-19 09:29:57.000000000 +0200
@@ -1,6 +1,6 @@
 #! /bin/sh

-if [ -x /usr/bin/updatedb ]
+if [ -x /usr/bin/slocate ]
 then
        if [ -f /etc/updatedb.conf ]
        then
@@ -8,4 +8,5 @@
        else
                nice /usr/bin/updatedb -f proc
        fi
+       chown root.slocate /var/lib/slocate/slocate.db
 fi

But I had version 2.7-r8 which told me to change the group name and I followed, so:

$ grep locate /etc/group
locate:x:245:

After manually deleting slocate.db and running updatedb, it's owned by root.locate, so I guess the whole chown line is not needed?
Comment 1 Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2006-04-19 05:43:16 UTC
The question also is, what woul happen when going to 3.1 from <2.7-r8 - would it also rename the group to "locate", as 2.7-r8 does, or is 3.1 expecting "slocate" not just in cron script?
Also wondering that 3.1 went directly to stable, after the long stabilisation of 2.7-r8...
Comment 2 Attila Tóth 2006-04-19 06:03:59 UTC
*** Bug 130449 has been marked as a duplicate of this bug. ***
Comment 3 Attila Tóth 2006-04-19 06:07:15 UTC
(In reply to comment #1)
> The question also is, what woul happen when going to 3.1 from <2.7-r8 - would
> it also rename the group to "locate", as 2.7-r8 does, or is 3.1 expecting
> "slocate" not just in cron script?
> Also wondering that 3.1 went directly to stable, after the long stabilisation
> of 2.7-r8...
> 

It's also a question to be answered, that which kind of new behaviour introduced by this new version creates the need for this new line, if the pervious ones were functioning correctly without it.
I have RBAC system installed, and I like to give a process only the resonable rights.

Regards,
Dw.
Comment 4 Oldrich Jedlicka 2006-04-19 12:16:47 UTC
I just upgraded to 3.1 and I was asked to make 'groupmod -n locate slocate'. So I renamed the group. The owner of /var/lib/slocate/slocate.db is now root.locate (group number stayed the same, only the name changed).

Fix the cron script, please. It should use root.locate, not root.slocate.
Comment 5 Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2006-04-20 04:20:31 UTC
OK it's no longer stable at least, see bug 130562
Comment 6 Rick Morra 2006-04-20 10:09:45 UTC
slocate-3.1 updates ok for me using the cron script from 2.7-r8 and the name of group 245 set to 'locate' in arch x86.

/var/lib/slocate/slocate.db ends up with ownership root.locate and it can be read by /usr/bin/locate as installed by 3.1.
Comment 7 SpanKY gentoo-dev 2006-04-20 22:22:48 UTC
fixed in 3.1-r1