Extreme memory usage by kio_thumbnail

Bug #289338 reported by what_if on 2008-10-26
46
This bug affects 6 people
Affects Status Importance Assigned to Milestone
KDE Base
Confirmed
Medium
kdebase-runtime (Ubuntu)
Medium
Unassigned

Bug Description

Binary package hint: dolphin

lsb_release -rd
Description: Ubuntu 8.04.1
Release: 8.04
32-bit

apt-cache policy dolphin
dolphin:
  Installed: 0.9.2-0ubuntu6.1
  Candidate: 0.9.2-0ubuntu6.1

Simple explanation:
When managing large image files in dolphin using the "previews" mode many thumbnail-generating sub-processes are spawned causing excessive memory usage and swap usage (over 2 GB). The computer system essentially "hangs" from the memory usage.

To duplicate the problem:
Place a handful of large image files (I used 10 tiff files of 45.8 megapixels each) in a folder.
Open Dolphin and navigate to the folder containing the image files.
Ensure the "Previews" view mode is selected.
Ensure the "Right Sidebar" is enabled.
Simply hold the cursor over the icon of an image file until it tries to load a preview in the "Right Sidebar"
--A sub-process of kio_thumbnail will be spawned every time the previous step is repeated with a new file to the tune of 202MB each in my case. (2.02GB memory usage in this example from kio_thumbnail processes).

The system will begin to slow as the physical memory is exhausted and all system resources are required to facilitate the swapping.

Jonathan Thomas (echidnaman) wrote :

Is this an issue with Intrepid or with dolphin-kde4 in Hardy?

Changed in dolphin:
status: New → Incomplete
Jonathan Thomas (echidnaman) wrote :

e are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comments. Please reopen it if you can give us the missing information, and don't hesitate to submit bug reports in the future. To reopen the bug report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in kdebase-runtime:
status: Incomplete → Invalid
dwchapin (daren-chapin) wrote :

This is most definitely still a problem, even in a new Jaunty install. It is particularly pronounced with directories of multipage tiff files. kio_thumbnail processes get launched until all available memory is exhausted, swapping out the entire system until nothing works. Before the system freezes up completely I counted 6 instances of kio_thumbnail at ~200MB each on a 1G memory box.

Changed in kdebase-runtime (Ubuntu):
assignee: nobody → dwchapin (daren-chapin)
status: Invalid → New
assignee: dwchapin (daren-chapin) → nobody
Peri Hankey (mpah) wrote :

In Kubuntu 9.10:

Something similar applies to PDF documents. If you have a directory containing several large PDF documents, and you have preview enabled, konqueror (or dolphin) effectively freezes. Even if you turn preview off, there seems to be no way of disabling a preview component for the right-click properties dialog for PDF files. The same applies with tootips - you get a pdf preview, and that can take a long time. So you have to run without preview and without tooltips, and even then you must take care not to attempt to read the properties of any large PDF.

This is an absurd state of affairs. Except for large single image PDF files, the preview image should be the first page, which is unlikely to be very large. It should be possible to get the first page without reading the whole document, which is what seems to be happening.

For certain kinds of usage, where you habitually deal with large PDF documents from other sources, this kind of thing is a road block for karmic + KDE4.

Peri Hankey (mpah) wrote :

In fact System Monitor shows konqueror/dolphin eating a large percentage of CPU, so perhaps it's not kio_thumbnail. And at some point konqueror spawns pdftotext. Is there any way to stop this behaviour?

Changed in kdebase-runtime (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
ShinobiTeno (lct-mail) wrote :

This is not related to KUbuntu, but its KDE 4.3.3 problem. If there will be solution, please upstream it!

Im currently running x64 gentoo system, based on Calculate linux 10, which is actually prebuilt gentoo.
Machine is dual-core E5300 with 4Gb of ram.

Im experiencing SAME issues with kio_thumbnail, slowly eating memory up, even if im NOT browsing (or browsed) any pictures and did not open any miniatures.
The effect is so insane, that this machine left for 6 hours for a purpose of backing video up(scratched dvd) has experienced kernel panic, because it run out of memory! (4Gb ram + 4Gb swap).

See two small examples in attatchment.

This is a very serious bug, it prevents normal work even if system is running stock and untouched.

ShinobiTeno (lct-mail) wrote :

This is a picture of htop, displaying kio_thumbnail eating over 4Gb of ram.

Changed in kdebase:
status: Unknown → Confirmed
Alexander (roth-a) wrote :

I've the same problem. It eats so much ram thart it blocks my compuer completly.
It seams to occur always with the same pictures. Maybe there is an error in the pictures.

But kio_thumbnail shouldn't have such grave problems with broken images...

gwenview and digikam have also the same problem with the images...

gene (eugenios) wrote :

Tried to give a non-mono application a try and got upset with it. Not only digikam is strange that it does not find images when an album is specified, it eats up all resources and completely freezes my system. I do have 4 gb of photos, digikam uses all resources to "add" a little fraction of it - a folder worth of 200 mb. If a new user sees f-spot or this even worse digikam, he/she might get a false impression about Linux. I myself use ImageMagick, gthumb, and eog...

gene (eugenios) wrote :

Well, amarok behaves in a similar way in the cover art manipulation. In this case, how does it manage to hang all the resources with a few tiny pictures? With this KDE is a real mess... However, maybe there is some specifics about our, say video cards? Mine is known to be quite hostile to linux.
lspci -vvv

..........
VGA compatible controller: ATI Technologies Inc RC410 [Radeon Xpress 200M]
...........

Does any of this bug sufferers have a similar chip?
Thanks

Pavel Malyshev (afunix) wrote :

Lucid-RC still has this bug. Looks like kio_thumbnail does not free memory.
Maybe it creates some cache in memory and does not clean it? If it's true, where can we tune memory limit for cache?

Changed in kdebase:
importance: Unknown → Medium
Ha-Duong Nguyen (cmpitg) wrote :

Is there any fix yet? The problem persists in KDE 4.4.5. I'm using Gentoo x86_64.

ShinobiTeno (lct-mail) wrote :

Hello Yang!

Please unmask and update to KDE 4.5.3 or later!
I have tested the case again now in KDE 4.5.3 in Gentoo x86_64 under similar conditions for several hours, this bug was ironed out(resolved).

"Kdeinit4: Kiothumbnail" is started once the thumbnail view is requested via Dolphin "thumbnail" button consuming 20-40 MiB of RAM. Thumbnails are displayed rather fast. Then, it idles for around a minute or two and is killed.

Hope Kubuntu guys can retest this and confirm.

George (geoaraujo) wrote :

This is still happening on Kubuntu 11.04 with KDE 4.6.4.
Opening a folder with lots of tiff files will make kio_thumbnail to use a lot of cpu and the process doesn't come to an end unless it's stopped manually.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.