Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 319270

Summary: Long file paths make Virgo unusable for my target audience
Product: [RT] Virgo Reporter: Pete Carapetyan <pete>
Component: unknownAssignee: Project Inbox <virgo-inbox>
Status: CLOSED WORKSFORME QA Contact:
Severity: normal    
Priority: P3 CC: eiswind, glyn.normington, zteve.powell
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows Vista   
Whiteboard:

Description Pete Carapetyan CLA 2010-07-08 10:03:12 EDT
Build Identifier: 2.1.0.M01

The simple act of trying to install Virgo as a user might violates Windows file length limitations and prevents me from considering virgo as a candidate platform.

Obviously I should feel embarrassed for Microsoft to have created such a silly problem for their users, but this is something that is beyond my control.

Since I cannot choose my user's target platform, this makes virgo unusable as a target launch platform for my app. I can't vouch for virgo's intended user base, so I have no idea if this is would be a problem for others or not. It is possible that it was never intended for use by this audience, so it may not be a problem.

Reproducible: Always

Steps to Reproduce:
1. unzip virgo to c:/dev - works fine
2. imitate typical user by copying it to where is convenient such as c:/work/master/project/launchTemplate/virgo
3. Observe as it fails to copy some files due to file length problems.
Comment 1 Glyn Normington CLA 2010-07-09 04:33:44 EDT
I'm afraid there isn't a good solution as this is basically a Windows limitation. We have always recommended unzipping dm Server/Virgo into C:\ to avoid such problems. The only thing you can do is to ensure that your customers install similarly, although I realise that this may be tricky to achieve if you are packaging Virgo inside some kind of installer.
Comment 2 Steve Powell CLA 2010-08-02 07:04:02 EDT
I'm adding comments here to make this bug easier to find and to cross-reference recent notes.

Windows file pathlength limitation.

See comments in Virgo-Dev http://dev.eclipse.org/mhonarc/lists/virgo-dev/msg00175.html
and related.
Comment 3 Pete Carapetyan CLA 2010-08-03 07:21:33 EDT
A request for logs was made, but I'm not really finding much. Here is the best I could come up with.

serviceability/eventlogs/eventlogs.log:

[2010-08-03 06:09:26.797] startup-tracker              <KE0001I> Kernel starting. 
[2010-08-03 06:09:29.843] startup-tracker              <KE0002I> Kernel started. 
[2010-08-03 06:09:29.852] system-artifacts             <UR0002E> User region failed while deploying initial artifacts. Shutting down. 
[2010-08-03 06:09:29.857] System Bundle Shutdown       <KE0010I> Shutdown initiated. 

serviceability/logs/log.log:

[2010-08-03 06:09:26.801] startup-tracker              org.eclipse.virgo.medic.eventlog.default                         KE0001I Kernel starting. 
[2010-08-03 06:09:29.846] startup-tracker              org.eclipse.virgo.medic.eventlog.default                         KE0002I Kernel started. 
[2010-08-03 06:09:29.854] system-artifacts             org.eclipse.virgo.medic.eventlog.default                         UR0002E User region failed while deploying initial artifacts. Shutting down. 
[2010-08-03 06:09:29.862] System Bundle Shutdown       org.eclipse.virgo.medic.eventlog.default                         KE0010I Shutdown initiated. 

serviceability/logs/virgo-kernel

[2010-08-03 06:09:26.801] startup-tracker              org.eclipse.virgo.medic.eventlog.default                         KE0001I Kernel starting. 
[2010-08-03 06:09:29.846] startup-tracker              org.eclipse.virgo.medic.eventlog.default                         KE0002I Kernel started. 
[2010-08-03 06:09:29.854] system-artifacts             org.eclipse.virgo.medic.eventlog.default                         UR0002E User region failed while deploying initial artifacts. Shutting down. 
[2010-08-03 06:09:29.862] System Bundle Shutdown       org.eclipse.virgo.medic.eventlog.default                         KE0010I Shutdown initiated. 

serviceability/logs/multi-artifact.plan-1

no entries

cygwin console:

$ ./startup.bat
[2010-08-03 06:09:26.797] startup-tracker              <KE0001I> Kernel starting
.
[2010-08-03 06:09:29.843] startup-tracker              <KE0002I> Kernel started.

[2010-08-03 06:09:29.852] system-artifacts             <UR0002E> User region fai
led while deploying initial artifacts. Shutting down.
[2010-08-03 06:09:29.857] System Bundle Shutdown       <KE0010I> Shutdown initia
ted.
Comment 4 Steve Powell CLA 2010-08-03 08:54:43 EDT
We misinterpreted the original bug description.

It talks about *installing Virgo as a user might* and says:
-----8<---
Steps to Reproduce:
1. unzip virgo to c:/dev - works fine
2. imitate typical user by copying it to where is convenient such as
c:/work/master/project/launchTemplate/virgo
3. Observe as it fails to copy some files due to file length problems.
----------

This was assumed to be a run-time error -- we misread line 3.

The problem with this scenario is the method by which COPY is done in step 2.  No 'user' is going to perform a command-line copy during installation, nor are they going to drag and drop.

The COPY command is hopeless -- XCOPY might be attempted:

We observe that XCOPY fails in the osgi work area (created when we tried it out in step 1.) and probably therefore fails to copy some objects which can be anything, not necessarily classes.

If we instead MOVE the directory we created under C:\dev we can put it into C:\work\master\project\launchTemplate\virgo\ws ('ws' is my test) quite happily and cd to that directory and run virgo (-clean) with no trouble at all.

To force problems to occur during run-time I moved ws to \work\master\project\launchTemplate\virgo\deep0123456789\deep0123456789\deep0123456789\deep0123456789\ws and ran it again.

This time I got problems during startup (this time I'm using 2.1.0.M02-incubation) loading the hosted-repository .par file:

[2010-08-03 13:15:26.286] fs-watcher                   <HD0001I> Hot deployer processing 'INITIAL' event for file 'org.eclipse.virgo.apps.repository-2.1.0.M02-incubation.par'.
[2010-08-03 13:15:26.301] Thread-3                     <WE0000I> Starting web bundle 'org.eclipse.virgo.apps.admin.web' version '2.1.0.M02-incubation' with context path '/admin'.
[2010-08-03 13:15:29.364] start-signalling-2           <DE0005I> Started bundle 'org.eclipse.virgo.apps.admin.core' version '2.1.0.M02-incubation'.
[2010-08-03 13:15:29.848] Thread-3                     <WE0001I> Started web bundle 'org.eclipse.virgo.apps.admin.web' version '2.1.0.M02-incubation' with context path '/admin'.
[2010-08-03 13:15:29.864] start-signalling-1           <DE0005I> Started bundle 'org.eclipse.virgo.apps.admin.web' version '2.1.0.M02-incubation'.
[2010-08-03 13:15:29.895] fs-watcher                   <ME0003I> Dump 'serviceability\dump\2010-08-03-13-15-458' generated
[2010-08-03 13:15:29.911] fs-watcher                   <HD0002E> Hot deploy failed for file 'org.eclipse.virgo.apps.repository-2.1.0.M02-incubation.par'. org.eclipse.virgo.kernel.deployer.core.Deploym
entException: listFiles() failed for file C:\work\master\project\LAUNCH~1\virgo\DEEP01~1\DEEP01~1\DEEP01~1\DEEP01~1\ws\work\org.eclipse.virgo.kernel.deployer_2.1.0.M02-incubation\staging\global\par\or
g.eclipse.virgo.apps.repository\2.1.0.M02-incubation\org.eclipse.virgo.apps.repository-2.1.0.M02-incubation.par\
        at org.eclipse.virgo.kernel.install.artifact.internal.StandardInstallArtifactTreeInclosure.createInstallTree(StandardInstallArtifactTreeInclosure.java:129)
        at org.eclipse.virgo.kernel.deployer.core.internal.PipelinedApplicationDeployer.doInstall(PipelinedApplicationDeployer.java:140)
        at org.eclipse.virgo.kernel.deployer.core.internal.PipelinedApplicationDeployer.install(PipelinedApplicationDeployer.java:123)
        at org.eclipse.virgo.kernel.deployer.core.internal.PipelinedApplicationDeployer.deploy(PipelinedApplicationDeployer.java:187)
        at org.eclipse.virgo.kernel.deployer.hot.HotDeploymentFileSystemListener.deploy(HotDeploymentFileSystemListener.java:174)
        at org.eclipse.virgo.kernel.deployer.hot.HotDeploymentFileSystemListener.deployIfNotDeployed(HotDeploymentFileSystemListener.java:186)
        at org.eclipse.virgo.kernel.deployer.hot.HotDeploymentFileSystemListener.onChange(HotDeploymentFileSystemListener.java:87)
        at org.eclipse.virgo.util.io.FileSystemChecker.notifyListeners(FileSystemChecker.java:245)
        at org.eclipse.virgo.util.io.FileSystemChecker.check(FileSystemChecker.java:166)
        at org.eclipse.virgo.kernel.deployer.hot.WatchTask.run(WatchTask.java:58)
        at java.lang.Thread.run(Thread.java:619)
Caused by: org.eclipse.virgo.util.io.FatalIOException: listFiles() failed for file C:\work\master\project\LAUNCH~1\virgo\DEEP01~1\DEEP01~1\DEEP01~1\DEEP01~1\ws\work\org.eclipse.virgo.kernel.deployer_2
.1.0.M02-incubation\staging\global\par\org.eclipse.virgo.apps.repository\2.1.0.M02-incubation\org.eclipse.virgo.apps.repository-2.1.0.M02-incubation.par\
        at org.eclipse.virgo.util.io.FileSystemUtils.listFiles(FileSystemUtils.java:237)
        at org.eclipse.virgo.util.io.FileSystemUtils.listFiles(FileSystemUtils.java:268)
        at org.eclipse.virgo.kernel.artifact.fs.internal.FileArtifactFSEntry.getChildren(FileArtifactFSEntry.java:50)
        at org.eclipse.virgo.kernel.install.artifact.internal.ParPlanInstallArtifact.findChildArtifacts(ParPlanInstallArtifact.java:94)
        at org.eclipse.virgo.kernel.install.artifact.internal.ParPlanInstallArtifact.<init>(ParPlanInstallArtifact.java:85)
        at org.eclipse.virgo.kernel.install.artifact.internal.ParPlanInstallArtifactFactory.createParPlanInstallArtifact(ParPlanInstallArtifactFactory.java:74)
        at org.eclipse.virgo.kernel.install.artifact.internal.PlanInstallArtifactTreeFactory.createParTree(PlanInstallArtifactTreeFactory.java:96)
        at org.eclipse.virgo.kernel.install.artifact.internal.PlanInstallArtifactTreeFactory.constructInstallArtifactTree(PlanInstallArtifactTreeFactory.java:87)
        at org.eclipse.virgo.kernel.install.artifact.internal.StandardInstallArtifactTreeInclosure.constructInstallArtifactTree(StandardInstallArtifactTreeInclosure.java:155)
        at org.eclipse.virgo.kernel.install.artifact.internal.StandardInstallArtifactTreeInclosure.createInstallTree(StandardInstallArtifactTreeInclosure.java:123)
        ... 10 common frames omitted

[2010-08-03 13:15:29.926] fs-watcher                   <HD0001I> Hot deployer processing 'INITIAL' event for file 'org.eclipse.virgo.apps.splash-2.1.0.M02-incubation.war'.
[2010-08-03 13:15:29.942] start-signalling-1           <DE0005I> Started plan 'org.eclipse.virgo.apps.admin.plan' version '2.1.0'.
[2010-08-03 13:15:30.036] fs-watcher                   <DE0000I> Installing bundle 'org.eclipse.virgo.apps.splash' version '2.1.0.M02-incubation'.
[2010-08-03 13:15:30.145] fs-watcher                   <DE0001I> Installed bundle 'org.eclipse.virgo.apps.splash' version '2.1.0.M02-incubation'.
[2010-08-03 13:15:30.176] fs-watcher                   <DE0004I> Starting bundle 'org.eclipse.virgo.apps.splash' version '2.1.0.M02-incubation'.
[2010-08-03 13:15:30.192] Thread-3                     <WE0000I> Starting web bundle 'org.eclipse.virgo.apps.splash' version '2.1.0.M02-incubation' with context path '/'.
[2010-08-03 13:15:30.301] Thread-3                     <WE0001I> Started web bundle 'org.eclipse.virgo.apps.splash' version '2.1.0.M02-incubation' with context path '/'.
[2010-08-03 13:15:30.317] start-signalling-1           <DE0005I> Started bundle 'org.eclipse.virgo.apps.splash' version '2.1.0.M02-incubation'.

and we can see that everything else works fine.

The diagnostic is new to M02, and indicates that the listFiles() method is failing on a directory file.  There are no diagnostics from the method call, it just returns null, and we have a trap specifically to spot this introduced in M02 for other reasons.

Notice that the par file fails but the rest of the system is running fine.  Admin console correctly installed, so a workaround is to simply ignore the hosted-repository app (unless you need to host a remote repository, which is unlikely for the casual user (which this is).
------------------------------------------

I suggest that installation procedures take care to avoid deficient Windows commands, and to advise 'users' to install only using those procedures.  Moving installed products after installation is likely to fail in Windows in any case (although it works better on other platforms), so just don't let users do it.

------------------------------------------

This bug is still closed, but I will change the qualification -- it is not a Virgo problem.

Steve Powell
Comment 5 Glyn Normington CLA 2010-10-22 12:07:48 EDT
*** Bug 328492 has been marked as a duplicate of this bug. ***