22

I'm using a standalone version of Aptana and I have just finished reformatting. When I tried to launch Aptana I got this error:

Could not launch the product because the specified workspace cannot be created. The specified workspace directory is either invalid or read-only.

How can I solve this?

Bill the Lizard
  • 398,270
  • 210
  • 566
  • 880
ahmedelgabri
  • 1,228
  • 3
  • 17
  • 30
  • Sounds like the path you are using for your workspace is either invalid or read only. Where is your workspace located? Does the parent directory exist? Do you have write access to it? – Suppressingfire Dec 02 '09 at 03:46
  • See if you have the latest version that matches up with what's on their website. They made some really big changes and you may be way behind. – philfreo Dec 02 '09 at 03:53
  • i`m on a new installation so i don`t have a workspace yet and i`m using the latest version from the website – ahmedelgabri Dec 03 '09 at 01:48

3 Answers3

43

I just ran into this same issue. It's caused by having your "My Documents" folder mapped to a different drive. The installer and program assume it's located on the C:\ drive and attempt to create or open the workspace there.

To fix the issue:

Create a new shortcut for Aptana (or modify the existing one) and add a -data parameter with the path to your workspace folder (by default under your documents). On my system it is setup like so:

 "C:\Users\Lance\AppData\Local\Aptana Studio 2.0\AptanaStudio.exe" -data "E:\Documents\Aptana Studio Workspace"

Viewing the error log:

A log file is written in the /configuration/ folder of the program each time you attempt to launch the program. The log files look like they are named after some kind of timestamp (1259818956579.log). Inside the log file there is a detailed error message with the -data solution:

Root exception: java.lang.IllegalStateException: The platform metadata area could not be written: C:\Users\Lance\My Documents\Aptana Studio Workspace.metadata. By default the platform writes its content under the current working directory when the platform is launched. Use the -data parameter to specify a different content area for the platform.

Lance McNearney
  • 9,410
  • 4
  • 49
  • 55
10

This can happen if you copy the Aptana folder from one machine to another and the usernames or update one machine and change your username. Try checking the file "configuration/.settings/org.eclipse.ui.ide.prefs" if you have it and make sure any references to locations reflect your current environment.

You can try to comment or delete the line with: RECENT_WORKSPACES key.

Community
  • 1
  • 1
Keith Hughitt
  • 4,860
  • 5
  • 49
  • 54
2

I had the same error message with "Aptana Studio 3" on Fedora 12.

I removed spaces from directory names in the path where Aptana is stored and updated the corresponding path in the config file;

configuration/config.ini

Tom.

Tom
  • 21
  • 1