Problem with mlocate

I am new to NixOS (not to Linux). I have installed mlocate and, as root, issued the updatedb command. The command is now running for more and 1 hour and the database is almost 125Gb. Seems not correct. Updatedb used to be almost immediate on my other systems.

Many thanks in advance for helping

Is it possible you have a circular bind mount or similar?

I do not think that I have circular mounts (but I have a number of CIFS shares that are mounted to subdirectories of my home directory).
Anyhow, thanks for your suggestion. I have now used “prunePaths” in my service definition to avoid indexing directories on my CIFS shares (that are on a Synology NAS) that have to do with backups.
I’ll see if this helps.

Seems to be stable now. For information, the service definition in my configuration.nix is:

services.locate = {
enable = true;
locate = pkgs.mlocate;
prunePaths = [ “/tmp” “/var/cache” “/var/lock” “/var/run” “/var/spool” “/home/karel/Data/Archive” “/home/karel/Data/#recycle” “/home/karel/Data/#snapshot” “/home/karel/Music/#recycle” “/home/karel/Music/#snapshot” "/home/karel/Pictur>
interval = “hourly”; # possible with mlocate because it’s fast (because incremental)
};

Did you have a look what’s in there, e.g. using ncdu and perhaps looking in some of the files, if there are larger ones?

As said in an earlier remark, by excluding some directories from being indexed, I now have a stable situation.
The size of “locatedb” is now 23 M. So everything seems to be OK.
Thanks for your suggestion.