I wonder why aren't there any tool that enable one to find files on his harddisk very rapidly like "search everything" does .Just type a part of the file name and all files containing the keyword will show up instantly . Isn't it possible to design a program to record the names of all files in some directory in a database so that you can search the database quickly for file names ?

  • A minor nitpick, but it might help you understand the system better. In general, filesystems don't directly support file searching or creating indexes. The job of the filesystem is to store files. Searching and indexing is done by various utility programs. It's done this way because simpler filesystem=smaller chance of bugs and it lets the user configure the level of index-building and which areas should be the targets.
    – Perkins
    Jul 28, 2016 at 17:29

2 Answers 2


Run sudo updatedb and locate [ filename or part ]
updatedb updates the index database.
If you want to locate a program, run whereis [ program name ]

  • 1
    Nice, but how to make locate search in some specific directory in linux mint ? Nov 7, 2012 at 8:58
  • well for that purpose you can use find command, use it like this find [path to directory] | grep "file name or part" This will search recursively so you can just search inside the base directory and it will automatically look for the file inside any sub directory.
    – Gufran
    Nov 7, 2012 at 9:02
  • For some specific directory: locate foo | grep /home/bar/baz Nov 7, 2012 at 9:13
  • Thanks , but can you give me an example ?I'm completely new to linux .In windows ,you write D:\\foldername\ etc What's the equivalent in linux? Also ,does this tool has a GUI so that I can open the file directly ? Nov 7, 2012 at 9:29
  • utilities like locate or find do not have GUI built in, you can use a third party tool like catfish. To install the tool you can search for catfish in software center or run this command sudo apt-get install catfish. After installing this you can open the program from Unity Dash. regarding the File structure in linux, there is no C, D Drives, all the partitions are mounted as directory inside root, that is / (back-slash). so everything goes directly inside /, like your Home directory (same as your user directory in windows) is located inside /home/
    – Gufran
    Nov 7, 2012 at 9:46

If you are looking for file names only, it allready does this, it is called locate

For more advanced searching you can look at tracker: https://wiki.ubuntu.com/Tracker (see also this question: What are the alternatives to OS X's Spotlight? )

More options you can find here: https://help.ubuntu.com/community/FindingFiles

  • How can I make locate search in a specific directory ? Nov 7, 2012 at 8:56
  • That's another question, but you can find the answer here serverfault.com/questions/313733/… :)
    – Nanne
    Nov 7, 2012 at 8:59
  • but that finding files link on help.ubuntu is quite a good description of your choices it seems?
    – Nanne
    Nov 7, 2012 at 9:00
  • @hvjkjdtmkgh: See my comment on Gufran's answer for how to search a specific directory. Nov 7, 2012 at 9:15

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .