summaryrefslogtreecommitdiffstats
path: root/xlators/storage/posix/src
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/storage/posix/src')
-rw-r--r--xlators/storage/posix/src/posix-common.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/xlators/storage/posix/src/posix-common.c b/xlators/storage/posix/src/posix-common.c
index c8f92177952..abe086da105 100644
--- a/xlators/storage/posix/src/posix-common.c
+++ b/xlators/storage/posix/src/posix-common.c
@@ -144,7 +144,13 @@ posix_notify(xlator_t *this, int32_t event, void *data, ...)
switch (event) {
case GF_EVENT_PARENT_UP: {
- /* the parent that posix xlator is up */
+ /* Notify the parent that posix xlator is up */
+ char *volume_id;
+ int ret = dict_get_str(this->options, "volume-id", &volume_id);
+ if (!ret) {
+ strncpy(this->graph->volume_id, volume_id,
+ min(strlen(volume_id), GF_UUID_BUF_SIZE));
+ }
default_notify(this, GF_EVENT_CHILD_UP, data);
} break;