Enable periodic task to discover cell hosts when ironic is used
authorDmitry Tantsur <divius.inside@gmail.com>
Tue, 13 Jun 2017 16:05:33 +0000 (18:05 +0200)
committerDmitry Tantsur <divius.inside@gmail.com>
Fri, 23 Jun 2017 16:13:52 +0000 (18:13 +0200)
Starting with the Ocata release, bare metal nodes are no longer get recognized
by nova automatically. To avoid forcing users into running nova manage command
each time they enroll a node, we will have to allow enable the periodic task
to do so.

Change-Id: I8b0afac54dc9bd51dbe2ae4f237e4de50459be0f
Closes-Bug: #1697724

environments/services/ironic.yaml
puppet/services/nova-scheduler.yaml
releasenotes/notes/baremetal-cell-hosts-cd5cf5aa8a33643c.yaml [new file with mode: 0644]

index 8359f4a..b81b026 100644 (file)
@@ -2,3 +2,5 @@ resource_registry:
   OS::TripleO::Services::IronicApi: ../../puppet/services/ironic-api.yaml
   OS::TripleO::Services::IronicConductor: ../../puppet/services/ironic-conductor.yaml
   OS::TripleO::Services::NovaIronic: ../../puppet/services/nova-ironic.yaml
+parameter_defaults:
+  NovaSchedulerDiscoverHostsInCellsInterval: 15
index 5da6d43..72a1fce 100644 (file)
@@ -45,6 +45,14 @@ parameters:
     default:
       tag: openstack.nova.scheduler
       path: /var/log/nova/nova-scheduler.log
+  NovaSchedulerDiscoverHostsInCellsInterval:
+    type: number
+    default: -1
+    description: >
+      This value controls how often (in seconds) the scheduler should
+      attempt to discover new hosts that have been added to cells.
+      The default value of -1 disables the periodic task completely.
+      It is recommended to set this parameter for deployments using Ironic.
 
 resources:
   NovaBase:
@@ -71,6 +79,7 @@ outputs:
           - nova::ram_allocation_ratio: '1.0'
             nova::scheduler::filter::scheduler_available_filters: {get_param: NovaSchedulerAvailableFilters}
             nova::scheduler::filter::scheduler_default_filters: {get_param: NovaSchedulerDefaultFilters}
+            nova::scheduler::discover_hosts_in_cells_interval: {get_param: NovaSchedulerDiscoverHostsInCellsInterval}
       step_config: |
         include tripleo::profile::base::nova::scheduler
       upgrade_tasks:
diff --git a/releasenotes/notes/baremetal-cell-hosts-cd5cf5aa8a33643c.yaml b/releasenotes/notes/baremetal-cell-hosts-cd5cf5aa8a33643c.yaml
new file mode 100644 (file)
index 0000000..98ba86d
--- /dev/null
@@ -0,0 +1,6 @@
+---
+fixes:
+  - |
+    When ``environments/services/ironic.yaml`` is used, enable periodic task
+    in nova-scheduler to automatically discover new nodes. Otherwise a user
+    has to run nova management command on controllers each time.