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

Bug 360170

Summary: Deleting project fails under NFS
Product: [Tools] PTP Reporter: John Eblen <jdeblen1>
Component: RDT.syncAssignee: John Eblen <jdeblen1>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: beth, g.watson, jeblen, roland
Version: 6.0   
Target Milestone: 6.0.1   
Hardware: All   
OS: All   
Whiteboard:

Description John Eblen CLA 2011-10-06 17:15:36 EDT
Deleting a synchronized project on an NFS (network file system) with the option "delete project contents on disk" selected fails to delete all files.

Errors similar to the following are reported:

error 1:
Synchronization error for project: nd8:

Commit on repo without HEAD currently not supported

error 2:
An exception has been caught while processing the refactoring 'Delete
Resource'

Reason:
Problems encountered while deleting resources.
Comment 1 John Eblen CLA 2011-10-06 17:19:39 EDT
I've traced this to a failure to delete a .nfs file in .ptp-sync/objects/pack
Comment 2 John Eblen CLA 2011-10-06 20:58:19 EDT
This seems to be related to bug 349200
Comment 3 John Eblen CLA 2011-10-07 10:26:19 EDT
I've placed a workaround on the wiki under the "Known Issues" section. The workaround is to close Eclipse, restart, and then delete. This works because the pack files are not yet open on Eclipse startup.
Comment 4 John Eblen CLA 2011-10-07 11:30:47 EDT
I committed a small change to PTP_5_0 and HEAD that disables sync'ing for a project just before it is deleted. Otherwise it's possible, although I've never seen it happen, that a malfunctioning delete could trigger a sync that deletes files remotely.

(Note that the files could be recovered from the git repo, but it would not be obvious how to do it.)
Comment 5 John Eblen CLA 2012-02-14 15:52:39 EST
Fixed in master by closing repository just before project deletion.
Comment 6 John Eblen CLA 2012-03-08 10:17:24 EST
Fixed also in ptp_5_0
Comment 7 John Eblen CLA 2012-06-13 11:10:32 EDT
Refactoring for Juno disabled the fix for this bug. It also occurs on Windows, which locks open files (the pack files used by JGit in this case).
Comment 8 John Eblen CLA 2012-06-21 11:36:43 EDT
Fixed in master