Re: scripts_gdb: Python Exception <class 'gdb.error'>: There is no member named nsections.

From: Jan Kiszka
Date: Fri Feb 21 2025 - 01:45:20 EST


On 20.02.25 16:21, Antonio Quartulli wrote:
> Hi,
>
> I have been working on the new ovpn linux kernel module since a while
> and your gdb kernel debugging helper scripts have been of great help.
>
> However, recently I have started hitting an issue I could not explain.
> When my qemu instance loads the ovpn.ko module, I get the following
> output in gdb:
>
> scanning for modules in /home/ordex/exp/openvpn_dev/linux-ovpn-dco
> loading @0xffffffffa0000000: /home/ordex/exp/openvpn_dev/linux-ovpn-dco/
> drivers/net/ovpn/ovpn.ko
> Python Exception <class 'gdb.error'>: There is no member named nsections.
>
> and the load of the symbols fails.
>
> Does it ring any bell?
> Any help debugging further?
>
> I am running the latest net-next.
>

Thanks for reporting. That's because of [1] in upcoming 6.14. Someone
needs to update scripts/gdb/linux/symbols.py accordingly.

Jan

[1]
https://lore.kernel.org/r/linux-hardening/20241216-sysfs-const-bin_attr-module-v1-1-f81e49e54ce4@xxxxxxxxxxxxxx/

--
Siemens AG, Foundational Technologies
Linux Expert Center