www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/07/24/10:50:23

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
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
Date: Sat, 24 Jul 2004 15:50:01 +0100 (BST)
From: Vince Hoffman <jhary AT unsane DOT co DOT uk>
To: cygwin AT cygwin DOT com
Subject: Re: rsync and file ownership
In-Reply-To: <cdmp1f$268$1@sea.gmane.org>
Message-ID: <20040724154004.W7162@unsane.co.uk>
References: <407DF7D68DD30440B5CEB70ED234D1CF053F65C3 AT excuswa100 DOT americas DOT unity> <cdmp1f$268$1 AT sea DOT gmane DOT org>
MIME-Version: 1.0


On Thu, 22 Jul 2004, Matthew Dwyer wrote:

> Bakken, Luke wrote:
>   > What I ended up having to do is set CYGWIN=nontsec for my rsync server
> > and client before any transfers. If your directories are set to inherit
> > permissions then the permissions will be set OK based on the parent
> > permissions.
> >
> > For example:
> >
> > $ CYGWIN=nontsec rsync -rtvz server::share /c/foo
> >
> > You can set that variable in your cygrunsrv setup for the rsync daemon.
>
> Thanks, I'd already read that in this group and it helped a lot! :)
>
> The main problem remaining is just that its creating permissions that
> didn't exist on the files prior to the copy.  eg.  If I do a network
> copy (its my test environment, the real thing will be across the
> internet) the files have the same permissions as they started with.  If
> I rsync them, Admin and Everyone only get read access.  Thats what I
> need to change.  I'm running rsync over ssh from dos bat files.  Its not
> going to be interactive.  I don't think I can chown or chmod the files
> once copied (can that be done over ssh non-interactively?).

It can, pretty easily.
assuming pubkey withought passphrase (otherwise maybe have a read on
expect)
ssh user AT host DOT com chmod -<options> /path/to/files

(anything after the user AT host part is treated as a command to be executed
non interactively on the remote host as the specified user, see man ssh
for details)

Vince
>
> Matt.
>
>
> --
> 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/
>

--
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