Bug 259519 - OOMed after memory usage set to aggressive
Summary: OOMed after memory usage set to aggressive
Status: RESOLVED FIXED
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Slackware Linux
: NOR crash
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-11 13:59 UTC by Grissiom
Modified: 2012-07-23 22:31 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Grissiom 2010-12-11 13:59:17 UTC
Version:           unspecified (using KDE 4.5.4) 
OS:                Linux

snip of dmesg:(I can provide full version if required)

[18755.297280] 330694 total pagecache pages
[18755.297281] 0 pages in swap cache
[18755.297283] Swap cache stats: add 0, delete 0, find 0/0
[18755.297284] Free swap  = 0kB
[18755.297285] Total swap = 0kB
[18755.301779] 489456 pages RAM
[18755.301782] 10440 pages reserved
[18755.301784] 18723 pages shared
[18755.301785] 466265 pages non-shared
[18755.301787] [ pid ]   uid  tgid total_vm      rss cpu oom_adj oom_score_adj name
...

[18755.302165] [ 5714]  1000  5714    57830     1165   0       0             0 klauncher
[18755.302170] [ 6277]  1000  6277   147300    24112   0       0             0 okular
[18755.302175] [ 9509]  1000  9509    59323     1220   3       0             0 kio_http
[18755.302178] Out of memory: Kill process 6277 (okular) score 50 or sacrifice child
[18755.302181] Killed process 6277 (okular) total-vm:589200kB, anon-rss:96448kB, file-rss:0kB


Reproducible: Didn't try

Steps to Reproduce:
1, Set memory usage to aggressive.
2, open a large pdf file.
3, read though it.

Actual Results:  
OOMed by kernel.

Expected Results:  
I think it should use a limited percent of the whole RAM even when aggressive memory usage is set.

Hardware configuration:

DELL Vostro3500, Core i3, 2G RAM
Comment 1 Pino Toscano 2010-12-11 15:23:54 UTC
> I think it should use a limited percent of the whole RAM even when aggressive
> memory usage is set.

This is what it does, usually.
In your case, it didn't seem to be that bad, consiering you set it as "aggressive". Did you launch some other application when okular crashed?

(Also, looks like you don't have swap enabled; even a very bit of swap would generally help, not just for this case.)

Also, what version is your kernel (`uname -a`)?
Comment 2 Grissiom 2010-12-11 16:35:50 UTC
No other RAM consuming apps running when okular crashed. I noticed okular used almost 1GB cache. Is that normal?

uname -a is:
Linux darkstar 2.6.37-rc5-corei3-00062-g6313e3c #17 SMP PREEMPT Thu Dec 9 00:13:15 CST 2010 x86_64 Intel(R) Core(TM) i3 CPU       M 370  @ 2.40GHz GenuineIntel GNU/Linux
(I have to use the latest kernel to get hardware support)

Yes, I'm considering add some swap to the system. But that would be an other story ;)
Comment 3 Albert Astals Cid 2010-12-13 13:45:36 UTC
You told it to be agreesive, so it is, so yes 1GB of cache is normal if you are not using any other program and you had opened a big pdf file.
Comment 4 Albert Astals Cid 2012-07-23 22:31:24 UTC
There were a few bugs in free memory calculation, they have been ironed out for the KDE Applications 4.9 release due next week, this should be fixed by those changes.

If you can still reproduce the problem after updating to that version or newer please reopen the bug.

Thanks for caring about Okular :-)