diff options
author | Vijaikumar M <vmallika@redhat.com> | 2014-02-14 20:01:38 +0530 |
---|---|---|
committer | Rajesh Joseph <rjoseph@redhat.com> | 2014-03-03 22:58:23 -0800 |
commit | fe5927b6bd1ed795c9e85996e7c54c3abe36ceba (patch) | |
tree | d69e25c323a4b57c49af8555db75ff65c9690701 /xlators/mgmt/glusterd/src/glusterd-store.h | |
parent | 60d4f64cea4752f76b9495bdea255b51d09820ff (diff) |
glusterd/snapshot: store location for snap driven changes
Currently snapshot volfiles are stored at:
<workdir>/vols/<volname>/snaps/<snapvol>
With snap driven approach we need to store the volfiles at:
<workdir>/snaps/<snapname>/<snapvol>
Change-Id: I8efdd5db29833b2b06b64a900cbb4c9b9a5d36b6
Signed-off-by: Vijaikumar M <vmallika@redhat.com>
Signed-off-by: Sachin Pandit <spandit@redhat.com>
Reviewed-on: http://review.gluster.org/7006
Reviewed-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-by: Rajesh Joseph <rjoseph@redhat.com>
Tested-by: Rajesh Joseph <rjoseph@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-store.h')
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-store.h | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-store.h b/xlators/mgmt/glusterd/src/glusterd-store.h index 8ddd3e6bd..46f5ffb7f 100644 --- a/xlators/mgmt/glusterd/src/glusterd-store.h +++ b/xlators/mgmt/glusterd/src/glusterd-store.h @@ -68,7 +68,7 @@ typedef enum glusterd_store_ver_ac_{ #define GLUSTERD_STORE_KEY_SNAP_DESC "desc" #define GLUSTERD_STORE_KEY_SNAP_TIMESTAMP "time-stamp" #define GLUSTERD_STORE_KEY_SNAP_STATUS "status" -#define GLUSTERD_STORE_KEY_SNAP_COUNT "count" +#define GLUSTERD_STORE_KEY_SNAP_RESTORED "snap-restored" #define GLUSTERD_STORE_KEY_CG_VOL_COUNT "count" #define GLUSTERD_STORE_KEY_SNAP_MAX_HARD_LIMIT "snap-max-hard-limit" #define GLUSTERD_STORE_KEY_SNAP_MAX_SOFT_LIMIT "snap-max-soft-limit" @@ -104,8 +104,10 @@ int32_t glusterd_store_volinfo (glusterd_volinfo_t *volinfo, glusterd_volinfo_ver_ac_t ac); int32_t -glusterd_store_delete_volume (glusterd_volinfo_t *volinfo, - glusterd_volinfo_t *snapinfo); +glusterd_store_delete_volume (glusterd_volinfo_t *volinfo); + +int32_t +glusterd_store_delete_snap (glusterd_snap_t *snap); int32_t glusterd_retrieve_uuid (); @@ -145,27 +147,24 @@ int glusterd_store_update_volinfo (glusterd_volinfo_t *volinfo, glusterd_snap_t *snap); int32_t -glusterd_store_retrieve_bricks (glusterd_volinfo_t *volinfo, - glusterd_volinfo_t *snap_volinfo); +glusterd_store_retrieve_bricks (glusterd_volinfo_t *volinfo); int32_t glusterd_store_options (xlator_t *this, dict_t *opts); void glusterd_replace_slash_with_hyphen (char *str); + int32_t glusterd_store_perform_volume_store (glusterd_volinfo_t *volinfo); + int32_t -glusterd_store_perform_snap_store (glusterd_volinfo_t *volinfo, char *snapname); -int32_t -glusterd_store_perform_all_snap_store (glusterd_volinfo_t *volinfo); -int32_t -glusterd_store_perform_snap_list_store (glusterd_volinfo_t *volinfo); +glusterd_store_snap (glusterd_snap_t *snap); + int32_t glusterd_store_snap_cg (glusterd_snap_cg_t *cg); + int32_t glusterd_store_delete_snap_cg (glusterd_snap_cg_t *cg); -int32_t -glusterd_store_perform_snap_volume_store (glusterd_volinfo_t *volinfo, - glusterd_volinfo_t *snap_volinfo); + #endif |