Skip to content

Commit

Permalink
Cleanup SR-IOV and vhost0 configurations
Browse files Browse the repository at this point in the history
Change-Id: I60ecd3850ee3b3434ca7b5fbe7f632a13f1a08db
Closes-bug: #1576680
  • Loading branch information
semihalf-berestovskyy-andriy committed Apr 29, 2016
1 parent 6c12462 commit 599b7d4
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions fabfile/tasks/uninstall.py
Expand Up @@ -324,6 +324,16 @@ def uninstall_only_vrouter_node(manage_nova_compute='yes', *args):
pkgs.append('ceilometer-agent-compute')
apt_uninstall(pkgs)
sudo("sed -i 's/inet manual/inet dhcp/g' /etc/network/interfaces")
# Delete vhost0 interface
sudo("""sed -ri.bak '
/^auto vhost0/ d
/^iface vhost0/,/^(\w|$)/ {
/iface vhost0/ d
/^\s/ d
}
' /etc/network/interfaces""")
# Remove SR-IOV configuration
sudo("sed -i.bak '/sriov_numvfs/ d' /etc/rc.local")
else:
pkgs = get_pkg_list()
yum_uninstall(pkgs)
Expand Down

0 comments on commit 599b7d4

Please sign in to comment.