[sheepdog] [PATCH v6 03/17] dog: forbid creating snapshot of hypervolume

Hitoshi Mitake mitake.hitoshi at gmail.com
Wed Mar 5 16:28:44 CET 2014


From: Hitoshi Mitake <mitake.hitoshi at lab.ntt.co.jp>

Currently it is not supported.

Cc: MORITA Kazutaka <morita.kazutaka at lab.ntt.co.jp>
Cc: Valerio Pachera <sirio81 at gmail.com>
Cc: Alessandro Bolgia <alessandro at extensys.it>
Signed-off-by: Hitoshi Mitake <mitake.hitoshi at lab.ntt.co.jp>
---
 dog/vdi.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/dog/vdi.c b/dog/vdi.c
index b3a6bef..c0f6bf0 100644
--- a/dog/vdi.c
+++ b/dog/vdi.c
@@ -506,6 +506,11 @@ static int vdi_snapshot(int argc, char **argv)
 	if (ret != EXIT_SUCCESS)
 		return ret;
 
+	if (inode->store_policy) {
+		sd_err("creating a snapshot of hypervolume is not supported");
+		return EXIT_FAILURE;
+	}
+
 	ret = dog_write_object(vid_to_vdi_oid(vid), 0,
 			       vdi_cmd_data.snapshot_tag,
 			       SD_MAX_VDI_TAG_LEN,
-- 
1.8.3.2




More information about the sheepdog mailing list