Networking on Windows VM from KVM/ QEMU Host via Bridge


  1. Posts : 11,246
    Windows / Linux : Arch Linux
       #1

    Networking on Windows VM from KVM/ QEMU Host via Bridge


    Hi folks

    For those running Windows VM's on Linux Hosts and want to try the Linux Hypervisor (VMWare and VBOX will run concurrently so you don't even need to power off any running Windows VM's) with decent networking you need to set up a network Bridge (roughly analogous to External Switch in HYPER-V). Otherwise the VM will have access to the Internet only and other parts of your LAN but no host access either way -- either from HOST TO VM or from VM to HOST.

    I've assumed you've already installed basic networking and managed to create a Virtual Machine . (You can create the bridge of course before creating the Virtual Machine to test if it's working properly).

    1) On the HOST install bridge-utils
    2) Create the bridge -- this is done with a simple file in /etc/netctl directory -- my example is kvm-bridge
    3) here's the simplest possible file . If you don't like the basic vi editor (ugh !!!!) you can use a wysisyg full screen editor e.g kate that allows root save to root access only folders.

    Interface=br0
    Connection=bridge
    BindsToInterfaces=(enp2s0f1) ===>to a physical device in your system --
    IP=dhcp

    4) start the bridge : netctl start kvm-bridge

    5) automatically start at Host boot

    netctl enable kvm-bridge

    6) Check via any command if interfaces all working (via ifconfig or any appropriate command). To display the bridge use the command brctl show.

    7) In Samba add these two lines to /etc/samba.conf file

    bind interfaces only = yes
    interfaces = br0 >>>>> Name of your bridge

    If you don't do this on the HOST (only) the host will not have any access to any VM's on the LAN whatever host they are attached to -- even those on different physical machines - it will still be able to access physical machines and the Internet though.

    8) in the VM config for windows (Easy GUI is to use lib-virt - Virtual machine manager) create virtual network --- specify network source -- etc as shown (for Virtio install the win-virtio drivers otherwise a physical nic card will come up - can be used also but virtio is streets ahead for better for Windows)

    Networking on Windows VM from KVM/ QEMU Host  via Bridge-screenshot_20200106_124616.png

    9) Now your VM has full network access

    Networking on Windows VM from KVM/ QEMU Host  via Bridge-screenshot_20200106_125001.png

    10 ) And from the HOST (Hestur) -- the 2nd VM is a VMWare W10 VM on a different host (wulf) not running KVM.

    Networking on Windows VM from KVM/ QEMU Host  via Bridge-screenshot_20200106_132401.png

    Job Done "Seeemples" !!!


    enjoy !!!! ( it's a lot more fun than just starting up VMWare player !!!!!)


    Cheers

    jimbo
    Last edited by jimbo45; 06 Jan 2020 at 08:33. Reason: Added Network Map from HOST as well
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 01:23.
Find Us




Windows 10 Forums