Community
Participate
Working Groups
Build Identifier: 3.4.2.201102071137 When you start eclipse that is installed on a remote system from a Windows shortcut (e.g. \\hostname\sharename\path\executable), a stack trace is logged. The platform appears to start just fine, however, when you click Help->Software Updates then another stack trace is logged and the Updates window is not shown. I'll add the stack traces as an attachment. If I map the network drive and start it from there (e.g. z:\executable) then things appear to work just fine. Reproducible: Always Steps to Reproduce: 1. Install eclipse in a shared directory on a remote windows machine 2. Create a desktop shortcut which specifies to start it from the remote location e.g. \\hostname\pathname\directory\executable 3. Startup the platform and the error should occur. Clicking Help->Software updates also logs an exception and no updates panel is shown.
Created attachment 193028 [details] TXT file containing stack trace information Here's a text file containing stack trace information, many thanks.
We've successfully started Eclipse 3.4.2 both on WinXP and Win7 from a UNC path. Is there more information that you can provide about your setup that might help us determine/reproduce the problem?
Also how are we doing on 3.7?
Hi there, Thanks so much for trying this out for me. I can reproduce the problem when my eclipse is installed onto a remote Windows system. The Drive is shared as read-only and eclipse is installed in a directory called O:\eclipse. So on my local client which is Windows XP, I then right-click the desktop and select New->Shortcut. In the 'Create Shortbut' wizard, I then type in '\\hostname\sharename\' and then Windows seems to search and so 'eclipse' comes up as an autosuggest option so I select that and then the eclipse.exe. I give it a name and click Finish. Then I right click on the newly created shortcut and select Properties. In the Properties dialog, in the Target property, I add in the -consoleLog option so that I can see any errors that are logged on startup and click OK to save the change. Then I double click the link and eclipse starts with a DOS console window. In there, I see several exceptions, the first of which starts: !MESSAGE Plug-in "org.eclipse.equinox.p2.ui.sdk" was unable to instantiate class "org.eclipse.equinox.internal.p2.ui.sdk.AutomaticUpdateScheduler". !STACK 0 java.lang.IllegalStateException: Registry Directory not available. at org.eclipse.equinox.internal.p2.engine.SimpleProfileRegistry.restore( SimpleProfileRegistry.java:330) .... Then, if I click the Help->Software Updates... menu item then nothing happens but the exception is again logged in my console window. Please let me know if there's anything else that I can do to help. Many thanks.
What type of file system/OS is the remote one?
The remote OS is a Windows Server 2003 machine and the drive is formatted as NTFS. The drive is also configured as read-only. Interestingly, I've just tried changing that to give write permissions to the user and the problem does not occur. I don't think that this solution is acceptable to our customer who is trying to manage a shared installation where all users access the same drive. It might provide a clue as to where to look though? Does eclipse need write access to the directory that it's installed into?
What are the System property values that you see when you go into "Help -> About -> Configuration Details" for the following properties: eclipse.p2.data.area osgi.configuration.area
From my testing this works OK in 3.7. In 3.4.2, the code in SimpleProfileRegistry#restore is calling java.io.File#isDirectory which is returning false for a read-only folder . We have the same code in 3.7 but registry seems to be constructed in a different manner and is pointing to the user's local config area (which is writable) so we don't see the error.
Simon, this is the bug that I was talking about. The code in and around SurrogateProfileHandler is causing us problems in 3.4.2.
As suspected, this has to do with a subtle problem when converting URLs representing UNC paths to Files. We have a URL which is similar to: file://machine/share/r342/eclipse/p2/org.eclipse.equinox.p2.engine/profileRegistry We then call new File(url.getPath()). This path isn't considered absolute so File pre-pends extra data to it so the absolute path of what we end up with is actually: \\machine\share\r342\eclipse\share\r342\eclipse\p2\org.eclipse.equinox.p2.engine\profileRegistry The code is in SurrogateProfileHandler#getProfileRegistry.
Created attachment 198739 [details] patch Here is a patch. In 3.7 we use the URI class to handle some path issues. I've copied parts of our URIUtil class from equinox.common and called the same code as in 3.7.
Patch released to R34x maintenance branch.