Results 1 to 4 of 4

Thread: HOWTO: Desktop Search in Ubuntu Intrepid in KDE 4.2

  1. #1
    Join Date
    Jun 2006
    Location
    Switzerland
    Beans
    Hidden!
    Distro
    Kubuntu Jaunty Jackalope (testing)

    Lightbulb HOWTO: Desktop Search in Ubuntu Intrepid in KDE 4.2

    Desktop Search in Ubuntu Intrepid (and Debian) in KDE 4.2


    Introduction

    Ubuntu Intrepid 8.10 features an inbuilt desktop search. Unfortunately I never managed to get it to work right and I tried a lot of things. So I finally went on irc.freenode.org into the #strigi channel and asked for help. Lucky me Phreedom in there gave me a helping hand. Why Nepomuk doesn't work by default is still a mystery. I think this is related to Redland instead of Soprano. Unfortunately, as Phreedom told me, the Ubuntu and Debian maintainers don't supply Soprano with the current builds. Also his recommendation is to use KDE 4.2 (Kubuntu 8.10 comes with KDE 4.1).


    Step 1: Upgrading to KDE 4.2

    You can use my tool http://repogen.simplylinux.ch to get the according KDE 4.2 repos. There are two entries, one is the stable one (recommended) and the other one is nightly-build from the svn (I use nightly Amarok but not KDE repo). I know this is shameless self-advertisment *smile*.

    After you modified your sources list and added the KDE 4.2 upgrade it:
    Code:
    sudo apt-get update && sudo apt-get upgrade

    Step 2: Getting the necessary packages

    For compiling soprano we need a few additional things. Very likely you'll have some of it already.
    Code:
    sudo apt-get install libqt4-dev openjdk-6-jre openjdk-6-jdk build-essential cmake subversion qmake strigi-utils
    Instead of the OpenJDK Java you could use a different one. Just be sure use the according path in step 4.2. I prefer OpenJDK because it also has a 64bit browser plugin (keyword: icedtea)


    Step 3: Getting the sources

    Now we need to fetch the sources. Unfortunately we can't just only fetch soprano but we need to fetch a bit more. Run the following command from any location (desktop or so) and it will then create a kdesupport folder there and will fetch the sources inside.
    Code:
    svn co svn://anonsvn.kde.org/home/kde/tags/kdesupport-for-4.2/kdesupport


    Step 4: Compiling and installing

    (1) Now that we have the sources, go into the folder and create a build folder.
    Code:
    cd kdesupport/soprano
    mkdir build
    cd build
    (2) The environment variable JAVA_HOME is not set (at least on a default installation) and you need to do that now. If you don't use OpenJDK then change the path accordingly.
    Code:
    export JAVA_HOME=/usr/lib/jvm/java-6-openjdk
    (3) Run now cmake to check the prerequisits
    Code:
    cmake ..
    You should get an output like this:
    Code:
    -- Soprano Components that will be built:
       * Sesame2 storage backend (java-based)
       * D-Bus server/client support
    -- Soprano Components that will NOT be built:
       * Redland storage backend
       * Raptor RDF parser
       * Raptor RDF serializer
       * The CLucene-based full-text search index library
    (4) If you get that output you can compile and install soprano.
    Code:
    make
    sudo make install

    Step 5: Configure Nepomuk

    (1) As final step we have to configure Nepomuk a bit. First you need to stop it by going into the KDE system settings and go to the Advanced tab


    (2) Select there "Destkop Search" and you are in the Nepomuk configuration.


    (3) Deactivate Nepomuk there. Strigi will get greyed out.

    (4) Then open a terminal and delete the current Nepomuk data files.
    Code:
    rm -Rf ~/.kde/share/apps/nepomuk
    (5) Then we need to edit the Nepomuk config file.
    Code:
    nano ~/.kde/share/config/nepomukserverrc
    And set the new config to this:
    Code:
    [Basic Settings]
    Configured repositories=main
    Start Nepomuk=true
    
    [Service-nepomukmigration1]
    autostart=false
    
    [Service-nepomukstrigiservice]
    autostart=true
    
    [main Settings]
    Storage Dir[$e]=$HOME/.kde/share/apps/nepomuk/repository/main/
    Used Soprano Backend=sesame2
    rebuilt index for type indexing=true
    This will start Nepomuk and Strigi at boot-up and the database will be in the nepomuk folder.

    (5) Once you have done that, you can go into the Nepomuk Advanced Settings and select the folders you want to have indexed and set excludes for what you don't want to have indexed. Then start Nepomuk and Strigi again and it will start to index.

    (6) For searching now, open Dolphin and in the topbar enter the following.
    Code:
    nepomuksearch:KEYWORD
    Below you have an example.

    You can see results will be returned. As I set this up on a test-vm there aren't many hits. What you also can see is that in the right pane of Dolphin you can add description and tags to a file. Nepomuk will also index this metadata.


    Step 6: Wait and search

    That's it. First indexing will take a while and you can see the results immediately. In the Desktop Search in the system settings it will show you what folder currently is being indexed. Same goes if you move your mouse over the Nepomuk icon in the system tray.
    Last edited by hyper_ch; March 12th, 2009 at 05:09 PM.

  2. #2
    Join Date
    Dec 2007
    Beans
    11

    Re: HOWTO: Desktop Search in Ubuntu Intrepid in KDE 4.2

    I have been battling this for a while (months, off and on). Almost gave up again today until I found your detailed instructions. It's now working great. Superb contribution...thank you!

    -------------
    Many of the previous Strigi/Nepomuk instructions mentioned Konqueror as access to Desktop Search. I automatically tried to use that instead of Dolphin as indicated in your instructions. It doesn't work.

    -------------
    Step 5: Configure Nepomuk
    ...

    (6) For searching now, open Dolphin and in the topbar enter the following.
    Code:
    nepomukcsearch:KEYWORD

    This should be
    nepomuksearch:KEYWORD

  3. #3
    Join Date
    Jun 2006
    Location
    Switzerland
    Beans
    Hidden!
    Distro
    Kubuntu Jaunty Jackalope (testing)

    Re: HOWTO: Desktop Search in Ubuntu Intrepid in KDE 4.2

    small typo thx for pointing out well, redland is slow, soprano uses a lot of resources, but the strigi devs told me they look for a new alternative
    Last edited by hyper_ch; March 12th, 2009 at 05:10 PM.

  4. #4
    Join Date
    Jan 2006
    Location
    Summerhill, PA USA
    Beans
    53
    Distro
    Kubuntu 9.04 Jaunty Jackalope

    Re: HOWTO: Desktop Search in Ubuntu Intrepid in KDE 4.2

    I cant get this to work. When I restart nepomuk, it just rewrites the config to use redland.

    Any ideas what I am doing wrong.
    The only limit to innovation is the breadth of human imagination.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •