Uninstall the kernel patch module

To prevent the kernel live patching solution from applying a kernel patch module on subsequent boots, uninstall it.

Before you begin

  • You have root permissions on the system.
  • A live patching package is installed.
  • A kernel patch module is installed and loaded.

Procedure

  1. Select a kernel patch module:
    # kpatch list
    Loaded patch modules:
    kpatch_6_12_0_1_0_1 [enabled]
    
    Installed patch modules:
    kpatch_6_12_0_1_0_1 (6.12.0.el10_0.x86_64)
    ...
  2. Uninstall the selected kernel patch module.
    # kpatch uninstall kpatch_6_12_0_1_0_1
    uninstalling kpatch_6_12_0_1_0_1 (6.12.0.el10_0.x86_64)
    • Note that the uninstalled kernel patch module is still loaded:
      # kpatch list
      Loaded patch modules:
      kpatch_6_12_0_1_0_1 [enabled]
      
      Installed patch modules:
      kpatch_6_12_0_1_0_1 (6.12.0.el10_0.x86_64)

      When the selected module is uninstalled, the kernel remains patched until the next reboot, but the kernel patch module is removed from disk.

  3. Reboot your system.

Results

  1. Verify that the kernel patch module is uninstalled:
    # kpatch list
    Loaded patch modules:
    ...

    This example output shows no loaded or installed kernel patch modules, therefore the kernel is not patched and the kernel live patching solution is not active.