You are not logged in.

Announcement

Due to heavy spamming of forums registration is going in stages. If you wish to register as a new user with ArchBang Forums, first register and then send an e-mail to: archbangforums at gmail dot com. It should contain the problem you want to discuss or some other AB related content. You will be promoted from registering member with no posting rights to new member with posting rights after that. If your mail is ignored you haven't fulfilled the requirements.

#1 2011-11-03 06:10:40

siva.devel
Member
Registered: 2011-10-07
Posts: 14

Which package contains Updatedb/locate commands?

Hi,

Can someone point which package contains updatedb/locate commands? I could not get it with pacman -Ss - being a very commonly used command it would be great if those two are in default installation.

./Siva

Offline

#2 2011-11-03 06:31:03

Kruppt
Moderator
From: Blue Ridge Mountains, NC
Registered: 2010-12-20
Posts: 299

Re: Which package contains Updatedb/locate commands?

siva.devel wrote:

Hi,

Can someone point which package contains updatedb/locate commands? I could not get it with pacman -Ss - being a very commonly used command it would be great if those two are in default installation.

./Siva

rlocate and rlocate-utils

or

mlocate

Offline

#3 2012-04-21 08:29:33

attila123
New member
Registered: 2012-04-21
Posts: 1

Re: Which package contains Updatedb/locate commands?

Hi, I am a  newbie to Arch and not too experienced in linux generally. I landed here after having the same question and doing a google search.

I got confused on the various locate versions mentioned, so just did a research and now I share the results, so that maybe it will be useful for other newbies as well. Links below may not be the official websites for these commands, but just I found quickly.

http://carolina.mff.cuni.cz/~trmac/blog/mlocate/
mlocate is a new locate implementation. The ‘m’ stands for “merging”: updatedb reuses the existing database to avoid rereading most of the file system, which makes updatedb faster and does not trash the system caches as much.

http://rlocate.sourceforge.net/
rlocate is an implementation of the ``locate'' command that is always up-to-date. The database that the original locate uses is usually updated only once a day, so newer files cannot be located right away. The behavior of rlocate is the same as slocate, but it also maintains a diff database that gets updated whenever a new file is created. This is accomplished with rlocate kernel module and daemon. The rlocate kernel module can be compiled only with Linux 2.6 kernels.

http://linux.about.com/library/cmd/blcmdl1_slocate.htm
slocate - Security Enhanced version of the GNU Locate 
<...>
   Secure Locate provides a secure way to index and quickly search for  files on your system. It uses incremental encoding just like GNU locate to compress its database to make searching faster, but it will also store file permissions and ownership so that users will not see files they do not have access to.

After that I wanted to find out how to answer this question with pacman. I found the following thread:
https://bbs.archlinux.org/viewtopic.php?id=81038

So I did:
# pacman -S pkgtools
When it installed it reminded me to do:
# pkgfile --update

Then
$ pkgfile locate
core/mlocate

So I installed mlocate:
# pacman -S mlocate
then
# updatedb
and you can use locate.

Offline

Board footer

Powered by FluxBB