Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 26 Dec 2010 14:54:58 -0800
From:      Carl Johnson <carlj@peak.org>
To:        freebsd-questions@freebsd.org
Subject:   Re: cpio misunderstanding?
Message-ID:  <87ipygdu0t.fsf@oak.localnet>
In-Reply-To: <20101226210428.da2114c5.freebsd@edvax.de> (Polytropon's message	of "Sun, 26 Dec 2010 21:04:28 %2B0100")
References:  <if2rdo$tk5$1@dough.gmane.org>	<201012242042.21257.ken@mthelicon.com> <if3fi6$2k4$1@dough.gmane.org>	<AANLkTikP8Wb%2BmpDQpud32sgdVRV3wdfbfhPQvvUkwcey@mail.gmail.com> <20101226210428.da2114c5.freebsd@edvax.de>

next in thread | previous in thread | raw e-mail | index | archive | help
Polytropon <freebsd@edvax.de> writes:

> On Sun, 26 Dec 2010 11:30:59 -0800, David Brodbeck <gull@gull.us> wrote:
>> On Fri, Dec 24, 2010 at 4:57 PM, Joe Kraft <jvk-list@thekrafts.org> wrot=
e:
>> > OK, now I know what's going on. =C2=A0I just don't know why. =C2=A0The=
 immutable flag
>> > was set on all these files, if you clear it cpio will happily copy the=
m to
>> > the new directory.
>>=20
>> Does cpio attempt to preserve flags?  Since the error is "could not
>> create," I'm wondering if it's trying to set the same flags on the
>> copy of the file and failing to do so.
>
> I'm not sure about that - "man cpio" doesn't give a hint
> about flags. On the other hand, tar's -p option does keep
> the file mode (permissions), flags and maybe ACLs intact.
>
> I've tried "info cpio" ouch! ouch!, but that's not a
> continuous manual that allows easy searching for strings. :-(
>
> Some search in the /usr/src/bin subtree for the "chflags"
> call revealed that it is used by the chflags binary, cp,
> mv and rm commands, but no hint it is involved directly
> in cpio.

I had done some testing for flag support out of curiosity, and found
that only cp -p, bsdtar and dump support them.  Cpio, afio, gnutar,
gnucp and pax do not support them.  I also tested extended attributes
(used for ACLs?), and only bsdtar and dump worked for them.  Those
results were for usf, and generally didn't transfer to zfs at all or
probably other file systems.

--=20
Carl Johnson		carlj@peak.org




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?87ipygdu0t.fsf>