virsh: new command "domifannounce"

virsh domifannounce is a thin wrapper around the new API
virDomainAnnounceInterface(). Syntax:

     virsh domifannounce guestname [interfacename] [parameters]

where the optional interfacename can be either the MAC address of the
interface to announce, or the name of the tap device used to connect
the domain's interface to the real network (if the connection is with
a tap device), and [parameters] is one or more of the following options:

  --initial [unsigned integer]
  --max     [unsigned integer]
  --rounds  [unsigned integer]
  --step    [unsigned integer]

For example:

    virsh domifannounce myguest 52:54:00:BE:EF:E1 --initial 100
    virsh domifannounce other vnet2
    virsh domifannounce myguest

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Martin Kletzander <mkletzan@redhat.com>
This commit is contained in:
Laine Stump
2026-06-08 02:33:43 -04:00
parent 7191d29326
commit f0c89a8aa9
2 changed files with 129 additions and 0 deletions
+41
View File
@@ -2328,6 +2328,47 @@ exclusive. If no flag is specified, behavior is different depending
on hypervisor.
domifannounce
-------------
**Syntax**
::
domifannounce domain [interface-device] [parameters]
Request that a domain inject "gratuitous" ARP responses into the
outbound data stream of a specific network interface of the domain (or
if no interface-device is given, inject ARP responses on the outbound
data stream of all interfaces of the domain). This can be helpful to
re-sync network switches in the broadcast domain of said interfaces
when the network topology has changed. This is usually done
automatically when a domain is started, or after it has migrated (for
example, that is the behavior of QEMU), but a more complicated setup
where the topology changes around an already active domain (or
possibly all the plumbing isn't yet connected and passing traffic at
the time the automatic announcement takes place) might benefit from a
manually triggered announce.
The optional parameters are:
- *--initial n*
initial delay before first announcement (milliseconds) default: 50
- *--max n*
maximum delay between announcements (milliseconds) default: 550
- *--rounds n*
total number of announcements default: 5
- *--step n*
increment added to delay (milliseconds) after each announcement default 50
dominfo
-------