Failed to Execute a Resource Scheduling Task on UOS
Symptom
A resource scheduling task fails on UOS. An error is reported indicating that the task collection fails because the system kernel version is earlier than 4.19. You are advised to use 4.19 or later.
Possible Cause
The BPF parameter is not configured. The kernel needs to be recompiled.
Checking the Tracers Configuration
- Check the current kernel version.
1uname -rFigure 1 Kernel version
- Download the source code of the target version at kernel.org.Figure 2 Downloading the source code
- Decompress the source package and go to the source code directory.
1 2
tar -xvf linux-4.19.274.tar.xz cd linux-4.19.274
- Copy the current kernel configuration file to the extracted source code directory.
Rename the copied configuration file as .config.
1cp /boot/config-4.19-90-2201.4.0.0135.up1.uel20.aarch64 ./.config
Figure 3 Copying the configuration file
- Configure the kernel.
Run the make menuconfig command to open the kernel configuration menu and adjust the compilation options of the modules loaded by the kernel as required, such as changing the kernel name and adding the modules that are missing in the system.
- View the Tracers option.
Go to the kernel configuration page and select Kernel hacking.
Figure 4 Compilation option menu
Tracers is not enabled in the configuration. Therefore, perf does not support collection of schedule events.
Figure 5 Configuration of Tracers
Configuring Tracers and Compiling the Kernel
- Configure the built-in options of Tracers.
Select Tracers, press Enter, and select Scheduling Latency Tracer. Save the settings and exit.
Figure 6 Selecting Scheduling Latency Tracer
A dialog box is displayed asking you to enter the name of the file to be saved. Retain the default value and click OK.
Figure 7 Entering a file name
- Check Tracers and save the settings.Figure 8 Checking the Tracers option
Press Esc twice.
- Compile the kernel.
Switch to the source code directory. In the command, 128 indicates the number of CPU cores. Change it as required.
1make -j 128
Figure 9 Compilation
- Install the modules.
Compile and install the modules after the compilation is complete.
1make modules_installFigure 10 Compiling and installing the modules
- Install the kernel core file.
1make installFigure 11 Installing the kernel core file
- Reboot the system.
1reboot
- Check the kernel version.
1uname -rCheck the kernel version. It is found that the kernel version is updated.
Figure 12 Confirmation