From 5842656feba99a239b922f8099fb336c66b61929 Mon Sep 17 00:00:00 2001 From: Venky Shankar Date: Tue, 21 Feb 2012 14:23:13 +0530 Subject: Introduce new extended attribute: node-uuid Request for trusted.glusterfs.node-uuid returns pathinfo like string but containing the UUID of glusterd instead of the backend path for the requested file. This info is benificial for tasks like parallel rebalance that will make use of the UUID for data locality. Change-Id: I766a09cc4a5f63aebd11c73107924a1b29242dcf BUG: 772610 Signed-off-by: Venky Shankar Reviewed-on: http://review.gluster.com/2614 Tested-by: Gluster Build System Reviewed-by: Shishir Gowda Reviewed-by: Vijay Bellur --- libglusterfs/src/glusterfs.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'libglusterfs/src') diff --git a/libglusterfs/src/glusterfs.h b/libglusterfs/src/glusterfs.h index 75476cef801..0ab5767980f 100644 --- a/libglusterfs/src/glusterfs.h +++ b/libglusterfs/src/glusterfs.h @@ -81,6 +81,13 @@ #define GF_XATTR_CLRLK_CMD "glusterfs.clrlk" #define GF_XATTR_PATHINFO_KEY "trusted.glusterfs.pathinfo" +#define GF_XATTR_NODE_UUID_KEY "trusted.glusterfs.node-uuid" + +#define XATTR_IS_PATHINFO(x) (strncmp (x, GF_XATTR_PATHINFO_KEY, \ + strlen (GF_XATTR_PATHINFO_KEY)) == 0) +#define XATTR_IS_NODE_UUID(x) (strncmp (x, GF_XATTR_NODE_UUID_KEY, \ + strlen (GF_XATTR_NODE_UUID_KEY)) == 0) + #define GF_XATTR_LINKINFO_KEY "trusted.distribute.linkinfo" #define GFID_XATTR_KEY "trusted.gfid" -- cgit