Skip to main content
CYewe
Associate
February 3, 2019
Solved

Can't start. Getting message, "The registry refers to a nonexistent Java Runtime Environment installation or the runtime is corrupted."

  • February 3, 2019
  • 8 replies
  • 2379 views

Using Windows 7, 64 bit. Installed Keil uVision5 first and can run. Install of STM32CubeMX had no issues but can't run the application. Have updated Java, uninstalled CubeMX and reinstalled CubeMX and getting the same message. Not sure about editing the registry -- don't want to screw it up. Any help would be great. Thanks!

This topic has been closed for replies.
Best answer by CYewe

Hi Nesrine,

Thank you for your help and time on this issue. I installed Java from the link you provided and STM32CubeMX is now working. And I have my Nucleo board running code! I must have been trying to use a 32bit version of Java, or something. Thanks also to Clive Two.Zero and the ST Community!

8 replies

Tesla DeLorean
Guru
February 3, 2019

Should be a Java control panel app to check versions and cleanup

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
CYewe
CYeweAuthor
Associate
February 3, 2019

Control Panel indicates the last update (today) is Version 8 Update 201. Changed various security setting with no result. Same error message.

Tesla DeLorean
Guru
February 3, 2019

Then your alternatives here get to be to inspect and modify the registry. Start by inspection so you can provide useful feedback to ST so they might be able to understand/address/resolve issues.

Problem is that there a million ways a system in the field may be configured, and systems get registries cluttered with junk, and dependencies on drivers, DLLs, applications which might no long be valid or internally coherent.

Search on terms like "Java", "Java Runtime", "JRE" to locate the nodes. You're looking for random crap not related to the current installation, ie zombie nodes or data that is ambiguous or inconsistent.

'Software\JavaSoft\Java Runtime Environment'

@Nawres GHARBI​  consider providing diagnostic and analysis software which can determine why a system won't work, and sufficient depth of reporting that you can understand the system as it exists, and fails, so you can fix and address problems not seen from local testing.

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
CYewe
CYeweAuthor
Associate
February 3, 2019

Using Registry Editor, I find the folder 1.8.0_65 (with a sub folder: MSI) Double-click on JavaHome and get the Value data: C;\Program Files\Java\jre 1.8.0_65. Paste this in File Explorer and get the message, "Can't find...jre 1.8.0_65". That folder contains the STM32CubeMX.exe and related folders.

Any ideas on my next step?

Tesla DeLorean
Guru
February 4, 2019

Semi-colon looks dodgy

"C:\Program Files (x86)\Java\jre1.8.0_151" using this 32-bit version here

File Export the JavaSoft registry node and provide for ST to review

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
CYewe
CYeweAuthor
Associate
February 4, 2019

Thanks. Yes that semi-colon was wrong but it was my typo -- I didn't cut & paste. The value data has a colon. Anyway, that path seems to be wrong -- it is the directory for the STM32Cube app. So, I did export the JavaSoft registry to a file; who do I send it to, or do I post here? Sorry, I'm new to this.

Tesla DeLorean
Guru
February 4, 2019

You could attach it here, or in a PM to @Nawres GHARBI​ @Khouloud GARSI​ 

Hopefully someone will review/respond, or I will escalate the issue from my end.

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
CYewe
CYeweAuthor
Associate
February 6, 2019

I posted the file here and sent to Nawres. Now I see nothing here.

Technical Moderator
February 7, 2019

Hello,

Your feedback has been raised internally to CubeMx for check.

We will come back to you soon with update.

Kind Regards,

Imen

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks
Nesrine.JLASSI
Visitor II
February 8, 2019

​Hi @CYewe​ 

I redid the same scenario described: i used Windows 7, 64 bit. Updated the version of Java (Version 8 Update 201) from this link:

https://www.java.com/en/download/windows-64bit.jsp

Installed Keil uVision5 then the STM32CubeMX ==> Everything is working correctly.

Regards,

Nesrine.

Tesla DeLorean
Guru
February 8, 2019

I think the larger problem is the ability to diagnose what's wrong with systems in the field, where you're likely to find a much broader set of circumstances. Especially the ability to unpack "The registry refers to a nonexistent Java Runtime Environment installation or the runtime is corrupted." where it outputs the keys and values in the registry it is complaining about, and checking the existence of the file specified. And to check if any secondary registry entries point to valid installations.

The issue is not the 99.99% of systems on which it functions, but the 0.01% where it doesn't. Ones where "try reinstalling" and expecting different results.

You also want something that can fix or cleanup broken environments, or automates the process.

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
CYewe
CYeweAuthorBest answer
Associate
February 8, 2019

Hi Nesrine,

Thank you for your help and time on this issue. I installed Java from the link you provided and STM32CubeMX is now working. And I have my Nucleo board running code! I must have been trying to use a 32bit version of Java, or something. Thanks also to Clive Two.Zero and the ST Community!