X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org Date: Mon, 6 Sep 2010 17:48:41 +0200 From: Corinna Vinschen To: cygwin AT cygwin DOT com Subject: Re: permission denied when removing files on remote file share that is offline Message-ID: <20100906154841.GA17478@calimero.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <5FA595E1BD1AE146A2069381870C99F2FBFC14CB AT icexm6 DOT ic DOT ac DOT uk> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <5FA595E1BD1AE146A2069381870C99F2FBFC14CB@icexm6.ic.ac.uk> 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 6 15:33, Thielemans, Kris wrote: > Hi > > I think my problem appeared after upgrading to cygwin 1.7.7 but it might have been present before that as well, I am not sure. > > I'm using a file share with Offline Folders such that I can access it when not connected to our intranet. In cygwin I cannot remove any files that I create on the share when it's offline: > > $ touch /xxx/testfile > $ rm /xxx/testfile > rm: cannot remove `/xxx/testfile': Permission denied > > I can create/modify the files without trouble, but not delete them. I can delete the file with Windows Explorer. getfacl doesn't show anything strange. I can delte the file once the file share gets @connected@ again. Everything works fine on my local disks. > > This happens both when specifying the file share, or when using a drive letter: > > $ mount //fileserver/myusername$ /xxx > > $ mount h: /xxx > > Some extra info: > $ net use > New connections will be remembered. > Status Local Remote Network > ------------------------------------------------------------------------------- > OK H: \\fileserver\myusername$ Microsoft Windows Network > The command completed successfully. > > after mounting the file share explicitly > $ mount |grep xxx > //fileserver/myusername$ on /xxx type ntfs (binary,notexec,user) Strange. I cannot reproduce this problem. I created a share on a server just for this purpose, then, on the client, made it available offline and synced it once. Then I disconnected the NIC: $ net use Status Local Remote Network ------------------------------------------------------------------------------- Disconnected H: \\fileserver\myusername$ Microsoft Windows Network The command completed successfully. $ touch /mnt/h/xyz/testfile $ rm /mnt/h/xyz/testfile Works like a charm. I tried the same with an additional explicit Cygwin mount, which worked fine as well. Can you run rm under strace? Maybe there's a status code which gives some helpful information. Look for the "unlink_nt" function. 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