In step 1, we write the XML definition for the new network interface. We specify bridge as the type, an IP address for the interface, and optionally a MAC address.
In steps 2 and 3, we define the new bridge interface and list it. Defining an interface does not automatically make it active, so we activate it in step 4.
Activating the bridge creates the actual interface on the host, as shown in step 5.
In step 6, we confirm that the IP and MAC address assigned to the bridge are indeed what we specified in step 1.
In steps 7 and 8, we obtain both the name and MAC address using the virsh utility and finally, in step 9, we remove the bridge interface.