Kernel Source Code Missing
Symptom
The analysis task fails. An error is reported indicating that the kernel header file is missing.
Possible Cause
The kernel source code is missing.
Troubleshooting Procedure
- Check the OS version.
The kernel source code must match the server OS version. The following uses openEuler 22.03 LTS SP2 as an example.
1cat /etc/os-releaseFigure 1 OS information
- Check the OS kernel version.
You can find the source code of the corresponding kernel version in the openEuler code repository.
For other OSs, download the source package from the corresponding community website or image repository.
- Download the source package and upload it to the server.
- Decompress the source package.Assume that the package is in the /home directory.
1unzip /home/kernel-openEuler-22.03-LTS-SP2.zip - Create a link.
1ln -s /home/kernel-openEuler-22.03-LTS-SP2 /lib/modules/$(uname -r)/build
Parent topic: FAQs