From 82b9033e83c565ebbe08bc490997dc3acff00d77 Mon Sep 17 00:00:00 2001 From: "kirby@puppetlabs.com" Date: Mon, 6 Nov 2017 11:12:15 -0800 Subject: [PATCH] Document parameters added in vmpooler.yaml.example This change documents new vshpere specific parameters introduced related to host selection and folder creation. Without this change these paremeters are not documented. --- lib/vmpooler/providers/vsphere.rb | 3 +-- vmpooler.yaml.example | 25 ++++++++++++++++++++++++- 2 files changed, 25 insertions(+), 3 deletions(-) diff --git a/lib/vmpooler/providers/vsphere.rb b/lib/vmpooler/providers/vsphere.rb index 880af8b..8f0632e 100644 --- a/lib/vmpooler/providers/vsphere.rb +++ b/lib/vmpooler/providers/vsphere.rb @@ -92,7 +92,6 @@ module Vmpooler else select_target_hosts(target, cluster, datacenter) end - logger.log('s', "Provider_hosts is: #{@provider_hosts[dc]}") end def wait_for_host_selection(dc, target, maxloop = 0, loop_delay = 5, max_age = 60) @@ -608,7 +607,7 @@ module Vmpooler # the host is in maintenance mode # the host status is not 'green' # the cpu or memory utilization is bigger than the limit param - def get_host_utilization(host, model = nil, limit = 80) + def get_host_utilization(host, model = nil, limit = 90) limit = @config[:config]['utilization_limit'] if @config[:config].key?('utilization_limit') if model return nil unless host_has_cpu_model?(host, model) diff --git a/vmpooler.yaml.example b/vmpooler.yaml.example index 2560568..ad7eb61 100644 --- a/vmpooler.yaml.example +++ b/vmpooler.yaml.example @@ -419,7 +419,30 @@ # of 2.0 means each time the pool is checked and nothing important happens, the loop delay is multiplied by 2.0, # for example, the first time is 2 seconds, then 4, 8, 16 etc. until it reaches check_loop_delay_max. # This value must be greater than 1.0. - +# +# - manage_host_selection (Only affects vSphere Provider) +# Allow host selection to be determined by vmpooler +# Hosts are selected based on current CPU utilization and cycled between when there are multiple targets +# The hosts tracking list is refreshed on an interval when a host is requested determined by host_selection_max_age +# (optional; default: false) +# +# - create_folders (Only affects vSphere Provider) +# Create the pool folder specified in the pool configuration +# Note: this will only create the last folder when it does not exist. It will not create any parent folders +# (optional; default: false) +# +# - host_selection_max_age (Only affects vSphere Provider) +# The maximum age of the provider_hosts list in seconds +# The list is repopulated when the difference between now and the last time +# checking of host utilization finished is greater than the value set. +# (optional; default: 60) +# +# - utilization_limit (Only affects vSphere Provider) +# The maximum utilization of host resources allowed before the host +# is excluded from consideration for VM deployment +# The value represents a percentage and applies to both memory and CPU +# (optional; default: 90) +# # Example: :config: