X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=1.7 required=5.0 	tests=BAYES_50,RCVD_IN_DNSWL_NONE,SARE_MSGID_LONG45
X-Spam-Check-By: sourceware.org
MIME-Version: 1.0
In-Reply-To: <20100415084927.GB7865@calimero.vinschen.de>
References: <o2ta9a39a211004142214mfed097abv98beb16fb7db1bfd@mail.gmail.com>  	<20100415084927.GB7865@calimero.vinschen.de>
From: =?UTF-8?B?RnLDqWTDqXJpYyBCcm9u?= <frederic.bron@m4x.org>
Date: Fri, 16 Apr 2010 11:13:07 +0200
Received: by 10.204.154.153 with SMTP id o25mr1488821bkw.68.1271409564761;  	Fri, 16 Apr 2010 02:19:24 -0700 (PDT)
Message-ID: <y2ha9a39a211004160213zd7424075wa8ccc2182b0f20fc@mail.gmail.com>
Subject: Re: rsync: rename .file.JVPk8f -> file: Device or resource busy (16)
To: cygwin@cygwin.com
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

> What you need to find out is what the files for which this happens have
> in common, plus a couple of extra conditions.
They are all .exe files! most of them were created from cygwin using g++.

> =C2=A0Is UAC enabled? =C2=A0Elevated or non-elevated shell?
Access control via Active Directory. No idea about elevation (do not
know that). I am listed in the administrator group of the main machine
I use (corporate PC).

> Are you using the same account on all machines (Active Directory), or do
> you use different accounts (at least one machine is a stand-alone
> workstation)?

In fact since I formatted the disks in ntfs, I have used them on only
one PC (the one used to format the disks). On that PC, I am listed in
the Administrators group. It is rare that I plug the USB disk on
another PC. When it is the case, it is with a different account and
different windows version.

> Is the drive formatted with all permissions for Everyone?
Yes, I removed all other permissions (system, administrators, user,
creater...) and left only Everyone with full control (at the root).

> Which OS are you using, btw?
Windows XP SP3

> Since the error occurs apparently in rename(2), it should be possible
> to reproduce it without rsync, just with mv.
No issue with mv on the same files!

> Do you run a anti-virus/anti-malware program which might interfere here?
Yes I use Symantec. No idea if it is an issue. It was not when my
disks were formatted in fat32.

> I just tried the same on W7 under UAC.  First I rsynced an older
> checkout of the Cygwin CVS repository onto the NTFS formatted USB stick,
> then I updated the CVS checkout, then I rsynced it again.  Worked fine.
Thanks for that.

I identified one file that was permanently failing to be saved had the
following permissions on my hard drive:
- Administraors: full control
- Domain Users: Read&Execute, Read
- MySelf: Modify, Read&Execute, Read, Write
- SYSTEM: full control
- Everyone: Read&Execute, Read
- Users (computer\Users): Read&Execute, Read

I added full control to my-self on the local hard drive and then rsync
worked fine. On the USB disk the remaining ".file.exe.XXXX" has full
control to everyone and only this which is fine.
I then removed again the full control to my-self on the local hard
drive and rsync failed again.

Any clue?

Thanks again,
Fr=C3=A9d=C3=A9ric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

