Openvz / CentOS 7 – Network Manager can break networking

If you are getting errors like


[root@us network-scripts]# ifup venet0
Error: no device found for connection ‘System venet0’.
[root@us network-scripts]# ifup venet0:0
Error: no device found for connection ‘System venet0:0’.


On a centos7 and openvz machine, stop network manager.


[root@us network-scripts]# service NetworkManager stop
Redirecting to /bin/systemctl stop NetworkManager.service
[root@us network-scripts]# chkconfig NetworkManager off
Note: Forwarding request to ‘systemctl disable NetworkManager.service’.
rm ‘/etc/systemd/system/dbus-org.freedesktop.nm-dispatcher.service’
rm ‘/etc/systemd/system/’
rm ‘/etc/systemd/system/dbus-org.freedesktop.NetworkManager.service’
[root@us network-scripts]# /etc/init.d/network restart
Restarting network (via systemctl):
[ OK ]