[Solved] KVM Failed to Startup Error: error: Network not found: no network with matching name ‘default‘

An error was reported when starting the KVM virtual machine on the command line: startup failed, and the default network could not be found

[root@localhost ~]# virsh start centos7.0
error: Failed to start domain centos7.0
error: Network not found: no network with matching name 'default'

However, there was a default network before, and an error was reported when it was restarted after a night. First, find the path of default.xml,

[root@localhost ~]# find/-name "default.xml"
/run/libvirt/storage/default.xml
/etc/libvirt/storage/default.xml
/etc/libvirt/storage/autostart/default.xml
/usr/share/backgrounds/default.xml
/usr/share/libvirt/networks/default.xml

It can be seen that there are many xml files. Select those related to network and libvirt for execution

[root@localhost ~]# virsh net-define /usr/share/libvirt/networks/default.xml
Network default defined from /usr/share/libvirt/networks/default.xml

[root@localhost ~]# virsh net-start default
Network default started

Start successfully, check:

[root@localhost ~]# virsh net-list
 Name                 State      Autostart     Persistent
----------------------------------------------------------
 default              active     no            yes

Finally, just start the KVM virtual machine:

[root@localhost ~]# virsh start centos7.0
Domain centos7.0 started

The graphical interface has also been viewed successfully:

Read More: