Here are the 4 Top and most common OPATCH issues in Windows server
OPatch cannot find a valid oraInst.loc file to locate Central Inventory. OPatch failed with error code = 104
On UNIX-based systems, OPatch uses an oraInst.loc file to determine the location of the central inventory. On Windows, this is done by a registry entry instead: the key is Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Oracle\inst_loc. On this system, the central inventory registry key was missing because the installation had been done manually by copying the binaries into place rather than running the WLS installer, and the registry had not been updated. This was why the central inventory could not be found.
1.Launch regedit as a Windows administrator.
2.Navigate to the Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Oracle\inst_loc key.
3.Edit the value of the key to point to the Oracle central inventory.
4.Save your changes.
5.Run opatch again and verify that it now works as expected.
Problems are reported while installing a patch or patchset using opatch on a Windows platform. “Couldn’t copy errors” are reported in the logs, or “failure to backup” errors. The apply log shows a list of files that could not be backed up or copied.
Files are locked by the operating system (as being in use).
The patching process is attempting to install a new copy of a particular file from the patch source software, but the operating system does not allow it. This can be caused by running Oracle processes, operating system processes such as automated backups, and locks by third party software.
Windows suffers from the severe limitation of only having one environment. For that reason, you must shut down ALL running Oracle Processes running out of ALL Oracle Homes before installing or patching ANY Oracle software on Windows.
The operating system can also lock files, as well as some backup software and anti-virus programs.
The use of failover and failsafe services, both Oracle and non-Oracle, can also lock files, as these services attempt to check on status with client connections. These services must also be stopped when patching on Windows.
The same problem keeps files from being backed up.
The first solution to try is to set all Oracle Services to start in “Manual” mode and reboot before attempting to install the patch using opatch again. The second solution is to boot to Safe Mode to install the patch. Either way, running Oracle processes are removed as a possible cause to this problem.
In every case, DO NOT rollback before trying “opatch apply” again. Simply stop the offending process, then attempt “opatch apply” again.
Opatch failed with below error message
Unable to lock Central Inventory. OPatch will attempt to re-lock. Do you want to proceed? [y|n] n User Responded with: N Unable to lock Central Inventory. Stop trying per user-request? OPatchSession cannot load inventory for the given Oracle Home C:\app\oracle\product\11.2.0\dbhome_1. Possible causes are: No read or write permission to ORACLE_HOME/.patch_storage Central Inventory is locked by another OUI instance No read permission to Central Inventory The lock file exists in ORACLE_HOME/.patch_storage The Oracle Home does not exist in Central Inventory OPatch failed with error code 73
Due to Windows security, OPatch must run in a command window that was opened As Administrator
1.Open cmd.exe As Administrator
2.Apply the patch
%ORACLE_HOME%\OPatch\opatch lsinventory -jdk C:\Program Files\Java\jdk1.6.0_33 File Not Found Java could not be located. OPatch cannot proceed!
space in the directory of java
Use the short name of the folder/directory in the absolute path.
To identify the short name, open DOS prompt (window) and execute the directory command with the “X” flag as below:
C:\> dir /X
You will see an output similar to this:
02/16/2019 12:32 PM <DIR> PROGRA~1 Program Files 03/13/2019 04:42 AM <DIR> PROGRA~2 Program Files (x86)
In the output above, “PROGRA~1” is the directory’s short name.
Navigate to the Java directory as follows:
C:\> cd PROGRA~1\Java\jdk1.6.0_33
So command will be
%ORACLE_HOME%\OPatch\opatch lsinventory -jdk C:\PROGRA~1\Java\jdk1.6.0_33
xml-20108: (fatal error) start of root element expected :Check out this page for the solution on the error org.xml.sax.SAXParseException: : XML-20108 we get while applying the opatch
How to run Opatch in non interactive form : Check how to apply opatch in silent mode
rollback the Oracle patch : check out this on how to rollback the oracle patch like database patch,application patch,Application server patch with detailed steps
opatch failed with error code 73 : Find out the cause and resolution for the topmost common issues in Window while applying patches using opatch
download Patch from Oracle using Wget :Downloading oracle patches from Oracle website is time consuming. We download Patch from Oracle using Wget directly to the server to save time and energy
check patches applied in weblogic :This page contain details on how to check patches applied in weblogic in version 10.3.6,12.1.1,12.1.1 above with commands