From 2d31a9411501467bc647d77fa13eaf6e6ca60411 Mon Sep 17 00:00:00 2001 From: "Ruben S. Montero" Date: Wed, 15 Feb 2012 23:53:35 +0100 Subject: [PATCH] feature #1112: Configuration parameters for the System Datastore --- share/etc/oned.conf | 15 ++++++++++++++- src/nebula/NebulaTemplate.cc | 8 ++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/share/etc/oned.conf b/share/etc/oned.conf index e89cf46340..431b641fe1 100644 --- a/share/etc/oned.conf +++ b/share/etc/oned.conf @@ -84,8 +84,15 @@ NETWORK_SIZE = 254 MAC_PREFIX = "02:00" #******************************************************************************* -# Image Repository Configuration +# DataStore Configuration #******************************************************************************* +# SYSTEM_DS +# base_path : Base path for the system datastore. The system datastore +# keeps the images (or reference to) of running or stopped VMs. +# The images are stored in the form base_path/. +# type : SSH: non shared, will limit live_migration +# SHARED: needs to be exported and mounted in the hosts +# # DEFAULT_IMAGE_TYPE: This can take values # OS Image file holding an operating system # CDROM Image file holding a CDROM @@ -97,6 +104,12 @@ MAC_PREFIX = "02:00" # xvd XEN Virtual Disk # vd KVM virtual disk #******************************************************************************* + +SYSTEM_DS = [ + base_path = "/var/lib/one/system_ds", + type = "shared" +] + DEFAULT_IMAGE_TYPE = "OS" DEFAULT_DEVICE_PREFIX = "hd" diff --git a/src/nebula/NebulaTemplate.cc b/src/nebula/NebulaTemplate.cc index 4113db6921..7d76ddf089 100644 --- a/src/nebula/NebulaTemplate.cc +++ b/src/nebula/NebulaTemplate.cc @@ -186,6 +186,14 @@ void OpenNebulaTemplate::set_conf_default() # DEFAULT_DEVICE_PREFIX #******************************************************************************* */ + //SYSTEM_DS + vvalue.clear(); + vvalue.insert(make_pair("BASE_PATH","/var/lib/one/system_ds")); + vvalue.insert(make_pair("TYPE","shared")); + + vattribute = new VectorAttribute("SYSTEM_DS",vvalue); + conf_default.insert(make_pair(attribute->name(),vattribute)); + //DEFAULT_IMAGE_TYPE value = "OS";