From: Andreas Gruenbacher <agruen@suse.de>
To: Christoph Hellwig <hch@infradead.org>
Cc: linux-xfs@oss.sgi.com, acl-devel@bestbits.at,
Ales Zelinka <azelinka@redhat.com>
Subject: Re: [RFE] --reference option for setfattr
Date: Mon, 22 Dec 2008 14:47:54 +0100 [thread overview]
Message-ID: <200812221447.54325.agruen@suse.de> (raw)
In-Reply-To: <20081222130103.GA12367@infradead.org>
On Monday, 22 December 2008 14:01:03 Christoph Hellwig wrote:
> On Tue, Nov 04, 2008 at 10:50:58AM +0100, Ales Zelinka wrote:
> > currently when I want to copy all extended attributes from one file to
> > another, I have to use ugly command like this:
> >
> > getfattr --dump -m '-' /etc/samba/smb.conf |sed 's;file:
> > etc/samba/smb.conf;file: /tmp/smb.conf;'| setfattr --restore=-
> >
> > Would you please implement --reference=some_file option that will read
> > all extended attributes set on some_file and set them on pathname?
> >
> > The previous use case would then look like this:
> >
> > setfattr --reference=/etc/samba/smb.conf /tmp/smb.conf
> >
> > Other commands from file-attributes-manipulation familly already have
> > parameter like this (chmod, chown, chcon,...)
>
> This feature seems useful to me, any chance you could try coming up with
> a patch?
getfattr/setfattr are modeled similar to getfacl/setfacl, and with those two
tools you can do this (-b stands for --remove-all):
getfacl /etc/samba/smb.conf | setfacl -b -M - /tmp/smb.conf
Would it make sense to implement this in setfattr in a similar way?
A -b option would be handy in this context as well, of course.
But maybe --reference is more convenient sometimes, and so it should be added
in any case?
Thanks,
Andreas
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
prev parent reply other threads:[~2008-12-22 13:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-04 9:50 [RFE] --reference option for setfattr Ales Zelinka
2008-12-22 13:01 ` Christoph Hellwig
2008-12-22 13:47 ` Andreas Gruenbacher [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200812221447.54325.agruen@suse.de \
--to=agruen@suse.de \
--cc=acl-devel@bestbits.at \
--cc=azelinka@redhat.com \
--cc=hch@infradead.org \
--cc=linux-xfs@oss.sgi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox