• Welcome to Support Forum: Get Support for Patch My PC Products and Services.
 

Java RE update removes PATH variable

Started by FabianSz, May 15, 2023, 09:18:17 AM

Previous topic - Next topic

FabianSz

We had an issue with latest Java rollout JRE 8 Update 371. Oracle did some major changes which broke the e-banking software of one of our banks we make business with.

Additionally, sometimes the Java path in PATH variable was gone, as well as the path "C:\Program Files (x86)\Common Files\Oracle\Java\javapath", which is kind of a link to another folder like "C:\Program Files (x86)\Common Files\Oracle\Java\javapath_target_15148000". The missing PATH broke other java apps which rely on finding the java executable.

Oracle changed the behavior in the past. They moved that "javapath" from C:\Programdata to C:\Program Files (x86): https://support.oracle.com/knowledge/Middleware/2412304_1.html

I've not found the cause of the missing PATH variable, yet. But it seems that the install order of 32-bit and 64-bit is important. Every time I install the 32-bit version AFTER 64-bit (using Patch My PC), the PATH variable is gone. The other way round, it stays.

Same issue happens when I run the setups manually in the following order --> PATH variable is gone.
jre-8u371-windows-x64.exe /s /L C:\Logs\PatchMyPCInstallLogs\jre-8u371-windows-x64.exe-manual.log
jre-8u371-windows-i586.exe /s /L C:\Logs\PatchMyPCInstallLogs\jre-8u371-windows-i586.exe-manual.log

Using the extracted MSI setups (silently) in the "wrong" order, results in the same issue --> path is gone.

But now comes the fun part: Running the EXE interactively, it's all good!!

Looks like it's a bug of Oracles 371 silent mode :-(
Can anyone confirm this behavior?

Jake Shackelford (Patch My PC)

Our Catalog team is actively looking into this one

Andrew Jimenez (Patch My PC)

Following up on this. We have had 1 other customer report a similar issue, however, because the issue is with the Java installer itself, there is not much we can do to remedy it. We have looked at different install commands and have been unable to resolve the issue ourselves. We'll continue to watch the issue, I imagine this issue will be resolved with Java 381 in July.

FabianSz

Thanks, Andrew!

The only solution for now would be to force the correct order. 32-bit first, 64-bit second. I do that using an "Application Group".

But using Software Updates, it probably relies on alphabetical order. Which results in deploying "x64" BEFORE "x86". So, better naming would be "32-bit" and "64-bit" ;-)

FabianSz

The fun part:

1. install Java 371 64-bit
2. path "C:\Program Files (x86)\Common Files\Oracle\Java\javapath" appears
3. install Java 371 32-bit
4. path "C:\Program Files (x86)\Common Files\Oracle\Java\javapath" is gone
5. uninstall Java 64-bit
6. path "C:\Program Files (x86)\Common Files\Oracle\Java\javapath" magically appears!
7. install Java 64-bit
8. path "C:\Program Files (x86)\Common Files\Oracle\Java\javapath" stays

Interesting and surprising are 5. and 6.

ponda2

You mentioned that Oracle made changes in the past, moving the "javapath" folder from C:\ProgramData to C:\Program Files (x86). You also observed that the install order of the 32-bit and 64-bit versions of Java may be important, as installing the 32-bit version after the 64-bit version caused the PATH variable to go missing.

FabianSz

Yes :-)

Could be different today with current Java Runtime 401.