Merge "Add grab version func"
diff --git "a/tcp_tests/environment/environment_template/\173\043 roles \043\175/openstack_database" "b/tcp_tests/environment/environment_template/\173\043 roles \043\175/openstack_database"
index 5bc6aee..3c3c87f 100644
--- "a/tcp_tests/environment/environment_template/\173\043 roles \043\175/openstack_database"
+++ "b/tcp_tests/environment/environment_template/\173\043 roles \043\175/openstack_database"
@@ -7,6 +7,7 @@
           classes:
 #}
           - cluster.${_param:cluster_name}.openstack.database
+          - service.galera.slave.cluster
 {{- set_param('keepalived_vip_interface', 'br_ctl') }}
 {{- register_metaparam('mysql_cluster_role', 'openstack_database') }}
 {{- register_metaparam('keepalived_vip_priority', 'openstack_database') }}
diff --git "a/tcp_tests/environment/environment_template/\173\043 roles \043\175/openstack_database_leader" "b/tcp_tests/environment/environment_template/\173\043 roles \043\175/openstack_database_leader"
index 1f855fe..c8e2112 100644
--- "a/tcp_tests/environment/environment_template/\173\043 roles \043\175/openstack_database_leader"
+++ "b/tcp_tests/environment/environment_template/\173\043 roles \043\175/openstack_database_leader"
@@ -7,4 +7,5 @@
           classes:
 #}
           {%- include ("{# roles #}/" + 'openstack_database') %}
-          - cluster.${_param:cluster_name}.openstack.database_init
\ No newline at end of file
+          - cluster.${_param:cluster_name}.openstack.database_init
+          - service.galera.master.cluster
\ No newline at end of file
diff --git a/tcp_tests/templates/cookied-mcp-ocata-dop-sl2/common-services.yaml b/tcp_tests/templates/cookied-mcp-ocata-dop-sl2/common-services.yaml
index ea2997a..cf66773 100644
--- a/tcp_tests/templates/cookied-mcp-ocata-dop-sl2/common-services.yaml
+++ b/tcp_tests/templates/cookied-mcp-ocata-dop-sl2/common-services.yaml
@@ -1,5 +1,11 @@
 {% from 'cookied-mcp-ocata-dop-sl2/underlay.yaml' import HOSTNAME_CFG01 with context %}
 
+- description: Refresh grains
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' state.sls salt.minion.grains
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 15}
+  skip_fail: false
+
 # Install support services
 - description: Install keepalived on ctl01
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False
diff --git a/tcp_tests/templates/cookied-mcp-ocata-dvr-vxlan/common-services.yaml b/tcp_tests/templates/cookied-mcp-ocata-dvr-vxlan/common-services.yaml
index 1deca4b..b2d0751 100644
--- a/tcp_tests/templates/cookied-mcp-ocata-dvr-vxlan/common-services.yaml
+++ b/tcp_tests/templates/cookied-mcp-ocata-dvr-vxlan/common-services.yaml
@@ -1,5 +1,11 @@
 {% from 'cookied-mcp-ocata-dvr-vxlan/underlay.yaml' import HOSTNAME_CFG01 with context %}
 
+- description: Refresh grains
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' state.sls salt.minion.grains
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 15}
+  skip_fail: false
+
 # Install support services
 - description: Install keepalived on ctl01
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False
diff --git a/tcp_tests/templates/physical_mcp11_ovs_dpdk/common-services.yaml b/tcp_tests/templates/physical_mcp11_ovs_dpdk/common-services.yaml
index 1728329..bbbd2f5 100644
--- a/tcp_tests/templates/physical_mcp11_ovs_dpdk/common-services.yaml
+++ b/tcp_tests/templates/physical_mcp11_ovs_dpdk/common-services.yaml
@@ -1,5 +1,11 @@
 {% from 'physical_mcp11_ovs_dpdk/underlay.yaml' import HOSTNAME_CFG01 with context %}
 
+- description: Refresh grains
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' state.sls salt.minion.grains
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 15}
+  skip_fail: false
+
 # Install support services
 - description: Install keepalived on ctl01
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False