[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: File Notes



On 6/1/07, Manon Metten <manon.metten@gmail.com> wrote:

 Before attr, getfattr or setfattr would work, I had to add the user_xattr
flag to the drive's entry in /etc/fstab and umount/mount the partition. Then
I could define my own "file note" like this:

 attr -s user.comment -V "Just testing..." my.txt
 Attribute "user.comment" set to a 15 byte value for my.txt:
 Just testing...

 attr -g user.comment my.txt
 Attribute "user.comment" had a 15 byte value for my.txt:
 Just testing...

Whereas the "user." part is mandatory and the "comment" part is up to the
user to define.


 Strangely enough, getfattr/setfattr and attr seem to be incompatible.
Here's what I got when I tried to read the previously with attr set
user.comment using getfattr:

 getfattr -n user.comment my.txt
 my.txt: user.comment: No such attribute

 So I guess I have to stick to either one of them.

I'm confused between attr, getfattr and setfattr. Which one to use.
What are the differences and advantages of one over others? For simple
use, which is better?

Regards,
Deboo

--
Please don't Cc: me, I'm subscribed to the list.



Reply to: