Details
-
Bug
-
Resolution: Fixed
-
Minor
-
None
-
None
-
3
-
9223372036854775807
Description
(setfattr does not allow us to specify XATTR_REPLACE so I used a custom utility.)
n:lustre# rm f0 n:lustre# touch f0 n:lustre# setfattr -n user.foo -v foo f0 n:lustre# getfattr -d f0 # file: f0 user.foo="foo" n:lustre# setfattr -n user.foo -v bar f0 n:lustre# getfattr -d f0 # file: f0 user.foo="bar" n:lustre# strace -e trace=setxattr ~/sys/sys_setxattr -r f0 user.foo baz setxattr("f0", "user.foo", "baz", 3, XATTR_REPLACE) = 0 +++ exited with 0 +++ n:lustre# getfattr -d f0 n:lustre#
This is due to ll_xattr_set_common() using OBD_MD_FLXATTRRM for XATTR_REPLACE:
if (flags == XATTR_REPLACE) { ll_stats_ops_tally(ll_i2sbi(inode), LPROC_LL_REMOVEXATTR, 1); valid = OBD_MD_FLXATTRRM; } else { ll_stats_ops_tally(ll_i2sbi(inode), LPROC_LL_SETXATTR, 1); valid = OBD_MD_FLXATTR; }
Attachments
Issue Links
- is related to
-
LU-9679 Prepare lustre for adoption into the linux kernel
- Resolved