QEMU: Bridge Network Adapter

From OnnoWiki
Revision as of 10:15, 15 September 2020 by Onnowpurbo (talk | contribs) (Created page with "Sumber: https://gist.github.com/extremecoders-re/e8fd8a67a515fee0c873dcafc81d811c ==Setup== Create a bridge sudo su brctl addbr br0 ip addr flush dev enp3s0 brctl addif...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Sumber: https://gist.github.com/extremecoders-re/e8fd8a67a515fee0c873dcafc81d811c

Setup

Create a bridge

sudo su
brctl addbr br0
ip addr flush dev enp3s0
brctl addif br0 enp3s0
tunctl -t tap0 -u `whoami`
brctl addif br0 tap0

Make sure everything is up

ifconfig enp3s0 up
ifconfig tap0 up
ifconfig br0 up
brctl show
dhclient -v br0

Cleanup

Remove tap interface tap0 from bridge br0

brctl delif br0 tap0
tunctl -d tap0
brctl delif br0 enp3s0
ifconfig br0 down
brctl delbr br0
ifconfig enp3s0 up
dhclient -v enp3s0


Release IP

dhclient -v -r <interface>
dhclient -v <interface>




Referensi

Pranala Menarik