Add Network Interface To KVM Guest
Use the steps below to add a network interface to your guest.
A good use-case for this is if you are setting up a NAT/gateway on a guest, who will need the normal public interface to the outside world, and another network interface for the internal private LAN that the other guests are connected to.
GUEST_ID="my-guest-name" NETWORK_NAME="privatenet" TYPE="network" virsh attach-interface \ --domain $GUEST_ID \ --type $TYPE \ --source $NETWORK_NAME \ --model virtio \ --config \ --live
First published: 19th July 2021