Re: XATTR option does NOT work for chattr attributes

[email protected] (Joerg Schilling) Fri, 21 Sep 2007 18:27:41 +0200
Newsgroups gmane.comp.archivers.star.user
Message-ID <46f3f0fd.0lTP2LdM1gdhVlJm%[email protected]>
"Vincent Callanan" <[email protected]> wrote:

> > OK, what  you get from chartte is just a few "free" bits from 
> > the UFS on disk 
> > inode.
>
> so -xfflags should preserve immutable flag, right?
> but they don't on my installation. That's when I started trying -xattr ;-)
>
> > File flags are implemented since 2001.
> > Star should support to completely restore the file flags.
> > If you have a problem, send a tar archive with a single empty 
> > file that cannot 
> > be restored correctly.
>
> I have attached a star archive of a single empty file.
> Here's what I did to create it.

I'll check it..

> # cd ~
> # mkdir src
> # cd src
> # touch test
> # chattr +i test
> # lsattr
> ----i------------ ./test
> # cd ..
> # mkdir dst
> # star -cp -xfflags -C ~/src . f=src.star
> # star -xp -xfflags -C ~/dst f=src.star
> # cd dst
> # lsattr
> ----------------- ./test
>
> So clearly, immutable flag is not preserved in backup/restore process on my
> Linux box.
> I also tried -Hexustar option (just in case it is not the default) but that
> did not make any difference.
>
> BTW, there is a note in man page about -xfflags on Linux being "buggy by
> design" (wonderful expression!!). Is that just historical or is it still the
> case?

Yes, the problem is that you need to open the file and do an ioctl(), but the 
open on the wrong file will rewind a tape media.......

Jörg

-- 
 EMail:[email protected] (home) Jörg Schilling D-13353 Berlin
       [email protected]                (uni)  
       [email protected]     (work) Blog: http://schily.blogspot.com/
 URL:  http://cdrecord.berlios.de/old/private/ ftp://ftp.berlios.de/pub/schily