diff --git a/doc/source/configuring.rst b/doc/source/configuring.rst index 3f09e9860f..5984929f6c 100644 --- a/doc/source/configuring.rst +++ b/doc/source/configuring.rst @@ -1079,6 +1079,38 @@ Can only be specified in configuration files. Datastore name associated with the ``vmware_datacenter_path`` +* ``vmware_datastores`` + +Optional. Default: Not set. + +This option can only be specified in configuration file and is specific +to the VMware storage backend. + +vmware_datastores allows administrators to configure multiple datastores to +save glance image in the VMware store backend. The required format for the +option is: ::. + +where datacenter_path is the inventory path to the datacenter where the +datastore is located. An optional weight can be given to specify the priority. + +Example:: + + vmware_datastores = datacenter1:datastore1 + vmware_datastores = dc_folder/datacenter2:datastore2:100 + vmware_datastores = datacenter1:datastore3:200 + +**NOTE**: + + - This option can be specified multiple times to specify multiple datastores. + - Either vmware_datastore_name or vmware_datastores option must be specified + in glance-api.conf + - Datastore with weight 200 has precedence over datastore with weight 100. + - If no weight is specified, default weight '0' is associated with it. + - If two datastores have same weight, the datastore with maximum free space + will be chosen to store the image. + - If the datacenter path or datastore name contains a colon (:) symbol, it + must be escaped with a backslash. + * ``vmware_api_retry_count=TIMES`` Optional. Default: ``10`` diff --git a/etc/glance-api.conf b/etc/glance-api.conf index 71738ed1f2..eeb6a381df 100644 --- a/etc/glance-api.conf +++ b/etc/glance-api.conf @@ -770,11 +770,27 @@ sheepdog_store_chunk_size = 64 # Inventory path to a datacenter (string value) # Value optional when vmware_server_ip is an ESX/ESXi host: if specified # should be `ha-datacenter`. +# Deprecated in favor of vmware_datastores. #vmware_datacenter_path = # Datastore associated with the datacenter (string value) +# Deprecated in favor of vmware_datastores. #vmware_datastore_name = +# A list of datastores where the image can be stored. +# This option may be specified multiple times for specifying multiple +# datastores. Either one of vmware_datastore_name or vmware_datastores is +# required. The datastore name should be specified after its datacenter +# path, seperated by ":". An optional weight may be given after the datastore +# name, seperated again by ":". Thus, the required format becomes +# ::. +# When adding an image, the datastore with highest weight will be selected, +# unless there is not enough free space available in cases where the image size +# is already known. If no weight is given, it is assumed to be zero and the +# directory will be considered for selection last. If multiple datastores have +# the same weight, then the one with the most free space available is selected. +#vmware_datastores = + # The number of times we retry on failures # e.g., socket error, etc (integer value) #vmware_api_retry_count = 10