Paul Wayper | 11 Jul 01:42 2007
Picon
Picon

Re: What kind of EA is saved?

Alexander Skwar wrote:
> [...]
> Adding file to archive: /dev/shm/.backup/etc/etc-update.conf                                    
> Saving Extended Attributes for /dev/shm/.backup/etc/system.jwmrc                                
> Saving Extended Attributes for /dev/shm/.backup/etc/nagios                                      
> Saving Extended Attributes for /dev/shm/.backup/etc/nagios/.keep                                
> [...]
>
> What kind of EA is DAR saving here? As far as I know, /etc/system.jwmrc
> doesn't have any EA:
>
> askwar <at> hetzner ~ $ sudo getfattr /etc/system.jwmrc
> askwar <at> hetzner ~ $ ls -la /etc/system.jwmrc
> -rw-r--r-- 1 root root 4035 Mar 11  2006 /etc/system.jwmrc
>   
If you're running SELinux, your security context information is in a
special system attribute that users don't normally see.  You can see
this by using the -Z option to ls:

[root <at> test ~]# ls -laZ /etc/sysctl.conf
-rw-r--r--  root root system_u:object_r:etc_t          /etc/sysctl.conf

> Note: When I do a backup, I create a LVM snapshot and mount it
> to /dev/shm/.backup. This means, that /etc and /dev/shm/.backup/etc
> is essentially the same.
>   

That's a very good idea and one I should use.  Ta!

Have fun,
(Continue reading)

Alexander Skwar | 11 Jul 09:54 2007

Re: What kind of EA is saved?

Paul Wayper <paul.wayper@...> wrote:

> Alexander Skwar wrote:
>> [...]
>> Adding file to archive: /dev/shm/.backup/etc/etc-update.conf
>> Saving Extended Attributes for /dev/shm/.backup/etc/system.jwmrc
>> Saving Extended Attributes for /dev/shm/.backup/etc/nagios
>> Saving Extended Attributes for /dev/shm/.backup/etc/nagios/.keep
>> [...]
>>
>> What kind of EA is DAR saving here? As far as I know, /etc/system.jwmrc
>> doesn't have any EA:
>>
>> askwar <at> hetzner ~ $ sudo getfattr /etc/system.jwmrc
>> askwar <at> hetzner ~ $ ls -la /etc/system.jwmrc
>> -rw-r--r-- 1 root root 4035 Mar 11  2006 /etc/system.jwmrc
>>   
> If you're running SELinux,

I'm not.

> your security context information is in a 
> special system attribute that users don't normally see.  You can see
> this by using the -Z option to ls:

askwar <at> hetzner ~ $ ls -laZ /etc/system.jwmrc
ls: invalid option -- Z
Try `ls --help' for more information.

Hm. :(
(Continue reading)

Denis Corbin | 20 Jul 13:59 2007
Picon

Re: What kind of EA is saved?


Alexander Skwar wrote:
> Paul Wayper <paul.wayper@...> wrote:
> 
>> Alexander Skwar wrote:
>>> [...]
>>> Adding file to archive: /dev/shm/.backup/etc/etc-update.conf
>>> Saving Extended Attributes for /dev/shm/.backup/etc/system.jwmrc
>>> Saving Extended Attributes for /dev/shm/.backup/etc/nagios
>>> Saving Extended Attributes for /dev/shm/.backup/etc/nagios/.keep
>>> [...]
>>>
>>> What kind of EA is DAR saving here? As far as I know, /etc/system.jwmrc
>>> doesn't have any EA:
>>>
>>> askwar <at> hetzner ~ $ sudo getfattr /etc/system.jwmrc
>>> askwar <at> hetzner ~ $ ls -la /etc/system.jwmrc
>>> -rw-r--r-- 1 root root 4035 Mar 11  2006 /etc/system.jwmrc
>>>   
>> If you're running SELinux,
> 
> I'm not.
> 
>> your security context information is in a 
>> special system attribute that users don't normally see.  You can see
>> this by using the -Z option to ls:
> 
> askwar <at> hetzner ~ $ ls -laZ /etc/system.jwmrc
> ls: invalid option -- Z
> Try `ls --help' for more information.
(Continue reading)

Alexander Skwar | 20 Jul 15:01 2007

Re: What kind of EA is saved?

Denis Corbin <dar.linux@...> wrote:

> Well, it seems that dar misses a feature that let the user known the EA
> names recorded for a particular file. ;-)

Yep, that be a good thing to know :) I wonder from where dar gets
those EA, though. As far as I can tell, those test files have no
EA records. Or did I not look closely enough? If so, could you please
tell me, how I could look "correctly"?

Thanks a lot,
Alexander Skwar

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
Denis Corbin | 20 Jul 15:36 2007
Picon

Re: What kind of EA is saved?


Alexander Skwar wrote:
> Denis Corbin <dar.linux@...> wrote:
> 
>> Well, it seems that dar misses a feature that let the user known the EA
>> names recorded for a particular file. ;-)
> 
> Yep, that be a good thing to know :) I wonder from where dar gets
> those EA, though.

from what the system reports and provides! ;-) The question is rather
why cannot you get access to them from the system provided tools.

> As far as I can tell, those test files have no
> EA records. Or did I not look closely enough?

I guess so, as dar does rely on the system to list and read EA attached
to a particular file. There is very little chance that a bug fakes the
presence of EA with dar while none are present (must first fake the
number of EA, then fake the name of each then fake the value of each).

> If so, could you please
> tell me, how I could look "correctly"?

for user namespaces:
   getfattr -d <filename>

for system namespaces:
   getfacl <filename>

(Continue reading)


Gmane