Monday, November 15, 2021

ERROR: The home is not clean. This home cannot be used since there was a failed OPatch execution in this home. Use a different home to proceed.

Everyone knows how to install the software for Oracle 19c database or grid infrastructure - Oracle ships preinstalled OH as a base release and a customer is performing runInstaller which is actually applying appropriate Release Update and one-off patches first and then linking libraries, executables and perform another stuff.

First you need to unpack the base release. Then, after running ./runInstaller script, something can potentially go wrong during applying the patches, for example, you might forget to renew opatch beforehand. To resolve the issue consult opatch logfiles located in ORACLE_HOME/cfgtoollogs directory. If the error is correctable, you fix it and rerun the installation, but you may get the following error :

ERROR: The home is not clean. This home cannot be used since there was a failed OPatch execution in this home. Use a different home to proceed.

You can go on by removing the new OH first, unzip a base home and rerun theinstallation, and it's actually the way the Oracle advises to follow on. In my case the opatch was older then required to install RU; it was not so much convenient to unpack or to copy over the network the installation files again.

So running truss (it was Oracle Solaris) I figured out the empty file is created when opatch starting its job during installation and this file is removed after successful all opatch operations. The file is :

$ORACLE_HOME/install/patch

I just removed it and rerun installation without unzipping base home again. All patches was applied successfully and the software was configured OK as well. That's it ! :)

P.S. You might with to clone ORACLE_HOME to avoid long installation and applying patches time.

Good Luck !

No comments:

Post a Comment