Friday, March 03, 2006

A quick technical note...

I googled like crazy for the answer to this question yesterday and didn't find it, so I'm blogging the answer now that I know it. I'm trying to use the new version of amarok, which is a KDE-based music player for Linux. It has a bug, which I hoped to fix, but haven't been able to fix. In the process of trying to build a version that I could debug, I managed to leave some tracks on my filesystem which prevented the official version from running.

The symptoms were that whenever I tried to run the official version of amarok, I'd get an error from kbuildsyscoca:

kio (KSycoca): ERROR: No database available!

There are probably lots of reasons why this can happen. None of the ones I found in my web search were it, though. It turns out that I'd accidentally left some amarok configuration files in /usr/local from my debug build of amarok, and these were overshadowing the official versions of the files. So the way I got this error message to go away was to search /usr/local for every file whose name contained the string "amarok" and deleting all of them.

If you are a neophyte and don't habitually install from source, this solution will definitely not work for you, because you did not commit the sin that I did, so the cure for your woes is not the one that worked for me. Only use this solution if you really seriously know what you're doing. If you use this solution and amarok starts really not working for you, uninstall and reinstall it - you probably polluted your installation.

This isn't as bad as a windows registry problem, but it was pretty ugly - it took me an hour or more to figure out. Error messages, people. Error messages are important. Not that I am bitter...


Anonymous Anonymous said...

Hi just wondering how did you search for a string like amarok in all files in a directery like /usr/local???
with cat or how??

Thursday, May 18, 2006 5:51:00 PM  
Blogger Ted Lemon said...

Sorry I took so long to answer your question, but for what it's worth, there are two answers, depending on whether you are asking what I did, or whether you really intended to ask what you actually asked.

To do what you describe in your question, you would type at the command line:

cd /usr/local
find . -type f -print0 |
xargs -0 fgrep -i amarok

This searches the contents of the files for the string "amarok". However, what I think I actually did was to just find all the files whose names contained the string "amarok":

find . -name \*amarok\* -print

Wednesday, May 31, 2006 1:11:00 AM  
Blogger Ted Lemon said...

Er, just to be clear, the blog commenter won't let me write HTML to make the above code look correct, so it insisted on breaking the line. You actually don't want to hit return after the '|' character in the first example - the find and the xargs should be on the same line.

Wednesday, May 31, 2006 1:12:00 AM  

Post a Comment

<< Home