summaryrefslogtreecommitdiffstats
path: root/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests
diff options
context:
space:
mode:
Diffstat (limited to 'fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests')
-rwxr-xr-xfuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/build_ovs_dpdk.pp8
-rwxr-xr-xfuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/clone.pp21
-rwxr-xr-xfuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/install_ovs_dpdk.pp204
-rwxr-xr-xfuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/params.pp1
-rwxr-xr-xfuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/postinstall_ovs_dpdk.pp164
-rwxr-xr-xfuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/uninstall_ovs.pp45
6 files changed, 326 insertions, 117 deletions
diff --git a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/build_ovs_dpdk.pp b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/build_ovs_dpdk.pp
index ad0b712..3ee686b 100755
--- a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/build_ovs_dpdk.pp
+++ b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/build_ovs_dpdk.pp
@@ -8,13 +8,13 @@ class ovsdpdk::build_ovs_dpdk (
require ovsdpdk::uninstall_ovs
file {"${plugin_dir}/files/build_ovs_dpdk.sh":
- content => template("${plugin_dir}/files/build_ovs_dpdk.erb"),
- mode => '0775',
+ content => template("${plugin_dir}/files/build_ovs_dpdk.erb"),
+ mode => '0775',
}
exec {"${plugin_dir}/files/build_ovs_dpdk.sh":
- require => File["${plugin_dir}/files/build_ovs_dpdk.sh"],
- timeout => 0,
+ require => File["${plugin_dir}/files/build_ovs_dpdk.sh"],
+ timeout => 0,
}
}
diff --git a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/clone.pp b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/clone.pp
index 255de0e..218964c 100755
--- a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/clone.pp
+++ b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/clone.pp
@@ -29,16 +29,37 @@ class ovsdpdk::clone(
exec { "wget dpdk":
command => "rm -rf dpdk.tgz $ovs_dpdk_dir && wget http://$master_ip:8080/plugins/fuel-plugin-ovsnfv-0.0/repositories/ubuntu/dpdk.tgz && tar xf dpdk.tgz && mv dpdk $ovs_dpdk_dir",
path => "/usr/bin:/usr/sbin:/bin:/sbin",
+ require => File[$dest],
}
exec { "wget ovs":
command => "rm -rf ovs.tgz $ovs_dir && wget http://$master_ip:8080/plugins/fuel-plugin-ovsnfv-0.0/repositories/ubuntu/ovs.tgz && tar xf ovs.tgz && mv ovs $ovs_dir",
path => "/usr/bin:/usr/sbin:/bin:/sbin",
+ require => File[$dest],
}
exec { "wget networking_ovs_dpdk":
command => "rm -rf networking-ovs-dpdk.tgz $networking_ovs_dpdk_dir && wget http://$master_ip:8080/plugins/fuel-plugin-ovsnfv-0.0/repositories/ubuntu/networking-ovs-dpdk.tgz && tar xf networking-ovs-dpdk.tgz && mv networking-ovs-dpdk $networking_ovs_dpdk_dir",
path => "/usr/bin:/usr/sbin:/bin:/sbin",
+ require => File[$dest],
+ }
+
+ exec { "wget qemu":
+ command => "rm -rf qemu-2.2.1.tar.bz2 /opt/code/qemu && wget http://$master_ip:8080/plugins/fuel-plugin-ovsnfv-0.0/repositories/ubuntu/qemu-2.2.1.tar.bz2 && tar xf qemu-2.2.1.tar.bz2 && mv qemu-2.2.1 /opt/code/qemu",
+ path => "/usr/bin:/usr/sbin:/bin:/sbin",
+ require => File[$dest],
+ }
+
+ exec { "wget libvirt":
+ command => "rm -rf libvirt-1.2.12.tar.gz /opt/code/libvirt && wget http://$master_ip:8080/plugins/fuel-plugin-ovsnfv-0.0/repositories/ubuntu/libvirt-1.2.12.tar.gz && tar xf libvirt-1.2.12.tar.gz && mv libvirt-1.2.12 /opt/code/libvirt",
+ path => "/usr/bin:/usr/sbin:/bin:/sbin",
+ require => File[$dest],
+ }
+
+ exec { "wget libvirt-python":
+ command => "rm -rf libvirt-python-1.2.12.tar.gz /opt/code/libvirt-python && wget http://$master_ip:8080/plugins/fuel-plugin-ovsnfv-0.0/repositories/ubuntu/libvirt-python-1.2.12.tar.gz && tar xf libvirt-python-1.2.12.tar.gz && mv libvirt-python-1.2.12 /opt/code/libvirt-python",
+ path => "/usr/bin:/usr/sbin:/bin:/sbin",
+ require => File[$dest],
}
exec { "install pbr":
diff --git a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/install_ovs_dpdk.pp b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/install_ovs_dpdk.pp
index 2b446de..d049077 100755
--- a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/install_ovs_dpdk.pp
+++ b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/install_ovs_dpdk.pp
@@ -7,6 +7,7 @@
class ovsdpdk::install_ovs_dpdk (
$networking_ovs_dpdk_dir = $::ovsdpdk::params::networking_ovs_dpdk_dir,
$plugin_dir = $::ovsdpdk::params::plugin_dir,
+ $ovs_dir = $::ovsdpdk::params::ovs_dir,
$openvswitch_service_file = $::ovsdpdk::params::openvswitch_service_file,
$openvswitch_service_path = $::ovsdpdk::params::openvswitch_service_path,
$qemu_kvm = $::ovsdpdk::params::qemu_kvm,
@@ -14,56 +15,171 @@ class ovsdpdk::install_ovs_dpdk (
require ovsdpdk::build_ovs_dpdk
if $compute == 'True' {
- exec {'create_ovs_dpdk':
- command => "mv /etc/init.d/openvswitch-switch /tmp/openvswitch-switch.bak;cp ${networking_ovs_dpdk_dir}/devstack/ovs-dpdk/ovs-dpdk-init /etc/init.d/openvswitch-switch;chmod +x /etc/init.d/openvswitch-switch; ln -sf /etc/init.d/openvswitch-switch /etc/init.d/ovs-dpdk; cp /etc/openvswitch/conf.db /etc/openvswitch/conf.db.pre_dpdk",
- user => root,
- path => ['/usr/bin','/bin'],
- }
-
- file {'/etc/default/ovs-dpdk': content => template("${plugin_dir}/files/ovs-dpdk-conf.erb"), mode => '0644' }
-
- exec {'adapt_conf_file':
- command => "${plugin_dir}/files/tune_params.sh",
- user => root,
- require => File['/etc/default/ovs-dpdk'],
- }
-
-# exec { 'update ovs service':
-# command => "cp ${plugin_dir}/files/${openvswitch_service_file} ${openvswitch_service_path}/${openvswitch_service_file}",
-# path => ['/usr/bin','/bin'],
-# user => root,
-# onlyif => "test -f ${openvswitch_service_path}/${openvswitch_service_file}",
-# }
-
- if $::operatingsystem == 'CentOS' {
- exec { 'systemctl daemon-reload':
- path => ['/usr/bin','/bin','/usr/sbin'],
- user => root,
- require => Exec['update ovs service'],
- }
- }
-
- package {'qemu-kvm': ensure => installed }
-
- exec { "cp ${qemu_kvm} ${qemu_kvm}.orig":
- path => ['/usr/bin','/bin'],
- user => root,
- onlyif => "test -f ${qemu_kvm}",
- require => Package['qemu-kvm'],
- }
-
- exec { "cp ${plugin_dir}/files/kvm-wrapper.sh ${qemu_kvm};chmod +x ${qemu_kvm}":
- path => ['/usr/bin','/bin'],
- user => root,
- onlyif => "test -f ${qemu_kvm}",
- require => [ Exec["cp ${qemu_kvm} ${qemu_kvm}.orig"], Package['qemu-kvm'] ],
- }
+ exec {'create_ovs_dpdk':
+ command => "mv /etc/init.d/openvswitch-switch /tmp/openvswitch-switch.bak;cp ${networking_ovs_dpdk_dir}/devstack/ovs-dpdk/ovs-dpdk-init /etc/init.d/openvswitch-switch;chmod +x /etc/init.d/openvswitch-switch; ln -sf /etc/init.d/openvswitch-switch /etc/init.d/ovs-dpdk; cp /etc/openvswitch/conf.db /etc/openvswitch/conf.db.pre_dpdk",
+ user => root,
+ path => ['/usr/bin','/bin'],
+ }
+ file {'/etc/default/ovs-dpdk': content => template("${plugin_dir}/files/ovs-dpdk-conf.erb"), mode => '0644' }
+
+ exec {'adapt_conf_file':
+ command => "${plugin_dir}/files/tune_params.sh",
+ user => root,
+ require => File['/etc/default/ovs-dpdk'],
+ }
+
+# exec { 'update ovs service':
+# command => "cp ${plugin_dir}/files/${openvswitch_service_file} ${openvswitch_service_path}/${openvswitch_service_file}",
+# path => ['/usr/bin','/bin'],
+# user => root,
+# onlyif => "test -f ${openvswitch_service_path}/${openvswitch_service_file}",
+# }
+
+# if $::operatingsystem == 'CentOS' {
+# exec { 'systemctl daemon-reload':
+# path => ['/usr/bin','/bin','/usr/sbin'],
+# user => root,
+# require => Exec['update ovs service'],
+# }
+# }
+
+ package { 'zlib1g-dev':
+ ensure => installed,
+ }
+
+ package { 'libglib2.0-dev':
+ ensure => installed,
+ }
+
+ package { 'libxml2-dev':
+ ensure => installed,
+ }
+
+ package { 'libdevmapper-dev':
+ ensure => installed,
+ }
+
+ package { 'libpciaccess-dev':
+ ensure => installed,
+ }
+
+ package { 'libnl-dev':
+ ensure => installed,
+ }
+
+ package { 'pkg-config':
+ ensure => installed,
+ }
+
+ package { 'bison':
+ ensure => installed,
+ }
+
+ package { 'flex':
+ ensure => installed,
+ }
+
+ package { 'libyajl2':
+ ensure => installed,
+ }
+
+ package { 'libyajl-dev':
+ ensure => installed,
+ }
+
+ package { 'bc':
+ ensure => installed,
+ }
+
+ package { 'python-dev':
+ ensure => installed,
+ }
+
+ package { 'numactl':
+ ensure => installed,
+ }
+
+ package { 'libdbus-1-dev':
+ ensure => installed,
+ }
+
+ package { 'libnuma1':
+ ensure => installed,
+ }
+
+ package { 'libnuma-dev':
+ ensure => installed,
+ }
+
+ package { 'libgnutls26':
+ ensure => installed,
+ }
+
+ package { 'libgnutls-dev':
+ ensure => installed,
+ }
+
+ exec {'build qemu':
+ command => "true && cd /opt/code/qemu && ./configure --enable-kvm --target-list=x86_64-softmmu && make && make install",
+ user => root,
+ path => ['/usr/bin','/bin'],
+ require => [ Package['flex'], Package['bison'], Package['pkg-config'], Package['libnl-dev'], Package['libpciaccess-dev'], Package['libdevmapper-dev'], Package['libxml2-dev'], Package['libglib2.0-dev'], Package['zlib1g-dev'], Package['numactl'], Package['python-dev'],Package['libdbus-1-dev'],Package['bc'],Package['libnuma1'], Package['libnuma-dev'] , Package['libgnutls26'], Package['libgnutls-dev']],
+ timeout => 0,
+ }
+
+ exec {'build libvirt':
+ command => "true && cd /opt/code/libvirt && ./configure --prefix=/usr --with-dbus && make && make install",
+ user => root,
+ path => ['/usr/bin','/bin'],
+ require => [Exec['build qemu'], Package['libyajl2'], Package['libyajl-dev']],
+ timeout => 0,
+ }
+
+ exec {'build libvirt-python':
+ command => "true && cd /opt/code/libvirt-python && python setup.py build && python setup.py install",
+ user => root,
+ path => ['/usr/bin','/bin'],
+ require => Exec['build libvirt'],
+ timeout => 0,
+ }
+
+ exec { "cp ${qemu_kvm} ${qemu_kvm}.orig":
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => "test -f ${qemu_kvm}",
+ require => Exec['build qemu'],
+ }
+
+ exec { "cp ${plugin_dir}/files/kvm-wrapper.sh ${qemu_kvm};chmod +x ${qemu_kvm}":
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => "test -f ${qemu_kvm}",
+ require => [ Exec["cp ${qemu_kvm} ${qemu_kvm}.orig"], Exec['build qemu'] ],
+ }
+
+ exec { 'ln -sf /etc/init.d/libvirtd /etc/init.d/libvirt-bin':
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => 'test -f /etc/init.d/libvirtd',
+ }
#exec {'init ovs-dpdk':
#command => '/etc/init.d/ovs-dpdk init',
#user => root,
#require => [ Exec['create_ovs_dpdk'], File['/etc/default/ovs-dpdk'] ],
#}
+ exec { "ovsdb-tool convert /etc/openvswitch/conf.db ${ovs_dir}/vswitchd/vswitch.ovsschema":
+ path => ['/usr/bin','/bin'],
+ user => root,
+ }
+
+ exec { 'patch linux_net':
+ command => "cp ${plugin_dir}/files/linux_net.py /usr/lib/python2.7/dist-packages/nova/network/linux_net.py",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => 'test -f /usr/lib/python2.7/dist-packages/nova/network/linux_net.py',
+ }
+
}
# install mech driver
diff --git a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/params.pp b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/params.pp
index 3d7bdfa..ae55bec 100755
--- a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/params.pp
+++ b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/params.pp
@@ -41,6 +41,7 @@ class ovsdpdk::params {
$nova_conf_dir = '/etc/nova'
$nova_conf = "${nova_conf_dir}/nova.conf"
$ml2_ovs_conf = '/etc/neutron/plugins/ml2/openvswitch_agent.ini'
+ $ml2_conf = '/etc/neutron/plugins/ml2/ml2_conf.ini'
$neutron_l3_conf = '/etc/neutron/l3_agent.ini'
# OVS config
diff --git a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/postinstall_ovs_dpdk.pp b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/postinstall_ovs_dpdk.pp
index 4a23a89..a3fd60f 100755
--- a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/postinstall_ovs_dpdk.pp
+++ b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/postinstall_ovs_dpdk.pp
@@ -6,6 +6,7 @@ class ovsdpdk::postinstall_ovs_dpdk (
$plugin_dir = $::ovsdpdk::params::plugin_dir,
$nova_conf = $::ovsdpdk::params::nova_conf,
$openvswitch_service_name = $::ovsdpdk::params::openvswitch_service_name,
+ $ml2_conf = $::ovsdpdk::params::ml2_conf,
$ml2_ovs_conf = $::ovsdpdk::params::ml2_ovs_conf,
$neutron_l3_conf = $::ovsdpdk::params::neutron_l3_conf,
$openvswitch_agent = $::ovsdpdk::params::openvswitch_agent,
@@ -16,59 +17,132 @@ class ovsdpdk::postinstall_ovs_dpdk (
package {'crudini': ensure => installed }
if $compute == 'True' {
- # adapt configuration files
- exec {'adapt_nova_conf':
- command => "${plugin_dir}/files/set_vcpu_pin.sh ${nova_conf}",
- path => ['/usr/bin','/bin'],
- user => root,
- onlyif => "test -f ${nova_conf}",
- require => Package['crudini'],
- }
-
- exec {'adapt_ml2_conf':
- command => "sudo crudini --set ${ml2_ovs_conf} ovs datapath_type ${ovs_datapath_type}",
- path => ['/usr/bin','/bin'],
- user => root,
- onlyif => "test -f ${ml2_ovs_conf}",
- require => Package['crudini'],
- }
-
- exec {'adapt_neutron_l3':
- command => "sudo crudini --set ${neutron_l3_conf} DEFAULT external_network_bridge br-ex",
- path => ['/usr/bin','/bin'],
- user => root,
- onlyif => "test -f ${neutron_l3_conf}",
- require => Package['crudini'],
- }
-
-
- service {"${openvswitch_service_name}": ensure => 'running' }
-
- # restart OVS to synchronize ovsdb-server with ovs-vswitchd needed
- # due to several new --no-wait entries
- exec {'restart_ovs':
- command => "/usr/sbin/service ${openvswitch_service_name} restart",
- user => root,
- require => Service["${openvswitch_service_name}"],
- }
-
- exec { "${plugin_dir}/files/configure_bridges.sh ${ovs_datapath_type}":
- user => root,
- require => Exec['restart_ovs'],
- }
+ # adapt configuration files
+ exec {'adapt_nova_conf':
+ command => "${plugin_dir}/files/set_vcpu_pin.sh ${nova_conf}",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => "test -f ${nova_conf}",
+ require => Package['crudini'],
+ }
+
+ exec {'adapt_ml2_conf_datapath':
+ command => "sudo crudini --set ${ml2_ovs_conf} ovs datapath_type ${ovs_datapath_type}",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => "test -f ${ml2_ovs_conf}",
+ require => Package['crudini'],
+ }
+
+ exec {'adapt_neutron_l3':
+ command => "sudo crudini --set ${neutron_l3_conf} DEFAULT external_network_bridge br-ex",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => "test -f ${neutron_l3_conf}",
+ require => Package['crudini'],
+ }
+
+
+ service {"${openvswitch_service_name}": ensure => 'running' }
+
+ # restart OVS to synchronize ovsdb-server with ovs-vswitchd needed
+ # due to several new --no-wait entries
+ exec {'restart_ovs':
+ command => "/usr/sbin/service ${openvswitch_service_name} restart",
+ user => root,
+ require => Service["${openvswitch_service_name}"],
+ }
+
+ exec { "${plugin_dir}/files/configure_bridges.sh ${ovs_datapath_type}":
+ user => root,
+ require => Exec['restart_ovs'],
+ }
+
+ service { 'libvirtd': ensure => running }
+
+ exec {'libvirtd_disable_tls':
+ command => "sudo crudini --set /etc/libvirt/libvirtd.conf '' listen_tls 0",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ require => Package['crudini'],
+ notify => Service['libvirtd'],
+ }
+
+ exec {'restart_nova_compute':
+ command => "/usr/sbin/service nova-compute restart",
+ user => root,
+ require => [ Exec['libvirtd_disable_tls'], Service['libvirtd'] ],
+ }
+ }
+
+ exec {'adapt_ml2_conf_mechanism_driver':
+ command => "sudo crudini --set ${ml2_conf} ml2 mechanism_drivers ovsdpdk",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => "test -f ${ml2_conf}",
+ require => Package['crudini'],
+ }
+
+ exec {'adapt_ml2_conf_security_group':
+ command => "sudo crudini --set ${ml2_conf} securitygroup firewall_driver neutron.agent.firewall.NoopFirewallDriver",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => "test -f ${ml2_conf}",
+ require => Package['crudini'],
}
if $controller == 'True' {
service {'neutron-server':
- ensure => 'running',
+ ensure => 'running',
+ }
+
+ exec {'append_NUMATopologyFilter':
+ command => "sudo crudini --set ${nova_conf} DEFAULT scheduler_default_filters RetryFilter,AvailabilityZoneFilter,RamFilter,CoreFilter,DiskFilter,ComputeFilter,ComputeCapabilitiesFilter,ImagePropertiesFilter,ServerGroupAntiAffinityFilter,ServerGroupAffinityFilter,NUMATopologyFilter",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ onlyif => "test -f ${nova_conf}",
+ require => Package['crudini'],
+ }
+
+ exec { 'remove_old_agent':
+ command => "${plugin_dir}/files/remove_agent.sh $adminrc_user $adminrc_password $adminrc_tenant $adminrc_hostname",
+ user => 'root',
+ logoutput => 'true',
+ timeout => 0,
+ require => [ Service['neutron-server'], Exec['append_NUMATopologyFilter'] ],
+ }
+
+ exec {'restart_neutron_server':
+ command => "/usr/sbin/service neutron-server restart",
+ user => root,
+ require => Exec['remove_old_agent'],
}
+
+ exec {'restart_nova_scheduler':
+ command => "/usr/sbin/service nova-scheduler restart",
+ user => root,
+ require => Exec['remove_old_agent'],
+ }
+
}
if $compute == 'True' {
- service {"${openvswitch_agent}":
- ensure => 'running',
- require => [ Exec['restart_ovs'], Service["${openvswitch_service_name}"] ],
- }
+ exec { 'patch_ovs_agent':
+ command => "cp ${plugin_dir}/files/neutron-plugin-openvswitch-agent.conf /etc/init/neutron-plugin-openvswitch-agent.conf",
+ path => ['/usr/bin','/bin'],
+ user => root,
+ }
+
+ service {"${openvswitch_agent}":
+ ensure => 'running',
+ require => [ Exec['restart_ovs'], Service["${openvswitch_service_name}"], Exec['patch_ovs_agent'] ],
+ }
+
+ exec { "ovs-vsctl --no-wait set Open_vSwitch . other_config:pmd-cpu-mask=${ovs_pmd_core_mask}":
+ path => ['/usr/bin','/bin'],
+ user => root,
+ require => Service["${openvswitch_agent}"],
+ }
}
}
diff --git a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/uninstall_ovs.pp b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/uninstall_ovs.pp
index 97afdd7..7c7a23d 100755
--- a/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/uninstall_ovs.pp
+++ b/fuel-plugin-ovsnfv/deployment_scripts/puppet/modules/ovsdpdk/manifests/uninstall_ovs.pp
@@ -6,41 +6,38 @@ class ovsdpdk::uninstall_ovs (
$openvswitch_service_name = $::ovsdpdk::params::openvswitch_service_name,
$openvswitch_agent = $::ovsdpdk::params::openvswitch_agent,
$install_packages = $::ovsdpdk::params::install_packages,
- $openvswitch_agent = $::ovsdpdk::params::openvswitch_agent,
) inherits ovsdpdk {
- #Due to dependencies to other packages, we won't purge vanilla OVS
+ #Due to dependencies to other packages, we won't purge vanilla OVS
#package { $remove_packages: ensure => 'purged' }
if $compute == 'True' {
- exec { "/usr/sbin/service ${openvswitch_service_name} stop":
- user => root,
- }
-
-# This is required for Liberty
-# exec { "/usr/sbin/service ${openvswitch_agent} stop":
-# user => root,
-# path => "/usr/bin:/bin",
-# }
+ exec { "/usr/sbin/service ${openvswitch_service_name} stop":
+ user => root,
+ path => ["/usr/bin", "/bin", "/sbin"],
+ }
+
+ exec { "/usr/sbin/service ${openvswitch_agent} stop":
+ user => root,
+ path => ["/usr/bin", "/bin", "/sbin"],
+ }
+
+ exec { '/sbin/modprobe -r openvswitch':
+ onlyif => "/bin/grep -q '^openvswitch' '/proc/modules'",
+ user => root,
+ require => Exec["/usr/sbin/service ${openvswitch_service_name} stop"],
+ }
}
if $controller == 'True' {
- exec { '/usr/sbin/service neutron-server stop':
- user => root,
- path => "/usr/bin:/bin",
- onlyif => "ps aux | grep -vws grep | grep -ws neutron-server"
- }
+ exec { '/usr/sbin/service neutron-server stop':
+ user => root,
+ path => ["/usr/bin", "/bin", "/sbin"],
+ onlyif => "ps aux | grep -vws grep | grep -ws neutron-server",
+ }
}
package { $install_packages: ensure => 'installed' }
- if $compute == 'True' {
- exec { '/sbin/modprobe -r openvswitch':
- onlyif => "/bin/grep -q '^openvswitch' '/proc/modules'",
- user => root,
-# require => Exec["/usr/sbin/service ${openvswitch_agent} stop"],
- }
- }
-
}