opatch failing

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

opatch failing

Roshan
Oracle DB 19.3
Windows 64 bit

Hello Erman,

can you please advise why opatch is failing? I am applying the CPU patch Jul 2022 for Windows.

Screenshot_2022-10-18_155217.png

Thanks,

Roshan
Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

Roshan
Java version is 19 64-bit
Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

ErmanArslansOracleBlog
Administrator
It may be caused by using the wrong library.
Specify the jdk.. Use a command line -> opatch -oh $OH -jdk <correct_path> and retry..
After setting the correct env variable on your shell, something like the following should work;
opatch apply -jdk %JDK_HOME% -jre %JDK_HOME%\jre -oh %ORACLE_HOME%

Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

ErmanArslansOracleBlog
Administrator
And ensure you are patching a 64 bit software, with a 64 bit patch..
This may also be caused by using wrong patch (wrong bitsize, wrong arch.). So for instance; maybe you re using a 32 bit patch for patching a 64 bit product.. Please check that as well.
Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

ErmanArslansOracleBlog
Administrator
Resolved?

Please update.
Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

Roshan
No.. still same error. I added the java 1.8 and set the JDK path.
Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

Roshan
For info, Oracle binaries, OS and Opatch is 64 bit
Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

ErmanArslansOracleBlog
Administrator
This post was updated on .
We have that .dll coming from win64 folder, which is probably the location where the 64 bit DLLs reside.
So, that 32bit problem is somewhere else then.. While trying to link that 64bit library, probably 32 bit libraries are taken into account.

You see in the error stack we have oracle.sysman.oii.*.*.win32.. paths.. So that is probably the reason..
Please check your PATH and ORACLE HOME environment variable.. Ensure you are using the correct opatch from the correct Oracle Home which have correct CPU arch.. (64 bit) It seems, it is the opatch that issues 32 bit DLL calls and that's why probably you are failing..

The following ref is for SQL Developer, but it is similar and it will give you the idea ->
ocijdbc18.dll Can't Load 32-bit DLL On AMD 64-bit Platform (Doc ID 2779179.1)
Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

Roshan
Error was due to vcruntimedll.ddl. it was 32 bit. I copied from a 64 bit oracle Windows binary. Then i was able to proceed with the patching. This was trial by error.
Reply | Threaded
Open this post in threaded view
|

Re: opatch failing

ErmanArslansOracleBlog
Administrator
Good..