From owner-freebsd-current Thu Jan 30 19: 4: 2 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 738FD37B401 for ; Thu, 30 Jan 2003 19:04:01 -0800 (PST) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id CC5F643F43 for ; Thu, 30 Jan 2003 19:04:00 -0800 (PST) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.6/8.12.5) with SMTP id h0V33qP4035971; Thu, 30 Jan 2003 22:03:52 -0500 (EST) (envelope-from robert@fledge.watson.org) Date: Thu, 30 Jan 2003 22:03:52 -0500 (EST) From: Robert Watson X-Sender: robert@fledge.watson.org To: vidalrod@in.tum.de Cc: CURRENT Subject: Re: copy extended attributes In-Reply-To: <3E39ADBF.5000100@web.de> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=ISO-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, 30 Jan 2003, David Vidal Rodr=EDguez wrote: > After some investigation, I come to the conclusion that there is no > means to copy the extended attributes of a file by using standard > commands like cp (even with the -p option) or mv. At least it works with > mv if the rename(2) syscall is used (ie. moves within the same > filesystem), but as soon as it has to cross filesystems, extended attrs > get lost. Naturally I'm speaking of copying from a UFS2 fs to a UFS2 fs.= =20 >=20 > Am I missing something here or is it really a 'bug'? (or a feature, it > depends :) )=20 I have local patches submitted by Chris Faulhaber to copy ACLs when a file is copied (or moved between file systems) that I've been meaning to finish testing and merge. Likewise, for gzip, bzip, and others when a file is replaced. This wouldn't address the general issue of copying extended attributes, but is a necessary step. Presumably if we did extend cp, et al, to copy EA's, they should explicitly copy only user namespace EAs, not system EAs. There's been some recent e-mail on the Linux side about interfaces to copy ACLs from one file to another, but I haven't had a chance to review those changes as yet to see whether we should pick them up. Using the current EA interfaces, it should be relatively straight-forward to generate a list of user EA names, extract them, and copy them to another node. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message