1, NAT (network address translation mode) (recommended) The use of NAT mode is to let the virtual system with the use of NAT, the host's network to access the public network. in this mode, the host becomes a dual-NIC host, while participating in the existing host LAN and the new virtual local area network, but because of the addition of a virtual NAT server, the virtual local area network in the virtual machine in the external access, the use of the host's IP address, so from the external network view, You can only see the host, the new virtual LAN is completely invisible. Advantage: The virtual system can directly access the Internet without any manual configuration, as long as the host machine can access the Internet.
2, bridged (bridge mode) in this mode, VirtualBox virtual operating system is like a LAN in a separate host, it can access any machine in the network, you need to manually configure the virtual system IP address, netmask, and the host machine in the same network segment, so that the virtual system can communicate with the host machine, the virtual system and the host machine relationship, like two computers connected to the same hub. Understanding the network technology is equivalent to adding a virtual switch on the front end of the host, and then sharing the switch with the host and all virtual machines. Cons: Easy to cause IP conflicts
3, Host-only (host mode) in this mode is a new network of all virtual machines and host, but the LAN and the host itself in the existing local area network is independent of each other, if you do not make additional routing settings, these two LAN will not be connected, Therefore, the new LAN can be considered a separate private network belonging to the current host, and its members are the current host and all associated virtual machines. Cons: is a standalone host that cannot access the extranet
Three types of network setup modes for Linux systems