-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
7z
fails to extract initramfs
#640
Comments
Thanks for the very detailed report @NiklasGollenstede !
It should be non-zero according to
It will be present if you run unblob with
Agree 100%. We're tracking this at #263 and have a draft branch for it. |
Sounds good, thanks!
Well, that keeps the prepended CPIO archive. But that archive contains a file, which apparently gets completely ignored. Running with
I gutess the expected result (with
|
|
Quick update: I'll probably write a CPIO extractor since we're already parsing the entries anyway, should not take long with the recent addition of the |
@NiklasGollenstede I opened a pull request to handle this, this will be reviewed over the coming weeks. These are the results I'm getting with your sample and that branch:
Don't hesitate to give it a try. |
That looks better. It seems to be handling the first archive correctly! Some further nitpickiness (largely unrelated to this overall issue):
|
@NiklasGollenstede converted to a discussion at #650 so everyone in the team can chime in. Thanks for taking the time writing this by the way. |
Closing this issue since CPIO is properly extracted now. The discussion on console output is kept open for further exchanges. |
Describe the bug
I was browsing Nix projects when I found this one and thought "that's cool, should be useful to inspect
initrd
s, but unfortunately, that currently does not really work very much.The below command tries to extract a zstd-compressed NixOS initramfs with prepended Intel CPU microcode, but:
7z
fails to extract the main CPIO archive, butunblob
still exits with 0/success.unknown
chunks that are really just zero-padding.To Reproduce
Command output
tree -s ./initrd_extract
Expected behavior
7z
not to fail / something else (likecpio
) to extract the archive.unblob
to exit non-zero upon sub-command failure.unknown
blocks that are entirely zero to be calledzero-padding
or something like that.Environment information
The text was updated successfully, but these errors were encountered: