This tutorial explains how to set up internet connectivity for your GNS3 environment using VMware Workstation Pro. The process involves ensuring the network adapters in VMware are ordered correctly and mapping them to the Cloud node within GNS3.
In VMware Workstation Pro, open the settings for your GNS3 VM. It is critical to check the network adapters and their specific order.
You will typically see two network adapters:
The order is very important: the Host-Only adapter must be at the top, and the NAT adapter must be the second one.
Inside the GNS3 GUI, select the Cloud node to provide internet access. When prompted, choose to run this on the "GNS3 VM".
When you connect a cable to the Cloud node, you will see a list of interfaces. These directly correspond to the order of adapters in VMware:
To verify the setup, you can connect Virtual PCs (VPCS) to the different interfaces and request IP addresses via DHCP.
If you connect PC1 to the top interface (eth0) and run DHCP:
ip dhcp
show ip
You will receive an IP address (e.g., 10.0.0.101), but the Gateway field will be blank. Consequently, pinging external sites like google.com will fail.
If you connect PC2 to the bottom interface (eth1), which corresponds to the NAT adapter, and run DHCP:
ip dhcp
show ip
You should receive both an IP address (e.g., 172.16.1.100) and a Gateway (e.g., 172.16.1.2). You can confirm internet connectivity by pinging Google:
ping google.com
If configured correctly, the domain will resolve and you will receive replies.