20

OS: Ubuntu 19.10

When I ran locate plymouth, I got

dkb@dkb-uee:~$ locate plymouth

Command 'locate' not found, but can be installed with:

sudo apt install mlocate

dkb@dkb-uee:~$ 

So I installed mlocate and now locate works.

As far as I can remember, since Ubuntu 11.04, locate has always been there.

Why was it excluded in Ubuntu 19.10?

26

There was this thread: mlocate - what is it good for? with this:

The Ubuntu Foundations team was recently looking at an issue with mlocate[1] and the effect it has on all users of Ubuntu. While that specific issue is fixable there are also issues[2,3] with keeping PRUNEFS and PRUNEPATHS current in updatedb.conf. So we ended up questioning the usefulness of installing mlocate by default on systems at all. We believe that find is an adequate replacement for mlocate ...

This initial post called for opinions on the matter.

Later, in the same thread, there's this:

My own sense is that this is not a server vs desktop thing; there are users of locate, to be sure, but I believe they are a very small minority on both desktop and server (small on desktop because the user will generally use the gui instead; small on server because most server use is not interactive at the shell). I don't think the benefit of having locate available by default justifies the daily disk thrashing / energy usage on every Ubuntu machine everywhere. I think it's not onerous for those who want to use locate to manually install it the first time they need it on a machine.

And this:

Well, I don't think this is an argument for keeping mlocate installed by default on desktops, because effectively this means that you have TWO indexers on your desktop system - both tracker and mlocate. It looks like nautilus currently depends on tracker, so I'm not sure how one would uninstall it and usefully fall back to the mlocate backend anyway, but at most I'd say this should be expressed as 'Depends: tracker | mlocate' in nautilus, and not have mlocate kept around on the system updating its database daily just in case a user removes tracker.

The bottom line is that if you want it, just install it.

  • 2
    What's the GUI alternative, is it as fast as locate and does it not have the same drawbacks? – Eric Duminil Oct 26 '19 at 9:34
  • 2
    @EricDuminil I'm not sure any GUI alternative would be as fast. And, I've seen more than a fair number of complaints about GNOME's tracker and KDE Plasma's baloo hogging CPU. I have only quoted, and very partially at that, the arguments for not including mlocate. There are several posts there that didn't agree. – DK Bose Oct 26 '19 at 10:21
  • 3
    "small on server because most server use is not interactive at the shell" What?? How else do you manage servers? – RonJohn Oct 26 '19 at 15:18
  • "disk thrashing" meh home users should be on SSDs by now! – Lightness Races with Monica Oct 26 '19 at 20:22
  • 2
    @RonJohn Most server use is the consumption of that server's services. Of course you have to administer the server, and you'll do that at the shell, but if you're spending more time administering the server than people are spending actually consuming the services, you may wish to ask whether it's economical to run the server in the first place. That, or your administration is kind of broken. – Lightness Races with Monica Oct 26 '19 at 20:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.