What is the interface virbr0 for and how do I disable it? – Red Hat Customer Portal

What is the interface virbr0 for and how do I disable it? – Red Hat Customer Portal

環境

  • Red Hat Enterprise Linux 7
  • Red Hat Enterprise Linux 6
  • Red Hat Enterprise Linux 5
  • Virtualization (libvirt)

解決策

The virbr0 bridge interface is created by libvirtd’s default network configuration. libvirtd is the service which provides a basis for the host to act as a hypervisor.

One could prevent libvirtd’s default network from being activated on boot, or you could prevent libvirtd itself from activating on boot. The former will prevent any VM guest attached to libvirtd’s default network from having network connectivity and the latter would prevent VMs from running at all.

  • To immediately stop libvirtd’s default network (this will not persist across reboots):
# virsh net-destroy default  
  • To permanently disable the libvirtd default network from being created at boot:
# virsh net-autostart default --disable  
  • To permanently remove the libvirtd default network:
# virsh net-undefine default  
  • To permanently disable the libvirtd service from starting at boot on RHEL5 and RHEL6:
# chkconfig libvirtd off  
  • To permanently disable the libvirtd service from starting at boot on RHEL7:
# systemctl disable libvirtd.service