Hello Kienan,
I've continued investigating my issue and discovered something new that might shed some light. Here's the rundown:
1. To ensure my add-ons weren't causing problems, deleted all old modules and I followed the documentation on the LTTng website (
https://lttng.org/docs/v2.13/#doc-building-from-source) and downloaded `lttng-modules-2.13.13`.
2. Inside the downloaded folder, I successfully executed `make KERNELDIR=/usr/src/linux-source-6.5.0` without any issues.
3. Subsequently, I ran `make KERNELDIR=/usr/src/linux-source-6.5.0 modules_install`, which also completed successfully.
4. After that, I updated the module dependencies using `sudo depmod -a`, which went fine.
However, when I tried to load a module, such as `sudo modprobe lttng-probe-kvm`, it reported that the module couldn't be found at `/lib/modules/6.5.0-41-generic/`. Upon checking the logs, I confirmed that step 3 had installed the modules in `/lib/modules/6.5.0/`.
To address this, I modified step 3 to simply `make modules_install`, which then installed the modules correctly at `/lib/modules/6.5.0-41-generic/` and ran again step 4. But now, when attempting to load a module, I'm encountering the error `modprobe: ERROR: could not insert 'lttng_probe_kvm': Exec format error`.
Do you have any insights or ideas on what might be causing this issue?
Thanks again for your assistance.