Since I moved to KDE 4.11 the kfileplaces/bookmarks.xml file fills with entries. The file seems to consist almost completely of duplicates of <info> tags for removable devices: --- snip --- <separator> <info> <metadata owner="http://www.kde.org"> <UDI>/org/freedesktop/UDisks2/block_devices/dm_2d1</UDI> <isSystemItem>true</isSystemItem> <IsHidden>false</IsHidden> </metadata> <metadata owner="http://freedesktop.org"> <bookmark:icon name="folder"/> </metadata> </info> </separator> <separator> <info> <metadata owner="http://www.kde.org"> <UDI>/org/freedesktop/UDisks2/block_devices/sdc1</UDI> <isSystemItem>true</isSystemItem> <IsHidden>false</IsHidden> </metadata> <metadata owner="http://freedesktop.org"> <bookmark:icon name="folder"/> </metadata> </info> </separator> --- snap --- The number of lines seem to be telling a lot. Number of lines in the file: # wc -l /home/XXX/.kde4.11/share/apps/kfileplaces/bookmarks.xml 35130 /home/XXX/.kde4.11/share/apps/kfileplaces/bookmarks.xml Unique lines (non-redundant): # sort -u /home/XXX/.kde4.11/share/apps/kfileplaces/bookmarks.xml | wc -l 129 There is something appearing that could be a symptom of this or related to the source of the problem: Sometimes(!) when I keep dolphin open, the places panel constantly reloads. Dolphin becomes almost impossible to use, and it uses a lot of processor time. I once removed all the unnecessary duplicates by hand. But they reappeared later. Reproducible: Sometimes Steps to Reproduce: 1. Maybe: Keep Dolphin open 2. ??? 3. Receive duplicate entries Expected Results: No redundant entries in kfileplaces/bookmarks.xml, no constant reloading in dolphin.
I tried to reproduce the error and find the origin of it: The file seems to be slightly modified when I attach an external USB hard disc (encrypted, LUKS). But only minor changes appeared (entry for the external drive moved down). Then I tried to find the process changing the file. The audit tools show multiple entries of dolphin changing the file: --- snip --- type=SYSCALL msg=audit(1382560177.489:6562): arch=c000003e syscall=82 success=yes exit=0 a0=763eb68 a1=7624dc8 a2=763eb68 a3=0 items=5 ppid=3532 pid=1024 auid=1000 uid=1000 gid=1003 euid=1000 suid=1000 fsuid=1000 egid=1003 sgid=1003 fsgid=1003 ses=2 tty=(none) comm="dolphin" exe="/usr/bin/kdeinit4" key="bookmarks" --- snap --- (ppid=3532 is kdeinit4, pid=1024 is dolphin) I created the audit filter with: /sbin/auditctl -w /home/XXX/.kde4.11/share/apps/kfileplaces/bookmarks.xml -p war -k bookmarks I search for the audit records, using: /sbin/ausearch -k bookmarks But the previously mentioned, small change doesn't seem to be the bad one. Because at an arbitrary (?) point in time dolphin seems to run crazy and write about 900 times to that file. At "time->Wed Oct 23 21:30:08 2013" the first audit entry, at "time->Wed Oct 23 22:29:37 2013" the 900th. The time steps are mostly 0 seconds, but also a lot of 1, 2 or 3 seconds. But then also gaps of 3-5 mins. Just one step is larger than 5 mins. As far as I remember, I didn't use dolphin or any special application during that time actively. I just keep a dolphin instance open on a second screen.
I forgot to mention, I didn't attach the external disc in the evening. Only the first small change in the morning happened while connecting the device. But all new entries seem to be about the external drive.
Two months ago on #fedora-kde Freenode channel, user rom1dep complained about Dolphin (KDE 4) taking ~5 seconds to start. He said that removing .kde/share/apps/kfileplaces/bookmarks.xml .kde/share/apps/kfileplaces/bookmarks.xml.bak solved the problem. Those files contained thousands of lines about old (and no longer used) removable devices. Since I am running Plasma 5 and I was experiencing slow Dolphin start times too, I tried to check how many code lines had my /bookmarks.xml. I saw that it contained 7161 lines, for 228 KiB of disk space. I tried to remove those files, then logged out&in from Plasma, and then I saw that Dolphin required much less time to start. Removing those files did not affect the resources/bookmarks that everyday I use in Dolphin. They contain many lines of code about unused removable devices. I could see lines of XML code about Fedora 16 (now Fedora lastest version is 22)
Forum discussion https://forum.kde.org/viewtopic.php?f=224&t=126866
I (the original reporter) completely forgot about this report. But Germano's comment reminded me to check if the bug is still valid. In short: Yes, it is still valid for me: 621K Sep 15 21:02 .kde/share/apps/kfileplaces/bookmarks.xml $ wc -l .kde/share/apps/kfileplaces/bookmarks.xml 21413 .kde/share/apps/kfileplaces/bookmarks.xml $ grep --count /org/freedesktop/UDisks2/block_devices/dm_2d1 .kde/share/apps/kfileplaces/bookmarks.xml 432 (i. e. 432 identical entries, >21k lines total, >600 KB) On the other hand, I didn't recognize any negative impact from this. And sadly, it seems quite likely that this bug will never be addressed directly. Emmanuel Pescosta removed some (not all!) references to "kfileplaces/bookmarks.xml" in kdelibs and kio in favor of user-places.xbel. This seems to be a general trend to remove "kfileplaces/bookmarks.xml". See: - https://bugs.kde.org/show_bug.cgi?id=345174 - https://quickgit.kde.org/?p=kdelibs.git&a=commit&h=5c0a31a2f2a46aa44b8c34baae67b6951b2abcaf - https://quickgit.kde.org/?p=kio.git&a=commit&h=e919daeb5b144b146dbf459fadb116729b866d21 On my system kdelibs version 4.14.8 is installed, and when I attach a USB stick, the file still changes and I receive two identical entries for the stick in the bookmarks.xml, which disappear when I remove the stick. So someone is still using this file. My user-places.xbel has no redundant entries.
(In reply to Germano Massullo from comment #3) > Two months ago on #fedora-kde Freenode channel, user rom1dep complained > about Dolphin (KDE 4) > taking ~5 seconds to start. > He said that removing > .kde/share/apps/kfileplaces/bookmarks.xml > .kde/share/apps/kfileplaces/bookmarks.xml.bak > solved the problem. Those files contained thousands of lines about old > (and no longer used) removable devices. Since I am running Plasma 5 and > I was experiencing slow Dolphin start times too, I tried to check how > many code lines had my /bookmarks.xml. I saw that it contained 7161 > lines, for 228 KiB of disk space. I tried to remove those files, then > logged out&in from Plasma, and then I saw that Dolphin required much > less time to start. Removing those files did not affect the > resources/bookmarks that everyday I use in Dolphin. They contain many lines > of code about unused removable devices. I could see lines of XML code about > Fedora 16 (now Fedora lastest version is 22) I have been experiencing the above freezing of Dolphin at Fedora 21 since this summer. It takes up to a minute to remove a file/directory. Gwenview demonstrates the same behavior -- takes a while to become active when started. Removal of the bookmarks.xml helps indeed, yet this file, together with bookmarks.xml.bak, appears again when woken up from the sleep mode and has the same size as before deletion, so I wonder where does it get information and how to remove this information permanently?
.kde/share/apps/kfileplaces/bookmarks.xml no longer exists in Plasma 6. I think we can close this bugreport
You have to turn on the bookmarks feature in the file dialog; it's off by default.