Saturday, June 7, 2008

Google Desktop Search - Redefining search for Linux

Till around two years back, searching for documents on ones computer was limited to finding the files based on certain criteria such as the name of the file, the date of creation and so on. But this had the handicap that if one did not remember the name of the file or when it was last saved on the machine, it was very difficult to find the data and the person was left with the choice of taking wild guesses. And this was the case with all operating systems.

But in the past two years search for the desktop has gone through a remarkable metamorphosis and has transformed into an efficient tool to find exactly what one is looking for. The magic of this efficiency is the way the ubiquitous search tool has changed from just an executable file to a service where it actively indexes all the changes made to the files saved on ones machine in real time. Put another way, now it is possible to search for and find a particular text file say, by providing a phrase or snippet contained in it as the argument to the search tool. And these search tools makes searching your own email, files, music, photos, and more as easy as searching the web.

Apple's Mac OSX has what is called 'Spotlight' and Microsoft Windows has a plethora of tools like Microsoft's own desktop search and tools provided by Yahoo and Google to name a few. Unfortunately, Linux did not have a comprehensive solution in the same lines as those for Windows and OSX. True, we have Beagle - an offering from Novell and it does work efficiently. But it is not as integrated with the desktop as we would like it to be and it is dependent on Mono which is not installed by default on most Linux distributions.

But recently things got better for Linux enthusiasts as Google released its Desktop search tool for Linux as a native build. Because I consider desktop search to be a very important must have feature in all operating systems, I decided to download the Google search tool for Linux and give it a run.

The prerequisites for installing Google Desktop on Linux is that your system should already have glibc 2.3.2+ and gtk+ 2.2.0+ libraries installed. If you are using a modern Linux distribution released within the past one year, you will already have these libraries installed. I was using Debian Etch which already had these libraries and so I was able to proceed with the installation of Google Desktop. Google has released its Desktop search tool in two package formats, them being RPM and Deb packages. And to install either of them you run the respective commands as follows :
# rpm -ivh google-desktop-linux-1.0.1.0060.rpm
... for Red Hat based Linux distributions and
# dpkg -i google-desktop-linux-1.0.1.0060.deb
... for Debian based distributions such as Ubuntu.

The files are copied to the /opt directory and a short cut is created in the Gnome/KDE menu. The first time Google desktop is started, it prompts the user to enable the advanced features (a prudent thing to do) so that non-personal usage data and crash reports may be sent to Google to improve Desktop. This includes summary information, such as the number of searches you do, the time it takes for you to see your results, and application reports that Google will use to improve the program.

Using Google Desktop Search

Now that the installation is out of the way, it is time to find out how to use Google desktop search to find the files on ones hard disk. When Google desktop search tool is started, it minimizes to the task bar on the right hand side where you can access it by clicking on its icon.

Google Desktop search for LinuxFig: Google desktop search tool embeds in the Gnome taskbar

The first thing I did was set the preferences for searching. To access the preferences of the search tool, right-click on the icon and click on "Preferences..." and you can modify the preferences of Google desktop search tool in a web browser. Here I could set my preferences for indexing my machine. For example, I can order the search tool to skip indexing certain directories, skip indexing a particular type of file(s) such as my web history, email messages etc and even remove deleted files from the search results. Once I have made the requisite changes in the preferences, I could press the "save preferences" button to save the changes.

Google Desktop search for LinuxFig: The preferences dialog which opens in the web browser.

While it is true that indexing files on ones hard disk is a resource intensive process, Google desktop search tool is quite intelligent. It will start indexing files only when your system is idle. And when you start using the machine, it will stop its indexing and wait till the system is idle again. So I could never detect any lag in system performance when I started using Google Desktop search tool. Another feature I really like about this useful tool is the short-cut provided for it. If you press the 'Ctrl' key twice in quick succession, it will pop up a quick search box where you can type the search phrase. And once you finish searching, the pop-up box automatically fades away.

Google Desktop search for LinuxFig: Google Desktop quick search box

Features of Google Desktop Search for Linux
  • Indexes a diverse variety of files such as PDF, PostScript, info and man pages, text files, email messages, audio and video files (Music, Movies), web history and even secure pages (HTTPS) in web history (if enabled).
  • Is easy on the system resources and will start indexing only when the system is idle.
  • Can be easily accessed via the hot key (Ctrl).
  • Specific files are opened in their respective applications. So man pages are displayed in Gnome Yelp (documentation viewer), text files in the default text editor, web pages in the web browser and so on.
  • Rudimentary versioning support for files - Google Desktop creates cached copies (snapshots) of your files and other items each time they have been changed, and stores these copies on your computer’s hard drive. As a result, you can often use Desktop to find previous versions of your files or ones you've accidentally deleted.
  • It integrates quite well with the parent Desktop environment.
Other details ...

While Google Desktop search tool for Linux is dependent on various open source libraries, the search tool itself is a closed source product as Google has not released the source of the search tool yet.But I guess Google has pertinent reasons to keep it that way.

All in all, I find Google desktop search for Linux a very useful tool which enhances ones productivity by helping to drastically cut down the time taken to find data on ones machine.

No comments: