How can I make virt-install use an interface other than eth0?

Posted on 2014-08-26
Medium Priority
Last Modified: 2014-08-27
I am creating VMs using virt-install.  I can do so on a VM but it is very slow so I'd like to do on another "real" server but it is unable to download the kickstart file because it uses eth0.  How can I make it use a different interface such as br100?

# virt-install -n mick-testVm --hvm -r 2048 --vcpus=1 --os-variant=rhel6 -v --disk path=/images/mick-testVm.img,size=20 -l -x "ks= text console=tty0 utf8 console=ttyS0,115200"

# ifconfig
br100     Link encap:Ethernet  HWaddr 00:22:64:9b:38:46
          inet addr:  Bcast:  Mask:
          inet6 addr: fe80::5886:91ff:fed5:df3f/64 Scope:Link
          RX packets:7811372 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1117332 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:22064958722 (22.0 GB)  TX bytes:75912638 (75.9 MB)

eth0      Link encap:Ethernet  HWaddr 00:22:64:9b:38:46
          inet6 addr: fe80::222:64ff:fe9b:3846/64 Scope:Link
          RX packets:15019041 errors:0 dropped:191 overruns:0 frame:0
          TX packets:1117675 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:22710274213 (22.7 GB)  TX bytes:80426511 (80.4 MB)

lo        Link encap:Local Loopback
          inet addr:  Mask:
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:119356 errors:0 dropped:0 overruns:0 frame:0
          TX packets:119356 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:28950257 (28.9 MB)  TX bytes:28950257 (28.9 MB)

virbr0    Link encap:Ethernet  HWaddr 32:87:90:3a:36:d0
          inet addr:  Bcast:  Mask:
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

# netstat -rn
Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface         UG        0 0          0 br100   U         0 0          0 br100   U         0 0          0 br100   U         0 0          0 virbr0
Question by:mickt
  • 3
LVL 16

Accepted Solution

Joseph Gan earned 1000 total points
ID: 40286840

Author Comment

ID: 40287304
I found and tried this earlier but it did not work.  Does it not configure the interface of the VM?  Need to force the host to use br100 to retrieve ks file.

Here is the issue and why it's failing.  I cannot route to ks server via eth0, only br100.

           │                                                       │
           │ Waiting for NetworkManager to configure eth0.         │
           │                                                       │

        ┌─────────────┤ Error downloading kickstart file ├─────────────┐
        │                                                              │
        │ Unable to download the kickstart file.  Please modify the    │
        │ kickstart parameter below or press Cancel to proceed as an   │
        │ interactive installation.                                    │
        │                                                              │
        │ files/openstack/image-templates/mick-testVm/mick-testVm.cfg_ │
        │                                                              │
        │            ┌────┐                      ┌────────┐            │
        │            │ OK │                      │ Cancel │            │
        │            └────┘                      └────────┘            │
        │                                                              │
        │                                                              │

Author Comment

ID: 40287675
It worked using virbr0, which is set up when libvirt is installed.  I assumed it wouldn't as it has address.  Anyway, good now so cheers.

Author Closing Comment

ID: 40287677
had to use virbr0

Featured Post

Cyber Threats to Small Businesses (Part 2)

The evolving cybersecurity landscape presents SMBs with a host of new threats to their clients, their data, and their bottom line. In part 2 of this blog series, learn three quick processes Webroot’s CISO, Gary Hayslip, recommends to help small businesses beat modern threats.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will show you step-by-step instructions to build your own NTP CentOS server.  The network diagram shows the best practice to setup the NTP server farm for redundancy.  This article also serves as your NTP server documentation.
In this article will go through how to backup a vPostgres DB from a broken vCenter Appliance and restore to a new vCenter Appliance.
How to install and configure Citrix XenApp 6.5 - Part 1. In this video tutorial we have explained step by step installation of Citrix XenApp 6.5 Server on Windows Server 2008 R2 is explained in this video. We have explained the difference between…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses
Course of the Month15 days, 23 hours left to enroll

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question