delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2007/09/17/12:54:59

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Mon, 17 Sep 2007 18:54:15 +0200
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: cross-device mv regression in latest snapshot
Message-ID: <20070917165415.GE22259@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <loom DOT 20070831T154456-530 AT post DOT gmane DOT org> <loom DOT 20070831T161106-229 AT post DOT gmane DOT org>
Mime-Version: 1.0
In-Reply-To: <loom.20070831T161106-229@post.gmane.org>
User-Agent: Mutt/1.4.2.2i
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
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 Aug 31 14:18, Eric Blake wrote:
> Eric Blake <ebb9 <at> byu.net> writes:
> 
> > I'm trying to track down a breakage in cross-device moves in the latest 
> cygwin 
> > CVS code, whether it is in coreutils-9.6-5 or due to a recent cygwin change, 
> > although my current suspect is Corinna's changes.
> 
> I've ruled out my changes in coreutils-9.6-5, as a fresh CVS coreutils build 
> exhibits the same problem.  Rather, via a gdb trace, it appears this call is 
> the problem:
> 
> open("file2", O_WRONLY | O_CREAT | O_EXCL | O_BINARY, 0600);
> 
> It is creating the file on the samba share, then returning -1 as the fd.

This is weird behaviour.  It turned out that this was a result of always
creating a file with a valid security descriptor instead of just a
default descriptor when creating a file on a Samba share.  The security
descriptor has the local user SID in it's ACL, but Samba maintains
another user SID.  There's still no solution for a transparent mapping
between these two SIDs.  Anyway, the behaviour of the NtCreateFile call
is rather strange.  Apparently Samba creates the file first, and then,
afterwards, checks the security descriptor when it should return the
file handle.  It finds that the permissions don't match and *bing*
returns STATUS_ACCESS_DENIED and a NULL handle.  That's not helpful.
I have reverted the patch from last month for now.


Thanks for the report,
Corinna


-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019