X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org Date: Fri, 10 Sep 2010 19:09:01 +0200 From: Corinna Vinschen To: cygwin AT cygwin DOT com Subject: Re: Oddities with file deletion on CIFS drive Message-ID: <20100910170901.GF16534@calimero.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <20100910091632 DOT GB16534 AT calimero DOT vinschen DOT de> <37DB6F6163A83BE3A0AA4D4D@[192.168.1.2]> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <37DB6F6163A83BE3A0AA4D4D@[192.168.1.2]> User-Agent: Mutt/1.5.20 (2009-06-14) Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com On Sep 10 09:47, Quanah Gibson-Mount wrote: > The files are created with a native Win32 application (Perforce), > where it is checking these files out of the Perforce repository. > > Here is the output from cacls prior to +w/-w: > build AT zre-win-002 /cygdrive/z/current/WINDOWS/main/20100908131458_ZDESKTOP/ZimbraBuild/templates > $ cacls BUILD_ISYNC_template > Z:\current\WINDOWS\main\20100908131458_ZDESKTOP\ZimbraBuild\templates\BUILD_ISYNC_template > Everyone:F > F > R > Everyone:R These permissions look very weird. > Here is cacls after +w/-w: > Z:\current\WINDOWS\main\20100908131458_ZDESKTOP\ZimbraBuild\templates\BUILD_ISYNC_template > (special access:) > > STANDARD_RIGHTS_ALL > > DELETE > > READ_CONTROL > > WRITE_DAC > > WRITE_OWNER > > SYNCHRONIZE > > STANDARD_RIGHTS_REQUIRED > > FILE_GENERIC_READ > > FILE_GENERIC_EXECUTE > > FILE_READ_DATA > > FILE_READ_EA > > FILE_EXECUTE > > FILE_READ_ATTRIBUTES > > FILE_WRITE_ATTRIBUTES > > > R > > Everyone:R This looks better. The fact that the accounts can't be found is probably because it's running Samba and the drives are not real NTFS, so the SIDs returned by Samba are the artificial SIDs generated from the Unix uid/gid. Btw., just because the Unix user is called "build", it's not necessariliy the same user as the Windows user "build". Actually, if you don't use Samba with winbind and only use WIndows users from AD on both machines, the accounts are different. > Done. I've provided strace output from both rm and rm -f > > Let me know if there is anything else I can provide. I'm not sure. I don't think so. The problem is that the unlink(2) function in Cygwin does not get any error code from any of the OS functions it calls. So, from the Cygwin POV everything worked fine. How is it supposed to know that anything has gone wrong, if the underlying OS doesn't tell? Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Project Co-Leader cygwin AT cygwin DOT com Red Hat -- 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