Bug 1197643 - rpm with w19T0.zstdio error: create archive failed: cpio: write failed - Cannot allocate memory
Summary: rpm with w19T0.zstdio error: create archive failed: cpio: write failed - Cann...
Status: NEW
Alias: None
Product: openSUSE Tumbleweed
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: Current
Hardware: Other Other
: P5 - None : Normal (vote)
Target Milestone: ---
Assignee: Martin Liška
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-03-29 11:50 UTC by Martin Liška
Modified: 2023-04-12 00:44 UTC (History)
1 user (show)

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Liška 2022-03-29 11:50:23 UTC
I create an artificial package with 100 subpackages where each contains 3MB size:
https://build.opensuse.org/package/show/home:marxin:big/bigpackage

the package build fails on machine with 128 CPUs and 256GB memory:

[   11s] error: create archive failed: cpio: write failed - Cannot allocate memory
[   11s] error: create archive failed: cpio: write failed - Cannot allocate memory
[   11s] error: create archive failed: cpio: write failed - Cannot allocate memory
[   11s] error: create archive failed: cpio: write failed - Cannot allocate memory
[   11s] error: create archive failed: cpio: write failed - Cannot allocate memory
[   11s] error: create archive failed: cpio: write failed - Cannot allocate memory
[   11s] error: create archive failed: cpio: write failed - Cannot allocate memory

It's really weird because running streaming_compression_thread_pool.c (from zstd examples), consumes at maximum ~100MB with level == 19.

So even 128 * 100MB is a reasonable allocation on the machine.

Note I've seen the error when I build e.g. gcc11 package on the machine.
Comment 1 Martin Liška 2022-03-29 13:56:29 UTC
All right, I'm starting to understand the root cause..
Comment 2 Martin Liška 2022-03-30 08:32:49 UTC
Explained here:
https://github.com/facebook/zstd/pull/2328#issuecomment-1082783600

so the pool usage has limitations, I'm going to update our rpm patch.
Comment 3 Martin Liška 2022-03-30 09:00:53 UTC
I've just made a SR:
https://build.opensuse.org/request/show/965845