F5: Difference between revisions
→Enable Internet Access on VMs
Line 448:
=== Enable Internet Access on VMs ===
* Add Interface for the common network on host to the VMs:
sysctl -w net.ipv4.ip_forward=1▼
sudo virsh attach-interface --type bridge --source virbr0 --model virtio client
iptables --table nat --append POSTROUTING --out-interface enp3s0 -j MASQUERADE▼
▲ sudo sysctl -w net.ipv4.ip_forward=1
▲ sudo iptables --table nat --append POSTROUTING --out-interface
sudo iptables --insert FORWARD --in-interface virbr0 -j ACCEPT # virbr0 is newly added interface in VM
|