Score:1

How often is baloo indexing files by default?

br flag

In Kubuntu 22.04 file search works pretty well.

As I have a lot of documents that I often move around - re-arranging my folders - the file indexer has to re-index them for me to be able to open them quickly from the app launcher.

When I make many changes I expect baloo too keep track of my changes automatically, and I think it does, but I'm not sure how often it does it.

When I'm in a hurry I disable it and delete the index file before re-enabling index and restarting the session.

enter image description here

But do I have to do that?

Should I just log out and back without deleting the index file?

Or should I just wait? For how long? Is there an (adjustable?) time period at which baloo re-scans folders? Can some locations be preoritized? How does this work?

in flag
Just about everything you've asked about seems to be in the config documentation ([KDE docs](https://community.kde.org/Baloo/Configuration)). You could add a cronjob, eg with kde's [cron tool](https://userbase.kde.org/System_Settings/Task_Scheduler), to initiate an index check every hour.
br flag
@pbhj -Sorry to reply so late. The link you posted tells how to include and exclude and other stuff that can be done from the GUI as well. I understand about a cron job, but my question is just: how often is baloo indexing by *default*?
in flag
My understanding is that after the initial indexing baloo uses inotify, so when an included folder is changed then files get updated/added to the index. KDE docs don't appear to go into that but [Arch ones do](https://wiki.archlinux.org/title/Baloo) mention it in passing. `balooctl monitor` should show you that behaviour?
br flag
@pbhj - `when an included folder is changed then files get updated/added to the index`. It's supposed to be instantaneous, then? No cron job needed. Even if I simply move a file? it should be quickly re-indexed and found at the new location if searched?
in flag
That's my non-expert understanding. Clearly inotify has limits though. Did you try using `balooctrl monitor` to verify and see how rapidly updates were done?
br flag
@pbhj - `balooctl monitor` tells me `baloo` is running, now idle, but not how rapidly etc. Anyway, you might post an answer and get the expiring bounty.
Score:1
in flag

Your principle question seems to be "how do I get baloo to update its index?" and the answer to that is that you don't, it uses a system called inotify (as seen in this Baloo documentation that mentions inotify).

When you first use baloo it creates an index, from then it updates the index as you alter the directories it is watching. To optimise baloo, only have directories you care about in the index. In KDE use "file search" from the application menu (accessible using kcmshell5 kcm_baloofile) to choose the directories to index. Or, you can edit the ~/.config/baloofilerc directly.

You can use balooshow to check a file is in the index, eg balooshow ./* will show if the current directories files are indexed or not.

balooctl monitor (and other balooctl commands) can help with debugging, if you run it and then change something in a monitored folder then you should see some activity, eventually it will show "Idle" and all indexing has been finished. This is almost instantaneous in my tests adding 100 text files to a folder/directory.

Here's some example output:

enter image description here

from when I ran:

for i in {1..100}; do touch $i.txt; done
balooshow ./*

with:

balooctl monitor 

running in the right pane.

You can confirm that documents are in the index by searching, also, using baloosearch or however you normally use baloo for searching, eg through KDE/Plasma's Dolphin file manager.

br flag
`Your principle question seems to be "how do I get baloo to update its index?"` - but the title is simply `How often is baloo indexing files` - and in the body: `When I make many changes I expect baloo too keep track of my changes automatically, and I think it does, but I'm not sure how often it does it.` - I know how to update the index tool, I ask how often it does it by default (without my intervention) so that I know if I have to change the defaults or not.
br flag
`When you first use baloo it creates an index, from then it updates the index as you alter the directories it is watching.` - So the changes should be reflected instantly. That is the answer. - It wasn't so instant when I asked the question I guess, but testing now I can confirm it. New bounty in 23 hours.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.