Skip to content
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

objdump generates "unable to initialize decompress status for section .debug_aranges" on v2.3.0 #338

Closed
rob-scheepens opened this issue Jan 29, 2024 · 2 comments

Comments

@rob-scheepens
Copy link

rob-scheepens commented Jan 29, 2024

When running objdump -g on the binary for v2.3.0 it gives an error:

nutanix@NTNX-21SM5B060138-A-CVM:10.56.68.161:~$ objdump -g /usr/local/nutanix/bin/ebpf_exporter.x86_64
objdump: /usr/local/nutanix/bin/ebpf_exporter.x86_64: unable to initialize decompress status for section .debug_aranges
objdump: /usr/local/nutanix/bin/ebpf_exporter.x86_64: unable to initialize decompress status for section .debug_aranges
objdump: /usr/local/nutanix/bin/ebpf_exporter.x86_64: File format not recognized
nutanix@NTNX-21SM5B060138-A-CVM:10.56.68.161:~$

It seems to be related to the version of binutils used, see for example https://wiki.gentoo.org/wiki/Project:Toolchain/Binutils_2.32_upgrade_notes/elfutils_0.175:_unable_to_initialize_decompress_status_for_section_.debug_info:

"To fix it you need to switch active binutils to sys-devel/binutils-2.32 (and to >=gdb-8.3) or above and rebuild the affected packages."

@rob-scheepens rob-scheepens changed the title objdump generates "unable to initialize decompress status for section .debug_aranges" on v0.23.0 objdump generates "unable to initialize decompress status for section .debug_aranges" on v2.3.0 Jan 29, 2024
@bobrik
Copy link
Contributor

bobrik commented Jan 29, 2024

It sound like binutils is too old on your end. The binaries are built in Debian Bookworm and it has binutils v2.40:

I can replicate the issue even by running binutils v2.31 from Buster (on aarch64):

ivan@vm:/tmp$ curl -sLo ebpf_exporter.aarch64 https://github.com/cloudflare/ebpf_exporter/releases/download/v2.3.0/ebpf_exporter.aarch64

ivan@vm:/tmp$ docker run --rm -it -v $(pwd):$(pwd) -w $(pwd) debian:buster bash -c "apt-get update && apt-get install -y binutils && objdump -g ./ebpf_exporter.aarch64" | head -n50
...

./ebpf_exporter.aarch64:     file format elf64-littleaarch64

Contents of the .eh_frame section:

@rob-scheepens
Copy link
Author

You're right, verified this again and I will update our binutils.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants