Free DNS provides easy shared DNS hosting & URL forwarding

Monday, May 18, 2009

Eclipse says "Workspace in use or cannot be created"

Out of the blue, Eclipse is saying that the "Workspace in use or cannot be created". I say ok, probably a lock file was left behind and so I do:
rm ~/workspace/.metadata/.lock

No error (so the file was left behind), yet the problem is not solved. I tried clearing out the workspace path. Same problem.
Googleing, I found this post, so I ran:
sudo gedit /usr/share/eclipse/configuration/.settings/org.eclipse.ui.ide.prefs
removed the RECENT_WORKSPACES line. It works now.


  1. Thanks. Even going to task manager and killing javaw.exe (my case being Windows, but same would work on Unix as well with ps -fu and kill I guess)

  2. this an't working for me
    tried everything ...but didn't undstand wots Sanj suggested

  3. I don't think Sanj suggestion fixes the original problem. He basically suggests to kill+restart eclipse. That did not work for me. However, my solution might not work for you either in case you have a different problem.

  4. Good advice. If this isn't working for you though, it could be that a change occurred involving directory permissions.

    sudo eclipse

    If the workspace opens, your permissions have changed. Close eclipse.
    chown yourUserName /your/workSpace/path

    Open eclipse. You may need to browse to your workspace path again.

  5. Thanks Sanj for the solution. It worked for me. Killing Eclipse and Javaw.exe from Task Manager.

  6. I tried from the installation folder: /opt/eclipse (something like this)
    Use command: sudo ./eclipse

    As a root you can choose the workspace under Apache.

    May work or may not. Worked for me though.