Remove references to any product 72/672/1
authorJanne Suominen <janne.suominen@nokia.com>
Fri, 10 May 2019 07:32:37 +0000 (10:32 +0300)
committerJanne Suominen <janne.suominen@nokia.com>
Fri, 10 May 2019 07:33:55 +0000 (10:33 +0300)
Remove references to any particular product.

Change-Id: Ic74a87d1fd29a18fe7cde61c76d61b07c8a8705f
Signed-off-by: Janne Suominen <janne.suominen@nokia.com>
roles/allocate_cpu_cores/defaults/main.yml
roles/allocate_cpu_cores/tasks/main.yml
roles/allocate_cpu_cores/tasks/make_cpu_sets.yaml
roles/allocate_cpu_cores/templates/cloud_cpu_allocation.fact.j2 [new file with mode: 0644]
roles/allocate_cpu_cores/templates/ncir_cpu_allocation.fact.j2 [deleted file]
roles/change_kernel_cmdline/tasks/main.yml
roles/logging/tasks/main.yml
roles/logging/tasks/restart_centralized_instance.yml [deleted file]
roles/performance_nodes/tasks/ovsdpdk.yaml
roles/performance_nodes_post/tasks/nova.yaml

index 00d0741..0a43c76 100644 (file)
@@ -13,7 +13,7 @@
 # limitations under the License.
 
 # Number of platform CPUs to allocate per service by default.
-ncir_default_platform_cpus:
+cloud_default_platform_cpus:
   default:
     controller:
       own: 1
@@ -53,7 +53,7 @@ caas_service_profiles:
   - caas_master
   - caas_worker
 
-allocation_fact_file: "/etc/ansible/facts.d/ncir_cpu_allocation.fact"
+allocation_fact_file: "/etc/ansible/facts.d/cloud_cpu_allocation.fact"
 
 cpu_set_mapping:
   ovs_dpdk:
index cca66d8..b1c835f 100644 (file)
 
 - name: Prepare.
   set_fact:
-    ncir_cpu_remain: []
-    ncir_cpu_sets: {}
+    cloud_cpu_remain: []
+    cloud_cpu_sets: {}
 
 - name: Get CPU topology.
   get_cpu_topology:
-    var: ncir_cpu_topology
+    var: cloud_cpu_topology
 - debug:
-    var: ncir_cpu_topology
+    var: cloud_cpu_topology
 
 - name: Make default performance profile.
   set_fact:
     perf_profile: {
-      platform_cpus: "{{ ncir_cpu_topology | cpu_topology_defaults(hosts[hostname]['service_profiles'], ncir_default_platform_cpus, virtual_env, hosts | length < 2) }}"
+      platform_cpus: "{{ cloud_cpu_topology | cpu_topology_defaults(hosts[hostname]['service_profiles'], cloud_default_platform_cpus, virtual_env, hosts | length < 2) }}"
     }
 - debug:
     var: perf_profile
   loop_control:
     loop_var: cpu_set
   with_items:
-    - { 'name': 'vm', 'request': "{{ ncir_cpu_topology | get_cpu_count_by_percent(vm_share_percent) }}", 'where': 'tail' }
+    - { 'name': 'vm', 'request': "{{ cloud_cpu_topology | get_cpu_count_by_percent(vm_share_percent) }}", 'where': 'tail' }
   when:
     - "'compute' in hosts[hostname]['service_profiles']"
 
 - name: Calculate CaaS CPU counts
   set_fact:
-    perf_profile: "{{ perf_profile | combine({ item.key: ncir_cpu_topology | get_cpu_count_by_percent(item.value) }) }}"
+    perf_profile: "{{ perf_profile | combine({ item.key: cloud_cpu_topology | get_cpu_count_by_percent(item.value) }) }}"
   with_dict: "{{ perf_profile['caas_cpu_pools'] | default({}) }}"
   when: hosts[hostname]['service_profiles'] | intersect(caas_service_profiles)
 
 
 - name: Make set of remaining CPUs.
   set_fact:
-    ncir_cpu_remain: "{{ ncir_cpu_remain | union(item) }}"
-  with_items: "{{ ncir_cpu_topology.values() }}"
+    cloud_cpu_remain: "{{ cloud_cpu_remain | union(item) }}"
+  with_items: "{{ cloud_cpu_topology.values() }}"
 - debug:
-    var: ncir_cpu_remain
+    var: cloud_cpu_remain
 
 - name: Allocate remaining CPUs to platform.
   set_fact:
-    ncir_cpu_sets: "{{ ncir_cpu_sets | combine({ 'platform': ncir_cpu_sets['platform'] | default([]) | union(ncir_cpu_remain) }) }}"
-    ncir_cpu_remain: []
-  when: "ncir_cpu_remain | length > 0"
+    cloud_cpu_sets: "{{ cloud_cpu_sets | combine({ 'platform': cloud_cpu_sets['platform'] | default([]) | union(cloud_cpu_remain) }) }}"
+    cloud_cpu_remain: []
+  when: "cloud_cpu_remain | length > 0"
 
 - debug:
-    var: ncir_cpu_sets
+    var: cloud_cpu_sets
 
 - name: Make sure facts directory exists.
   file:
 
 - name: Save CPU allocation.
   template:
-    src: ncir_cpu_allocation.fact.j2
+    src: cloud_cpu_allocation.fact.j2
     dest: "{{ allocation_fact_file }}"
   register: cpu_allocation
 
index 4bb3816..a128fe7 100644 (file)
@@ -7,21 +7,21 @@
 
 - name: Allocate CPU set.
   set_fact:
-    allocated_cpu_set: "{{ ncir_cpu_topology | cpu_topology_alloc(cpu_request, cpu_set.where) }}"
+    allocated_cpu_set: "{{ cloud_cpu_topology | cpu_topology_alloc(cpu_request, cpu_set.where) }}"
 
 - name: Append allocated CPU set.
   set_fact:
-    combined_cpu_set: "{{ allocated_cpu_set | union(ncir_cpu_sets[cpu_set.name] | default([])) | sort }}"
+    combined_cpu_set: "{{ allocated_cpu_set | union(cloud_cpu_sets[cpu_set.name] | default([])) | sort }}"
 
 - name: Make CPU set.
   set_fact:
-    ncir_cpu_sets: "{{ ncir_cpu_sets | combine({ cpu_set.name: combined_cpu_set }) }}"
-    ncir_cpu_topology: "{{ ncir_cpu_topology | cpu_topology_trim(cpu_request, cpu_set.where) }}"
+    cloud_cpu_sets: "{{ cloud_cpu_sets | combine({ cpu_set.name: combined_cpu_set }) }}"
+    cloud_cpu_topology: "{{ cloud_cpu_topology | cpu_topology_trim(cpu_request, cpu_set.where) }}"
 
 - name: Show created CPU sets.
   debug:
-    var: ncir_cpu_sets
+    var: cloud_cpu_sets
 
 - name: Show CPU topology after sets creation.
   debug:
-    var: ncir_cpu_topology
+    var: cloud_cpu_topology
diff --git a/roles/allocate_cpu_cores/templates/cloud_cpu_allocation.fact.j2 b/roles/allocate_cpu_cores/templates/cloud_cpu_allocation.fact.j2
new file mode 100644 (file)
index 0000000..e7074ef
--- /dev/null
@@ -0,0 +1,9 @@
+{# Copyright (C) 2018 Nokia #}
+{
+{% for s in cloud_cpu_sets %}
+    "{{ s }}": {
+        "set" : {{ cloud_cpu_sets[s] | sort }},
+        "list": "{{ cloud_cpu_sets[s] | set_to_cpulist }}"
+    }{{ "," if not loop.last else "" }}
+{% endfor %}
+}
diff --git a/roles/allocate_cpu_cores/templates/ncir_cpu_allocation.fact.j2 b/roles/allocate_cpu_cores/templates/ncir_cpu_allocation.fact.j2
deleted file mode 100644 (file)
index ab31352..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-{# Copyright (C) 2018 Nokia #}
-{
-{% for s in ncir_cpu_sets %}
-    "{{ s }}": {
-        "set" : {{ ncir_cpu_sets[s] | sort }},
-        "list": "{{ ncir_cpu_sets[s] | set_to_cpulist }}"
-    }{{ "," if not loop.last else "" }}
-{% endfor %}
-}
index a514f16..63e8f40 100644 (file)
@@ -18,7 +18,7 @@
 - name: Get configuration.
   set_fact:
     perf_profile: "{{ performance_profiles[hosts[hostname]['performance_profiles'][0]] if 'performance_profiles' in hosts[hostname] else {} }}"
-    cpu_alloc: "{{ ansible_local.ncir_cpu_allocation | default([]) }}"
+    cpu_alloc: "{{ ansible_local.cloud_cpu_allocation | default([]) }}"
 - debug:
     var: perf_profile
 - debug:
index c57be00..1015def 100644 (file)
@@ -16,6 +16,3 @@
   tags:
       - generate_log_forwarding_config
 
-- include: restart_centralized_instance.yml
-  tags:
-      - restart_centralized_instance
diff --git a/roles/logging/tasks/restart_centralized_instance.yml b/roles/logging/tasks/restart_centralized_instance.yml
deleted file mode 100644 (file)
index ae29d0e..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-# Copyright 2019 Nokia
-
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-- name: Restart the centralized rsyslogd to activate updated configuration
-  shell: /usr/local/bin/hascli -r -o /rsyslog-master
-  ignore_errors: yes
index a72e76f..ae43c56 100644 (file)
@@ -16,8 +16,8 @@
 
 - debug:
     msg:
-      - "DPDK cores {{ ansible_local.ncir_cpu_allocation['ovs_dpdk']['list'] }}"
-      - "Platform cores {{ ansible_local.ncir_cpu_allocation['platform']['list'] }}"
+      - "DPDK cores {{ ansible_local.cloud_cpu_allocation['ovs_dpdk']['list'] }}"
+      - "Platform cores {{ ansible_local.cloud_cpu_allocation['platform']['list'] }}"
       - "Host VPUs  {{ansible_processor_vcpus}}, Processor cores {{ansible_processor_cores}}"
       - "Threads per core {{ansible_processor_threads_per_core}}, Sockets {{ansible_processor_count}}"
 
@@ -42,7 +42,7 @@
   script: >
       configure_ovsdpdk.py --cores {{ansible_processor_vcpus}} --pcore {{ansible_processor_cores}}
       --tcore {{ansible_processor_threads_per_core}} --sockets {{ansible_processor_count}}
-      --dpdkcores {{ ansible_local.ncir_cpu_allocation['ovs_dpdk']['list'] }}
+      --dpdkcores {{ ansible_local.cloud_cpu_allocation['ovs_dpdk']['list'] }}
   register: result
   changed_when: result.rc == 0
   failed_when: result.rc == 2
index e94bfcf..00258c1 100644 (file)
@@ -15,7 +15,7 @@
 # limitations under the License.
 
 - name: Set vcpu_pin_set
-  ini_file: dest=/etc/nova/nova.conf section=DEFAULT option=vcpu_pin_set value={{ ansible_local.ncir_cpu_allocation['vm']['list'] }} backup=no
+  ini_file: dest=/etc/nova/nova.conf section=DEFAULT option=vcpu_pin_set value={{ ansible_local.cloud_cpu_allocation['vm']['list'] }} backup=no
   register: nova1_result
 
 - name: Get performance profile configuration