From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id EE39613838B for ; Thu, 18 Sep 2014 05:27:37 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 6E504E0B8F; Thu, 18 Sep 2014 05:27:33 +0000 (UTC) Received: from mail-wi0-f173.google.com (mail-wi0-f173.google.com [209.85.212.173]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 3FF9DE0B6B for ; Thu, 18 Sep 2014 05:27:31 +0000 (UTC) Received: by mail-wi0-f173.google.com with SMTP id em10so2384766wid.12 for ; Wed, 17 Sep 2014 22:27:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=mAiqrclp0/x0kA02mc5FIyBI558jcM1h96r6/jslyQQ=; b=ZKzvUGauzjjnCblhFzoBWJUbkbevdNsiAU9feIVjENHtg/t0b1sCxtRGIl7kh+/wEZ Dbh1/vNNPQWat14ayqFEkUzfGRE9n7w4U1nTHIIUSM2VKMHqgzKym16a4qrO1MsrfgRi U6Wop0LNJPyZG0ckX/wk78DgALY6n/PgTkopNONzctHuYD5o50b0KxUIt35Kwm4TXN2z 1pyZ4aDxbwSbN9XwYVP6n0i0ChGAQ/rwrKPgSG5VchNym39xpRAsLmSKIz5teS2QoLYB thEpSRNmUlUznYv8dLTt0viL+nCNGo61lyYicptK+c+eEdzU0kh3WWfLTDdlRNUuolmS Hkiw== X-Received: by 10.180.78.226 with SMTP id e2mr10081538wix.68.1411018050939; Wed, 17 Sep 2014 22:27:30 -0700 (PDT) Received: from [192.168.1.40] ([41.85.145.17]) by mx.google.com with ESMTPSA id dc9sm1553645wib.5.2014.09.17.22.27.29 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Sep 2014 22:27:30 -0700 (PDT) Message-ID: <541A6CF3.3050303@gmail.com> Date: Thu, 18 Sep 2014 07:26:11 +0200 From: Alan McKinnon User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.1.1 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] copy file and preserve ownership References: <20140917225407.GD24503@syscon7> In-Reply-To: <20140917225407.GD24503@syscon7> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-Archives-Salt: 5e8d8bab-ee5a-45ed-ab9c-17e04043340f X-Archives-Hash: ec52f2ea72bbd5c0f7b79d672a5b0658 On 18/09/2014 00:54, Joseph wrote: > I like to use meld to copy file but meld does now preserve ownership of > the file that it copy. > rsyc does but how do I use rysnc to copy let say file that are newer > then certain date ? > > I was trying to use: > find /home/myuser/oldir/* -mtime -60 -exec cp {} /home/myuser/newdir/ \; > > but cp does not preserve file ownership either. Basic Unix principle: Only root can do it because a regular user cannot chown an object cp -a or cp -pr > > I was planning on copying hylafax-files (faxes) from one server to > another and most of those files have ownership "uucp:60002 or "uucp:uucp" > -- Alan McKinnon alan.mckinnon@gmail.com