After taking a long look at the code, it appears that
ProblemReport.load() method brings everything from the report in memory.
While this is acceptable for normal crashes, it becomes particularly
difficult for kernel crash dumps that are often multi Gb.

Since Raring, kernel crash dumps are no longer stored in the apport
report so this is not an issue. But for all kernel crashes happening on
Precise, this _is_ a problem.

My proposal is to add a ProblemReport.extract() method that will read
the report and write the binary content to disk.

A first pass is done by loading the report with binary=False. This will
NOT load the binary elements of the report.  Those will be identified
while writing the other elements of the report and then used in
conjunction with ProblemReport.extract to write only those binary
content directly to a file.

I will propose a merge for that shortly

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1307413

Title:
  apport-unpack requires too much main memory to run

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apport/+bug/1307413/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to