Apr 17 2008

fix eclipse errors

Posted by mark at 9:39 PM
1 comments
- Categories: Eclipse

My eclipse installation was throwing some odd errors when doing basic things, like closing files...most irritating, so I tried the only two things I knew how to without conducting some google based investigations! the first is really the common sense first step which was to check for updates to my build and the various plugins I have installed, this gave no joy...I was still getting the silly errors. Next up was to run the -clean statement, I've not been unlucky enough to find anything that this can't fix yet and am happy to say it fixed these errors too.

So, how to use this comand? (it should be noted that I run Ubuntu Linux, these steps will be slightly different for windows/mac i'd imagine) Basically if eclipse is on your path,you can simply call eclipse -clean in the terminal and off you go, the startup takes a little longer than normal but it clears out your whole workspace of all the data thats built up installing stuff, updating stuff and also just the general mess that gets caused with heavy use. In my case, I didn't have eclipse available in that manner so I opted for my preferred method as below:

  1. Open the terminal and type locate eclipse.ini, this returns the location of the file you want.
  2. Type nano eclipse.ini to edit the file with nano(funnily enough!) and add the -clean statement to the first line, save and close the file then start up eclipse again, the startup time will be a bit longer but thats just eclipse doing it's thing.
  3. Remember to edit eclipse.ini and remove -clean , you dont need to do this that often and it's not much to remember!

Hope this helps someone, like I said, I've not found anything (yet!) that the -clean statement doesn't fix and it's a good first or second step to try before getting into the guts of the matter and starting to think about a re-install.

Comments

James Buckingham

James Buckingham wrote on 04/18/08 11:11 AM

Do you know what, I thought I'd try that by putting it in the properties of my shortcut only to find it's there already. Didn't actually notice a slow opening either, must have just got used it lol.

A couple of other helpful things / plugins for you..

1) Eclipse comes with an error log facility built in which Andy Jarrett blogged about a while back. That's quite handy. Link is:
http://andyjarrett.co.uk/andy/blog/index.cfm/2007/6/19/Eclipse-error-logs

2) Eclipse has got a terrible habit of swallowing up memory space and before I gave in and bought more RAM I downloaded this funky little plugin called "Memory Manager". Link is:
http://www.eclipse-plugins.info/eclipse/rating_details_plugin.jsp?plugin_id=495

It monitors the RAM usage of Eclipse and also has a cool Garage Collector on it as well so if things slow down just hit that button :-).

3) Finally have a look at this:
http://www.qualityeclipse.com/doc/memory/content.html

Which is a way you can pass parameters to Eclipse when it first opens which restricts the amount of RAM it uses. Take that with a pinch of salt though becaues when things started getting bad for me it was going way over the limit.

HTH
James

Write your comment



(it will not be displayed)