EM 24ai: This version of OMSPatcher is not compatible to apply the given patch

Problem:

While analyzing EM 24ai Release 1 Update 2 (24.1.0.2) for Oracle Management Service patch application, I encountered an error indicating that the OMSPatcher located under the OMS home is outdated and needs to be updated before starting the patching process.:

$ export ORACLE_HOME=/u03/em24/middleware/oms_home
$ /u03/em24/middleware/oms_home/OMSPatcher/omspatcher apply -analyze 37629905/
...
This version of OMSPatcher(13.9.24.1.0) is not compatible to apply the given patch.
Minimum Required Version of OMSPatcher to apply the patch is 13.9.24.4.0
Procure the compatible version from My Oracle Support, and try again.
OMSPatcher failed with error code 255

Solution:

1. Download patch 19999993 for EM 24.1.0.0.0 (for your version) from My Oracle Support

2. Backup the current “OMSPatcher” folder

    $ mv <MIDDLEWARE_HOME>/OMSPatcher <MIDDLEWARE_HOME>/OMSPatcher_backup

    For example:

    mv /u03/em24/middleware/oms_home/OMSPatcher /u03/em24/middleware/oms_home/OMSPatcher_backup

    3. Unzip the “p19999993_241000_Generic.zip” under /u03/em24/middleware/oms_home

      $ unzip /u03/install/p19999993_241000_Generic.zip -d /u03/em24/middleware/oms_home

      4. Check the version again and make sure the version is correct

      $ export ORACLE_HOME=/u03/em24/middleware/oms_home
      $ $ORACLE_HOME/OMSPatcher/omspatcher version

      OMSPatcher Version: 13.9.24.4.0
      OPlan Version: 12.2.0.1.16
      OsysModel build: Tue Apr 28 18:16:31 PDT 2020

      OMSPatcher succeeded.

      5. Retry running the analyze patch

      $ /u03/em24/middleware/oms_home/OMSPatcher/omspatcher apply -analyze 37629905/
      ...
      Checking if current repository database is a supported version
      Current repository database version is supported


      Prereq "checkComponents" for patch 37616329 passed.
      Prereq "checkComponents" for patch 37616365 passed.

      ...