public inbox for kdevops@lists.linux.dev
 help / color / mirror / Atom feed
From: Luis Chamberlain <mcgrof@kernel.org>
To: kdevops@lists.linux.dev
Cc: Luis Chamberlain <mcgrof@kernel.org>
Subject: [PATCH 6/8] guestfs: remove explicit tap0 device name
Date: Thu,  7 Mar 2024 16:03:57 -0800	[thread overview]
Message-ID: <20240308000400.1646823-7-mcgrof@kernel.org> (raw)
In-Reply-To: <20240308000400.1646823-1-mcgrof@kernel.org>

If you create more than one guest each guest will have the same tap0
device name, and when you try to start the second guest it will fail
due to the clash. We can avoid this by just not specifying the target
host name and letting libvirt figure it out. This does mean a slight
functional change in that the host will get something like vnet+1 id
instead of tap0. This fixes getting networking when using multiple
guests as when testing with fstests against a filesystem.

Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>
---
 playbooks/roles/gen_nodes/templates/guestfs_q35.j2.xml  | 1 -
 playbooks/roles/gen_nodes/templates/guestfs_virt.j2.xml | 1 -
 2 files changed, 2 deletions(-)

diff --git a/playbooks/roles/gen_nodes/templates/guestfs_q35.j2.xml b/playbooks/roles/gen_nodes/templates/guestfs_q35.j2.xml
index ce160490..9af98313 100644
--- a/playbooks/roles/gen_nodes/templates/guestfs_q35.j2.xml
+++ b/playbooks/roles/gen_nodes/templates/guestfs_q35.j2.xml
@@ -136,7 +136,6 @@
     </controller>
     <interface type='bridge'>
       <source bridge='{{ libvirt_session_public_network_dev }}'/>
-      <target dev='tap0'/>
       <model type='virtio'/>
       <alias name='net0'/>
       <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
diff --git a/playbooks/roles/gen_nodes/templates/guestfs_virt.j2.xml b/playbooks/roles/gen_nodes/templates/guestfs_virt.j2.xml
index 29dc0951..ee669a0b 100644
--- a/playbooks/roles/gen_nodes/templates/guestfs_virt.j2.xml
+++ b/playbooks/roles/gen_nodes/templates/guestfs_virt.j2.xml
@@ -128,7 +128,6 @@
     </controller>
     <interface type='bridge'>
       <source bridge='{{ libvirt_session_public_network_dev }}'/>
-      <target dev='tap0'/>
       <model type='virtio'/>
       <alias name='net0'/>
       <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-- 
2.43.0


  parent reply	other threads:[~2024-03-08  0:04 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-08  0:03 [PATCH 0/8] guestfs: fixes and enhancements Luis Chamberlain
2024-03-08  0:03 ` [PATCH 1/8] guestfs: use macros for drives for aarch64 Luis Chamberlain
2024-03-08  0:03 ` [PATCH 2/8] bringup: disable ZNS and CXL for guestfs Luis Chamberlain
2024-03-08  0:03 ` [PATCH 3/8] libvirt: move zns, largio and cxl to its own files Luis Chamberlain
2024-03-08  0:03 ` [PATCH 4/8] guestfs: move options to its own file Luis Chamberlain
2024-03-08  0:03 ` [PATCH 5/8] bringup: match default distro to user's distro Luis Chamberlain
2024-03-08  0:03 ` Luis Chamberlain [this message]
2024-03-08  0:03 ` [PATCH 7/8] destroy_guestfs.sh: remove known ssh key Luis Chamberlain
2024-03-08  0:03 ` [PATCH 8/8] guestfs: verify new line on ssh include directive Luis Chamberlain
2024-03-08  9:55 ` [PATCH 0/8] guestfs: fixes and enhancements Luis Chamberlain
2024-03-08 14:14   ` Chuck Lever III
2024-03-08 14:26     ` Chuck Lever III
2024-03-08 15:44       ` Luis Chamberlain
2024-03-08 15:46         ` Chuck Lever III
2024-03-08 15:56           ` Luis Chamberlain

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240308000400.1646823-7-mcgrof@kernel.org \
    --to=mcgrof@kernel.org \
    --cc=kdevops@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox