diff options
author | Avra Sengupta <asengupt@redhat.com> | 2014-03-04 02:08:51 +0000 |
---|---|---|
committer | Rajesh Joseph <rjoseph@redhat.com> | 2014-03-07 04:32:12 -0800 |
commit | 96968a916336f70bfc77a353c6b31d4dedd91167 (patch) | |
tree | a995cb1ab55bf937262c04b05fb1d9b2d26c571e /cli | |
parent | b121434902d5839938045294cfdfe2a86e01a951 (diff) |
glusterd/mgmt_v3 locks: Using snaps as an entity for mgmt_v3 locks.
Created framework to process single volume lock, single snap lock,
multiple volume locks, multiple snap locks, and multiple snap and
volume locks requests.
Change-Id: I3f87bdec0bf142d6a1fd3f9d9f5012cc44eaf4bd
Signed-off-by: Avra Sengupta <asengupt@redhat.com>
Reviewed-on: http://review.gluster.org/7189
Reviewed-by: Rajesh Joseph <rjoseph@redhat.com>
Tested-by: Rajesh Joseph <rjoseph@redhat.com>
Diffstat (limited to 'cli')
-rw-r--r-- | cli/src/cli-cmd-parser.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/cli/src/cli-cmd-parser.c b/cli/src/cli-cmd-parser.c index 5e23d87f8..727206ab0 100644 --- a/cli/src/cli-cmd-parser.c +++ b/cli/src/cli-cmd-parser.c @@ -3504,6 +3504,15 @@ cli_cmd_snapshot_parse (const char **words, int wordcount, dict_t **options, if (!strcmp (w, "restore")) type = GF_SNAP_OPTION_TYPE_RESTORE; + if (type != GF_SNAP_OPTION_TYPE_CONFIG) { + ret = dict_set_int32 (dict, "hold_snap_locks", _gf_true); + if (ret) { + gf_log ("", GF_LOG_ERROR, + "Unable to set hold-snap-locks value as _gf_true"); + goto out; + } + } + cmdi = 2; /* Check which op is intended */ |