Search This Blog

Wednesday, June 30, 2021

[Ubuntu] qemu設定Host only網路(qemu set host only network on Windows guest)

[Host] Ubuntu 18.04

qemu/kvm

設定Host網路介面

# sudo ip link add dev bridge00 type bridge
#
sudo ip tuntap add tap00 mode tap user $USER group kvm
#
sudo ip link set tap00 master bridge00
#
sudo ip link set dev bridge00 up
#
sudo ip link set dev tap00 up

# sudo ip addr add 192.168.100.1/24 broadcast 192.168.100.255 dev bridge00

VM的網路要設定為bridge00

 


[Guest] Windows 10

ipv4

設定固定ip: 192.168.100.2 netmask: 255.255.255.0


Reference:

https://plkt.io/2021/01/15/manually-setting-up-host-only-networking-with-qemu-guest/

No comments: