Failed to create the Java Virtual Machine when installing Eclipse.

Introduction

When I tried to install Eclipse on my Mac, I was angry with "Failed to create the Java Virtual Machine."

install-error.png

It's the first time I've been humiliated during installation

Of course Java is included

From the conclusion, as expected, the usual one

That's setting -vm to the ini file

procedure

I'm not sure why, but when I fix the ini file with vim I get this error:

usodaro.png

As long as I do it with vim, it seems that I have to put "Eclipse Installer.app" in the trash can.

It works well if you do it with GUI while pushing the feeling of being ridiculous.

Mystery

Procedure outline

  1. Copy "Eclipse Installer.app" to a suitable location
  2. Right-click "Eclipse Installer.app" in Finder> View Package Contents> Open Contents / Eclipse / eclipse-inst.ini with a text editor
  3. Set Java8 path in ʻeclipse-inst.ini`

1. Copy "Eclipse Installer.app" to a suitable location

Normally when you download and click eclipse-inst-mac64.dmg, the eclipse installer should be mounted on / Volumes / Eclipse Installer.

Then, there is "Eclipse Installer.app" in it, so copy it to a suitable location.

This can be GUI or CLI.

Note that the following / Volumes / Eclipse Installer is Read Only, so you cannot edit it unless you copy it.

2. Right-click "Eclipse Installer.app" in Finder> View Package Contents> Open Contents / Eclipse / eclipse-inst.ini with a text editor

There is no supplementary explanation here.

Don't do it with vim as mentioned above

3. Set Java8 path in ʻeclipse-inst.ini`

Add these two lines to ʻeclipse-inst.ini`.

-vm
/Users/tommarute/.jenv/versions/1.8/bin/java

The reason for Java8 is that the installer didn't work with the latest (14) in my environment.

I haven't tried whether it works with Java9.

If you don't have Java8, put it in like this.

$ brew tap AdoptOpenJDK/openjdk
$ brew cask install adoptopenjdk8

It's a shame, but if you have the latest Java, you should have a management tool such as jenv.

Rerun the installer

After modifying the ini file, double-click "Eclipse Installer.app" from the Finder.

You should be able to see the usual screen.

installer.png

Thanks,

Recommended Posts

Failed to create the Java Virtual Machine when installing Eclipse.
I tried to translate the error message when executing Eclipse (Java)
From installing Eclipse to executing Java (PHP)
When the server fails to start in Eclipse
Failed to create the Java Virtual Machine when installing Eclipse.
Settings when installing Mirantis Kubernetes
[Eclipse Java] Development environment setting memo
Ansible: Allow downgrade when installing Docker
About require when setting strong parameters
[Java] Proxy setting method when starting Java
When the hover of Eclipse is hard to see
`Failed to create the host-only adapter` with docker-machine start`
Create a method to return the tax rate in Java
[Java] [jackson] Corresponds to the trailing comma (trailing comma) when parsing JSON.
Input to the Java console
If you want to change the Java development environment from Eclipse
Easy way to create a mapping class when using the API
How to solve the unknown error when using slf4j in Java
I tried to display the calendar on the Eclipse console using Java.
What is JVM (Java Virtual Machine)?
[java8] To understand the Stream API
Create a Java project using Eclipse
[Java] How to create a folder
Welcome to the Java Library Swamp! !!
The road from JavaScript to Java
java Eclipse How to debug javaScript
The first thing to do when you want to be happy with Heroku on GitHub with Eclipse in Java
Update JAVA to the latest version to 1.8.0_144 (when downloading from the web and updating)
Solution when java completion candidate does not appear after updating to eclipse 2018-12
[Java small story] Monitor when a value is added to the List
How to find the total number of pages when paging in Java
I want to get the IP address when connecting to Wi-Fi in Java
How to create your own annotation in Java and get the value
When I wanted to create a method for Premium Friday, it was already in the Java 8 standard API
[Java] How to use the File class
Java reference to understand in the figure
Introduction to java for the first time # 2
[Java] How to use the hasNext function
When deploying the source used twitter4j failed
Java SE8 Silver ~ The Road to Pass ~
[Java] How to use the HashMap class
About the procedure for java to work
[Java] How to use the toString () method
Java implementation to create and solve mazes
Studying how to use the constructor (java)
[Processing × Java] How to use the loop
How to resolve errors when installing Rails 5.1.3
Connect from Java to MySQL using Eclipse
[Java] How to set the Date time to 00:00:00
[Java] How to get the current directory
[Processing × Java] How to use the class
How to install the legacy version [Java]
How to get the date in java
Output of the book "Introduction to Java"
[Processing × Java] How to use the function
Precautions when migrating from VB6.0 to JAVA
I went to the Java Women's Club # 1
[Java] Color the standard output to the terminal
[Java] How to use the Calendar class
[Promotion of Ruby comprehension (1)] When switching from Java to Ruby, first understand the difference.