71

I am facing a small issue and need help on it.

I had to re-install Windows on my laptop. After that I installed Java, extracted Eclipse and set the environment variables, namely Path to the Java bin directory and also created a JAVA_HOME variable and set it. Every time I try opening eclipse.exe I get the following error.

The eclipse executable launcher was unable to locate its companion launcher jar.

What am I missing here?

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Ajay
  • 1,796
  • 3
  • 18
  • 22
  • 1
    Eclipse can start without anything else than the raw JRE installed. Perhaps you should undo some of your settings? – Thorbjørn Ravn Andersen Jun 04 '12 at 06:09
  • 2
    possible duplicate of [Eclipse executable launcher error: Unable to locate companion shared library](http://stackoverflow.com/questions/7070968/eclipse-executable-launcher-error-unable-to-locate-companion-shared-library) – Caterpillar Dec 12 '14 at 13:56

20 Answers20

78

The most common reason for this message seems to be unzipping the eclipse zip file wrongly (for instance unzipping without recreating the directory structure). Therefore please unzip the zipped Eclipse again with a good unzip tool (like 7-zip) and make sure that the necessary sub directories are created during the extraction.

Also make sure that the path to the unzipped Eclipse does not get very long. I've seen cases where Eclipse was unzipped into a deeply nested directory structure (to put it at some place into an SVN repository) and that led to the same error message.

If that still doesn't work, you may try launching eclipse.exe with administrative rights. That should not really be necessary, but maybe your access rights are somehow broken after the re-installation of Windows.

Bananeweizen
  • 21,797
  • 8
  • 68
  • 88
  • 1
    This fixed also a similar problem with - "The eclipse executable launcher was unable to locate its companion shared library" I used winrar to fix it... – CustomCase Nov 05 '12 at 11:38
  • 3
    Extracting with WinRAR instead of Windows 8 zip integration did the trick for me. – Daniel Imms May 18 '13 at 03:20
  • 1
    This can also happen if you are copying eclipse from a new location to an old location for which env. variables are set (to replace the old installation, if it is not working for any reason). If you attempt to start eclipse before the copying has completed, you will get this error. – Sumod Oct 22 '13 at 04:21
  • 1
    Also wait for the unzipping to complete. The extraction window was hidden and I tried running the executable. Obvious user error. – NuclearPeon Apr 28 '14 at 19:29
  • 7-Zip sorted me out. Thanks :) How I knew it was this was to open up the AnypointStudio.ini in the installs folder, then look for each of the files it references in the plugins/... folder. In my case the following folder was missing after the zip extraction "org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20150204-1316". It was referenced in the ini file but not on the file system. I then looked in the zip file (double click in windows) and saw that it was in the zip file (but not there after extraction). Thanks! – Garth Nov 11 '15 at 05:19
  • awesome explanation. helped me instantly – RISHI KHANNA Sep 27 '17 at 11:41
  • Shorter path makes it run. – romsky Nov 07 '18 at 10:14
  • 3
    I have used mc (midnight commander) for extraction and it had asked me to overwrite some file. It seems, that it have some problem with extraction and I have end with same error. Using `tar xvzf file.tar.gz` command for extraction has helped me. – Lubo Sep 04 '19 at 11:27
22

Edit the eclipse.ini file and remove these two lines:

-startup
plugins\org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar 
j0k
  • 22,600
  • 28
  • 79
  • 90
guest
  • 229
  • 2
  • 2
  • 1
    thanks. for me though, the path had changed. Once I edited the path so it was correct again - I could load Eclipse without removing those lines. – Stevanicus Jul 17 '14 at 16:40
  • 4
    you are absolutey right. It works but can you explain these lines. What do they do – Zar E Ahmer Mar 27 '15 at 10:13
8

Same issue on my Mac with a pre-packaged RCP client that was unzip only. The other answers pointed me to the eclipse.ini where all the paths looked valid, tried to check the working directory of my Eclipse bundle that doesn't see that easy to do. Seems when Finder starts an application it's working directory is / so that seems to be the issue.

Updated both references in my eclipse.ini to absolute paths and voila!

-startup
/Applications/RCPClient/client/eclipse/plugins/org.eclipse.equinox.launcher_1.1.1.R36x_v20101122_1400.jar
--launcher.library
/Applications/RCPClient/eclipse/plugins/org.eclipse.equinox.launcher.cocoa.macosx.x86_64_1.1.2.R36x_v20101019_1345
...
Sean
  • 643
  • 8
  • 10
5

Solution for Mac

Reason: Eclipse is copied from one location to another.

Solution: Need to update path(s) in eclipse.ini. My eclipse.ini was found in /Applications/eclipse/Eclipse.app/Contents/MacOS/eclipse.ini.

We need to update the path for plugins\org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar.

Jonny Henly
  • 4,023
  • 4
  • 26
  • 43
sabbir
  • 686
  • 1
  • 9
  • 15
4

You have to copy in Users/user/.p2 and .eclipse from old location when it come from and older location. For example i made a copy from computer to another, and i had this error, then i copied those folders and it worked !

cyril
  • 872
  • 6
  • 29
3

I've the same problem, and the below solution exactly work for me....!

Edit eclipse.ini file and remove these two lines:

--launcher.library .%%..\eclipse\plugins\eclipse\plugins\org.eclipse.equinox.launcher.win32.win32.x86_1.1.200.v20120522-1813

Make sure make a separate copy of this file before any changing...:)

Arsalan
  • 513
  • 1
  • 7
  • 22
3

You might want to check that library

**org.eclipse.equinox.launcher_(version).dist.jar**
and 
**plugins/org.eclipse.equinox.launcher.gtk.linux.x86_(version).dist**
exists on your system. 

Make sure that the version of libraries mentioned in eclipse.ini and the version that exists on your system is same. Usually after upgrade this mismatch occurs and eclipse fails to locate the required jar. Please take a look at this blog post here

teardrop
  • 420
  • 6
  • 11
3

I just had this problem and it seems to be related to permissions somehow. I initially unzipped it to my Program Files folder, in Windows 8. After unzipping it directly to C: the program started normally.

julealgon
  • 7,072
  • 3
  • 32
  • 77
  • 2
    Also had a permissions issue. Installed it as admin and then tried to run as user. And, as it turned out, had no rights to view admin's home directory with necessary files. – Antenka Dec 29 '15 at 11:27
3

Please Check "eclipse.ini" file:

Normally there should not be any hard code path like:
(For example)
P:\eclipse\plugins\org.eclipse.equinox.launcher.win32.win32.x86_1.1.200.v20140603

If you see anything like this please follow these steps:
1. Make Backup of the file
2. Then open the file original file in Editor
3. change the static path to :-- plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.200.v20140603 (and save file and open your eclipse it will work amazing)

Prashant Kumar
  • 145
  • 1
  • 11
2

open eclipse.ini and replace with this ~

-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.200.v20120522-1813
-product
com.android.ide.eclipse.adt.package.product
--launcher.XXMaxPermSize
256M
-showsplash
com.android.ide.eclipse.adt.package.product
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vmargs
-Dosgi.requiredJavaVersion=1.6
-Xms40m
-Xmx768m
-Declipse.buildId=v21.0.0-531062

this work for me, good luck ~

splatter_fadli
  • 761
  • 4
  • 16
  • 32
2

Run eclipse.exe file as an Administrator. It worked for me

Sachindra N. Pandey
  • 1,177
  • 17
  • 15
1

I got this error because on Windows the Zend Studio Icon in the Start Menu was still pointing at the previous version of Zend Studio. Once I changed the target to the new path, the error went away.

Onshop
  • 2,915
  • 1
  • 27
  • 17
1

My issue was much simpler. I had created a shortcut to launch the eclipse executable by dragging it from the folder to the screen. Clicking on the created shortcut icon gave the above error.

Issue: the executable was getting launched from the desktop location instead of the eclipse directory where it had been unzipped.

Solution: Create a new shortcut by right-clicking in the desktop area and providing the target executable from the browse window. This creates the shortcut properly and launches the executable from the right home directory.

Nanda Ramesh
  • 131
  • 1
  • 1
  • 5
1

I Had same problem and it seems that there is wrong "--launcher.library " address in eclipse.ini file. so I have just changed it and

amirani
  • 260
  • 3
  • 9
1

In my case I had to redownload it, something was wrong with the one I downloaded. Its size was far much less than the one on the website.

Mohamed Khamis
  • 7,731
  • 10
  • 38
  • 58
1

just add -vm C:\Java\JDK\1.6\bin\javaw.exe before -vmarg in eclipse.ini this works for me.Hope this will help you good luck...

1

Windows 8 follow these 3 steps:

  1. Locate eclipse file.
  2. create shortcut on desktop.
  3. Double click on the eclipse shortcut to open the application.
Vikas Gupta
  • 4,455
  • 1
  • 20
  • 40
1

I was facing the same issue with Eclipse JUNO & windows XP. After changing a lot of things in eclipse.ini still it was not working and then i deleted it, i don't know why its starts working after deleting this init file. You may try for yours

The PowerHouse
  • 560
  • 14
  • 29
1

On windows Eclipse installer app writes also below admin user directory. And when I started the same eclipse as normal (another) user, it could not find admin users ecplise directory. That directory is in eclipse.ini file. (This installer has made for neon eclipse.)

Tuomas
  • 169
  • 2
  • 4
0

Can't believe that this could occur with Eclipse Version 2022.09.

I have to use tar xzf eclipse-inst-jre-linux64.tar.gz to unpack a runable version. With Midnight Commander the unpack seems ok but wasn't.

Lars
  • 3,576
  • 2
  • 15
  • 13