Learn how to install mlocate with the command sudo apt-get install mlocate on Ubuntus.
Ads
Quick installation of mlocate:
Step 1: Update system:
sudo apt-get update
Step 2: Install: mlocate
Ater updaing the OS run following command to install the packae:
sudo apt-get install mlocate
Package Details | |
Package: | mlocate |
Version: | 0.23.1-1ubuntu2 |
Maintainer: | Ubuntu Developers |
Home page: | http://carolina.mff.cuni.cz/~trmac/blog/mlocate |
Description: | quickly find files on the filesystem based on their name mlocate is a new implementation of locate, a tool to find files anywhere in the filesystem based on their name, using a fixed pattern or a regular expression. Unlike other tools like find(1), locate uses a previously created database to perform the search, allowing queries to execute much faster. This database is updated periodically from cron. . Several implementations of locate exist: the original implementation from GNU's findutils, slocate, and mlocate. The advantages of mlocate are: . * it indexes all the filesystem, but results of a search will only include files that the user running locate has access to. It does this by updating the database as root, but making it unreadable for normal users, who can only access it via the locate binary. slocate does this as well, but not the original locate. . * instead of re-reading all the contents of all directories each time the database is updated, mlocate keeps timestamp information in its database and can know if the contents of a directory changed without reading them again. This makes updates much faster and less demanding on the hard drive. This feature is only found in mlocate. . Installing mlocate will change the /usr/bin/locate binary to point to mlocate via the alternatives mechanism. After installation, you may wish to run /etc/cron.daily/mlocate by hand to create the database, otherwise mlocate won't work until that script is run from cron itself (since mlocate does not use the same database file as standard locate). Also, you may wish to remove the "locate" package in order not to have two different database files updated regularly on your system. Homepage: http://carolina.mff.cuni.cz/~trmac/blog/mlocate |
Distro: | Ubuntu 12.04 LTS |
Release: | |
Repo/Section: | utils |
First of all update your system with the command:
sudo apt-get update
Ads
Above command will download the package lists for Ubuntu 12.04 LTS on your system. This will update the list of newest versions of packages and its dependencies on your system.
After downloading the latest package list with the help of above you can run the installation process.
If mlocate is not installed on your compter then the command 'dpkg -L mlocate' will give followin error.
Installing mlocate:
After system update use the following command to install mlocate:
sudo apt-get install mlocate
Above command will confirm before installing the package on your Ubuntu 12.04 LTS Operating System. If you are not already logged in as su, installer will ask you the root password. After completion of the installation you can use the package on your system.
Now we will see the commands for uninstalling the mlocate from Ubuntu 12.04 LTS. For uninstalling this package you can easily use the apt command and remove the package from Linux Operating System.
To remove the mlocate following command is used:
sudo apt-get remove mlocate
Following command is used to remove the mlocate package along with its dependencies:
sudo apt-get remove --auto-remove mlocate
This will remove mlocate and all its dependent packages which is no longer needed in the system.
Completely removing mlocate with all configuration files:
Following command should be used with care as it deletes all the configuration files and data:
sudo apt-get purge mlocate
or you can use following command also:
sudo apt-get purge --auto-remove mlocate
Above command will remove all the configuration files and data associated with mlocate package. You can can't recover the delete data, so, use this command with care.