Fix modules for mk22-qa-lab01

- Load missing modules after upgrade kernel to 4.4 on Ubuntu14.04
- Move workaround for cassandra memory consumption to the proper file
- Actualize the salt steps according to the upstream scripts
- switch to the master branch for the mk-lab-salt-models
diff --git a/README.md b/README.md
index 02d240d..d9684e9 100644
--- a/README.md
+++ b/README.md
@@ -37,26 +37,6 @@
 export ENV_NAME=tcpcloud-mk22  # You can set any env name
 ```
 
-Run deploy test for mk22-lab-basic
-----------------------------------
-```
-export LAB_CONFIG_NAME=mk22-lab-basic  # Name of set of templates
-
-LC_ALL=en_US.UTF-8  py.test -vvv -s -k test_tcp_install_default
-```
-, or as an alternative there is another test that use deploy scripts from models repository written on bash [2]:
-```
-LC_ALL=en_US.UTF-8  py.test -vvv -s -k test_tcp_install_with_scripts
-```
-
-Run deploy test for mk22-lab-avdanced
--------------------------------------
-```
-export LAB_CONFIG_NAME=mk22-lab-advanced  # Name of set of templates
-
-LC_ALL=en_US.UTF-8  py.test -vvv -s -k test_tcp_install_default
-```
-
 Run deploy test for mk22-qa-lab01
 ---------------------------------
 Note: This lab is not finished yet. TBD: configure vsrx node
@@ -66,6 +46,12 @@
 
 LC_ALL=en_US.UTF-8  py.test -vvv -s -k test_tcp_install_default
 ```
+, or as an alternative there is another test that use deploy scripts from models repository written on bash [2]:
+```
+LC_ALL=en_US.UTF-8  py.test -vvv -s -k test_tcp_install_with_scripts
+```
+
+Labs with names mk22-lab-basic and mk22-lab-avdanced are deprecated and not recommended to use.
 
 
 Create and start the env for manual tests
diff --git a/tcp_tests/templates/common-services/mk22-qa-lab01-common-services.yaml b/tcp_tests/templates/common-services/mk22-qa-lab01-common-services.yaml
index d3980d1..96d38d6 100644
--- a/tcp_tests/templates/common-services/mk22-qa-lab01-common-services.yaml
+++ b/tcp_tests/templates/common-services/mk22-qa-lab01-common-services.yaml
@@ -1,129 +1,110 @@
 # Install support services
-- description: Install keepalived on primary controller
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' state.sls
-    keepalived
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: true
-- description: Install keepalived on other controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    keepalived -b 1
+
+- description: Install keepalived
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keepalived:cluster' state.sls keepalived -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 10, delay: 10}
   skip_fail: true
+
 - description: Check the VIP
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' cmd.run
-    'ip a | grep 172.16.10.254' | grep -B1 172.16.10.254
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
-
-- description: Install keepalived on primary database server
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs01*' state.sls
-    keepalived
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: true
-- description: Install keepalived on other database servers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs*' state.sls
-    keepalived -b 1
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 10, delay: 10}
-  skip_fail: true
-- description: Check the database VIP
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs*' cmd.run
-    'ip a | grep 172.16.10.252' | grep -B1 172.16.10.252
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keepalived:cluster' cmd.run 'ip a | grep 172.16.10.2' | grep -B1 172.16.10.2
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
 
 
-- description: Install glusterfs on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    glusterfs.server.service
+- description: Install glusterfs
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@glusterfs:server' state.sls glusterfs.server.service
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Setup glusterfs on primary controller
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' state.sls
-    glusterfs.server.setup
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@glusterfs:server' state.sls glusterfs.server.setup -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Setup glusterfs on other controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    glusterfs.server.setup -b 1
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
+
 - description: Check the gluster status
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
-    'gluster peer status; gluster volume status'
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@glusterfs:server' cmd.run 'gluster peer status; gluster volume status' -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install RabbitMQ on all database servers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs*' state.sls
-    rabbitmq
+
+
+- description: Install RabbitMQ
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@rabbitmq:server' state.sls rabbitmq
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Check the rabbitmq status
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs*' cmd.run
-    'rabbitmqctl cluster_status'
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@rabbitmq:server' cmd.run 'rabbitmqctl cluster_status'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
+
 - description: '*Workaround* Update salt-formula-galera on config node to the latest
     version'
   cmd: apt-get -y --force-yes install salt-formula-galera
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install Galera on first dbs01 server
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs01*' state.sls
-    galera
+
+- description: Install Galera on first server
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@galera:master' state.sls galera
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install Galera on other dbs* servers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs*' state.sls
-    galera
+
+- description: Install Galera on other servers
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@galera:slave' state.sls galera
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Check mysql status
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' mysql.status | grep -A1 wsrep_incoming_addresses
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@galera:*' mysql.status | grep -A1 -e "wsrep_incoming_addresses\|wsrep_cluster_size"
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: true
-- description: Install haproxy on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    haproxy
+
+
+- description: Install haproxy
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@haproxy:proxy' state.sls haproxy
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Check haproxy status on controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' service.status
-    haproxy
+
+- description: Check haproxy status
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@haproxy:proxy' service.status haproxy
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install haproxy on all database servers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs*' state.sls
-    haproxy
+
+- description: Restart rsyslog
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@haproxy:proxy' service.restart rsyslog
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Check haproxy status on database servers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'dbs*' service.status
-    haproxy
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
+
 - description: Install memcached on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    memcached
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@memcached:server' state.sls memcached
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
diff --git a/tcp_tests/templates/openstack/mk22-qa-lab01-openstack.yaml b/tcp_tests/templates/openstack/mk22-qa-lab01-openstack.yaml
index 5959d37..d2ac096 100644
--- a/tcp_tests/templates/openstack/mk22-qa-lab01-openstack.yaml
+++ b/tcp_tests/templates/openstack/mk22-qa-lab01-openstack.yaml
@@ -1,167 +1,182 @@
 # Install OpenStack control services
-- description: Install keystone on primary controller
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' state.sls
-    keystone
+
+- description: Install keystone service
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' state.sls keystone.server -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install keystone on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    keystone -b 1
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
+
 - description: Populate keystone services/tenants/admins
-  cmd: salt-call --hard-crash --state-output=mixed --state-verbose=False state.sls
-    keystone.client
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:client' state.sls keystone.client
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Check keystone service-list
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
-    '. /root/keystonerc; keystone service-list'
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' cmd.run '. /root/keystonerc; keystone service-list'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install glance on primary controller
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' state.sls
-    glance
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
+
+
 - description: Install glance on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    glance -b 1
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+     -C 'I@glance:server' state.sls glance -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Configure glusterfs.client on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    glusterfs.client
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@glance:server' state.sls glusterfs.client
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Configure(re-install) keystone on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    keystone -b 1
+
+- description: Update fernet tokens for keystone server
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' state.sls keystone.server -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Check glance image-list
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
-    '. /root/keystonerc; glance image-list'
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' cmd.run '. /root/keystonerc; glance image-list'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install cinder on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    cinder -b 1
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
-- description: Check cinder list
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
-    '. /root/keystonerc; cinder list'
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
-- description: Install nova on ctl01
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' state.sls
-    nova
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
+
+
 - description: Install nova on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    nova
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@nova:controller' state.sls nova -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Check nova service-list
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
-    '. /root/keystonerc; nova service-list'
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' cmd.run '. /root/keystonerc; nova service-list'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install neutron on ctl01
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' state.sls
-    neutron
+
+
+- description: Install cinder
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@cinder:controller' state.sls cinder -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install neutron on all controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    neutron
+
+- description: Check cinder list
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' cmd.run '. /root/keystonerc; cinder list'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
+
+- description: Install neutron service
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@neutron:server' state.sls neutron -b 1
+  node_name: cfg01.mk22-qa-lab01.local
+  retry: {count: 3, delay: 5}
+  skip_fail: false
+
 - description: Check neutron agent-list
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
-    '. /root/keystonerc; neutron agent-list'
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' cmd.run '. /root/keystonerc; neutron agent-list'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Deploy dashboard on prx*
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'prx*' state.apply
+
+
+- description: Install heat service
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@heat:server' state.sls heat -b 1
+  node_name: cfg01.mk22-qa-lab01.local
+  retry: {count: 3, delay: 5}
+  skip_fail: false
+
+- description: Check heat service
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' cmd.run '. /root/keystonerc; heat resource-type-list'
+  node_name: cfg01.mk22-qa-lab01.local
+  retry: {count: 3, delay: 5}
+  skip_fail: false
+
+
+- description: Deploy horizon dashboard
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@horizon:server' state.sls horizon
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: true
+
 - description: Deploy nginx proxy
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cfg*' state.sls
-    nginx
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@nginx:server' state.sls nginx
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: true
 
+
 # Install contrail on controllers
 
-- description: Workaround of the bug https://mirantis.jira.com/browse/PROD-8164 for opencontrail.database
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' grains.set noservices True
+- description: Install contrail database on controllers
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@opencontrail:database' state.sls opencontrail.database -b 1
+  #cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+  #    'ctl*' state.sls opencontrail.database -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
 
-- description: Install contrail database on controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    opencontrail.database -b 1
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
 - description: Check cassandra status on ctl01
-  cmd: salt 'ctl01*' cmd.run 'nodetool status;nodetool compactionstats;nodetool describecluster;'
+  cmd: salt -C 'I@opencontrail:database'
+    cmd.run 'nodetool status;nodetool compactionstats;nodetool describecluster;' -b 1
+  #cmd: salt 'ctl*'
+  #    cmd.run 'nodetool status;nodetool compactionstats;nodetool describecluster;' -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Install opencontrail on controllers
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' state.sls
-    opencontrail -b 1
+
+- description: Install opencontrail control services
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@opencontrail:control' state.sls opencontrail -b 1
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
-- description: Check contrail status
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
-    '. /root/keystonerc; contrail-status; neutron net-list; nova net-list'
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
+
+
 - description: Add contrail bgp router on ctl01
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@opencontrail:control:id:1' cmd.run
     '/usr/share/contrail-utils/provision_control.py --oper add --api_server_ip 172.16.10.254
     --api_server_port 8082 --host_name ctl01 --host_ip 172.16.10.101 --router_asn
     64512 --admin_user admin --admin_password workshop --admin_tenant_name admin'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Add contrail bgp router on ctl02
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl02*' cmd.run
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@opencontrail:control:id:1' cmd.run
     '/usr/share/contrail-utils/provision_control.py --oper add --api_server_ip 172.16.10.254
     --api_server_port 8082 --host_name ctl02 --host_ip 172.16.10.102 --router_asn
     64512 --admin_user admin --admin_password workshop --admin_tenant_name admin'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Add contrail bgp router on ctl03
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl03*' cmd.run
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@opencontrail:control:id:1' cmd.run
     '/usr/share/contrail-utils/provision_control.py --oper add --api_server_ip 172.16.10.254
     --api_server_port 8082 --host_name ctl03 --host_ip 172.16.10.103 --router_asn
     64512 --admin_user admin --admin_password workshop --admin_tenant_name admin'
@@ -169,48 +184,59 @@
   retry: {count: 3, delay: 5}
   skip_fail: false
 
-
-# Install compute node
-
-- description: Workaround of the bug https://mirantis.jira.com/browse/PROD-8164 for opencontrail on compute nodes
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' grains.set noservices True
+- description: Check contrail status
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@opencontrail:control' cmd.run 'contrail-status'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
+- description: Test neutron and nova with contrail
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@keystone:server' cmd.run '. /root/keystonerc; neutron net-list; nova net-list'
+  node_name: cfg01.mk22-qa-lab01.local
+  retry: {count: 3, delay: 5}
+  skip_fail: false
+
+
+# Install compute node
+
 - description: Apply formulas for compute node
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' state.apply
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: true
-- description: Workaround of the bug https://mirantis.jira.com/browse/PROD-8164 for opencontrail on compute nodes
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' grains.set noservices True
-  node_name: cfg01.mk22-qa-lab01.local
-  retry: {count: 3, delay: 5}
-  skip_fail: false
+
 - description: Re-apply(as in doc) formulas for compute node
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' state.apply
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: true
+
 - description: Add vrouter for cmp01
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl01*' cmd.run
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@opencontrail:control:id:1' cmd.run
     '/usr/share/contrail-utils/provision_vrouter.py --oper add --host_name cmp01 --host_ip
     172.16.10.105 --api_server_ip 172.16.10.254 --api_server_port 8082 --admin_user
     admin --admin_password workshop --admin_tenant_name admin'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Reboot compute nodes
-  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' system.reboot
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' system.reboot;
+    sleep 30
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
+
 - description: Check IP on computes
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' cmd.run
     'ip a'
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 10, delay: 30}
   skip_fail: false
+
 - description: Check contrail status on computes
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' cmd.run
     'contrail-status'
diff --git a/tcp_tests/templates/salt/mk22-qa-lab01-salt.yaml b/tcp_tests/templates/salt/mk22-qa-lab01-salt.yaml
index aba8288..e4fb62d 100644
--- a/tcp_tests/templates/salt/mk22-qa-lab01-salt.yaml
+++ b/tcp_tests/templates/salt/mk22-qa-lab01-salt.yaml
@@ -1,4 +1,5 @@
 # Install salt to the config node
+
 - description: Configure tcpcloud repository on the cfg01 node
   cmd: echo 'deb [arch=amd64] http://apt.tcpcloud.eu/nightly/ xenial main security tcp tcp-salt' > /etc/apt/sources.list;
     echo 'deb [arch=amd64] http://apt.tcpcloud.eu/nightly/ trusty tcp-salt' >> /etc/apt/sources.list;
@@ -72,7 +73,9 @@
 
 - description: Clone reclass models and perform a workaround for https://mirantis.jira.com/browse/PROD-8078
   cmd: |
-    git clone https://github.com/Mirantis/mk-lab-salt-model.git /srv/salt/reclass -b dash;
+    git clone https://github.com/Mirantis/mk-lab-salt-model.git /srv/salt/reclass;
+    cd /srv/salt/reclass;
+    git checkout master;
     cat << 'EOF' >> /srv/salt/reclass/nodes/control/cfg01.mk22-qa-lab01.local.yml
     # local storage
       reclass:
@@ -126,7 +129,7 @@
 
 - description: Workaround set low max_heap_size for Cassandra
   cmd: |
-    cat << 'EOF' >> /srv/salt/reclass/classes/system/linux/system/single.yml
+    cat << 'EOF' >> /srv/salt/reclass/classes/system/opencontrail/control/cluster.yml
     # opencontrail lowmem
       opencontrail:
         database:
@@ -137,32 +140,34 @@
   retry: {count: 1, delay: 1}
   skip_fail: false
 
-
 # Prepare salt services and nodes settings
 - description: Run 'linux' formula on cfg01
-  cmd: salt-call --hard-crash --state-output=mixed --state-verbose=False state.sls
-    linux
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@salt:master' state.sls linux
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
 
 - description: Run 'openssh' formula on cfg01
-  cmd: salt-call --hard-crash --state-output=mixed --state-verbose=False state.sls
-    openssh;sed -i 's/PasswordAuthentication no/PasswordAuthentication yes/' /etc/ssh/sshd_config
-    && service ssh restart
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@salt:master' state.sls openssh;
+    salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@salt:master' cmd.run "sed -i 's/PasswordAuthentication no/PasswordAuthentication
+    yes/' /etc/ssh/sshd_config && service ssh restart"
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
 
 - description: '*Workaround* of the bug https://mirantis.jira.com/browse/PROD-7962'
-  cmd: echo '    StrictHostKeyChecking no' >> /root/.ssh/config
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    '*' cmd.run "echo '    StrictHostKeyChecking no' >> /root/.ssh/config"
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 1, delay: 1}
   skip_fail: false
 
 - description: Run 'salt' formula on cfg01
-  cmd: salt-call --hard-crash --state-output=mixed --state-verbose=False  state.sls
-    salt
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@salt:master' state.sls salt.master
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: true
@@ -174,8 +179,8 @@
   skip_fail: false
 
 - description: Generate inventory for all the nodes to the /srv/salt/reclass/nodes/_generated
-  cmd: salt-call --hard-crash --state-output=mixed --state-verbose=False state.sls
-    reclass.storage
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False
+    -C 'I@salt:master' state.sls reclass
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 3, delay: 5}
   skip_fail: false
@@ -186,15 +191,34 @@
   retry: {count: 3, delay: 5}
   skip_fail: false
 
+- description: Sync all salt resources
+  cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' saltutil.sync_all
+  node_name: cfg01.mk22-qa-lab01.local
+  retry: {count: 3, delay: 5}
+  skip_fail: false
+
+
 # Bootstrap all nodes
-- description: Configure linux on controllers
+- description: Workaround for missing kernel modules
+  cmd: salt '*' cmd.run "for module in nf_conntrack_ipv4 ip_tables
+    x_tables nf_defrag_ipv4 nf_nat_ipv4 nf_nat
+    iptable_filter iptable_mangle iptable_nat;
+    do
+    modprobe \$module;
+    echo \$module >> /etc/modules;
+    done"
+  node_name: cfg01.mk22-qa-lab01.local
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Configure linux on all nodes
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' state.sls
     linux
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 5, delay: 5}
   skip_fail: false
 
-- description: Configure openssh on controllers
+- description: Configure openssh on all nodes
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False -C '* and not
     cfg*' state.sls openssh;salt --hard-crash --state-output=mixed --state-verbose=False
     -C '* and not cfg*' cmd.run "sed -i 's/PasswordAuthentication no/PasswordAuthentication
@@ -224,13 +248,6 @@
   retry: {count: 3, delay: 5}
   skip_fail: false
 
-#- description: '*Workaround* of the bug https://mirantis.jira.com/browse/PROD-8063'
-#  cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' cmd.run 'dhclient
-#    -r;dhclient'
-#  node_name: cfg01.mk22-qa-lab01.local
-#  retry: {count: 1, delay: 1}
-#  skip_fail: false
-
 - description: Configure salt.minion on controllers
   cmd: salt --hard-crash --state-output=mixed --state-verbose=False '*' state.sls
     salt.minion
@@ -244,3 +261,4 @@
   node_name: cfg01.mk22-qa-lab01.local
   retry: {count: 5, delay: 10}
   skip_fail: false
+