Bug 478337

Summary: Trying to open previously saved 7GB file results in crash
Product: [Applications] krita Reporter: ciaduck
Component: * UnknownAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED NOT A BUG    
Severity: crash CC: alvin, halla
Priority: NOR    
Version First Reported In: 5.2.1   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Krita Logs

Description ciaduck 2023-12-10 04:35:18 UTC
Created attachment 164059 [details]
Krita Logs

SUMMARY
I have a project I've been working on, and I have several copies of the file saved at different points. None of them seem to want to open. When I try, my RAM usage spikes to almost maximum, and krita will crash after 1 to 5 minutes of trying to load.

I'm really sad that this project I've spent hours on doesn't seem to have any valid file I can load. I don't know what is causing the crash, but I'm worried all my files are corrupt somehow.

STEPS TO REPRODUCE
1. Open Krita
2. Select "Open File" and attempt a file
3. Watch it crash

SOFTWARE/OS VERSIONS
Krita: 5.1.5, 5.2.1
Windows: 11

ADDITIONAL INFORMATION
I've attached logs as a single file. The crash logs are at the end, and perhaps the most important.
Comment 1 Alvin Wong 2023-12-10 07:58:47 UTC
Krita crashed from running out of tile swap space (KisChunkAllocator::getChunk). This doesn't mean the file is corrupted yet (we can't know for sure without inspecting the file.)

You can try increasing the memory limit and swap limit in Krita:
1. Close other programs (especially web browsers - they consume a lot of memory, and any chat clients like Discord.)
2. Open "Settings" -> "Configure Krita", then switch to the performance tab [1].
3. Increase the "Memory Limit", but not too much (check Task Manager to see how much unused memory you have.)
4. Increase the "File Size Limit" under "Swapping" to as much as your disk space allows (if you don't have much space left, clean up some free space.)
5. Restart Krita, then try opening the file again.

[1]: https://docs.krita.org/en/reference_manual/preferences/performance_settings.html
Comment 2 ciaduck 2023-12-13 02:46:41 UTC
Uping the RAM and SWAP helped to open the file. Thank you!

Do you have any recommendations for reducing load times or working with files with many layers?
Comment 3 Halla Rempt 2024-10-24 09:34:14 UTC
I'm sorry, but files with many layers taking time is basically a given because it just takes time to load all that data.