← Back to Guides Homepage

How to Get Internet in GNS3 (VMware Tutorial)

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.

Step 1: Verify GNS3 VM Network Settings

In VMware Workstation Pro, open the settings for your GNS3 VM. It is critical to check the network adapters and their specific order.

1. Host-Only vs. NAT Adapters

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.

Step 2: Add the GNS3 Cloud Node

Inside the GNS3 GUI, select the Cloud node to provide internet access. When prompted, choose to run this on the "GNS3 VM".

1. Connecting the Interfaces

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:

Step 3: Verification and Testing

To verify the setup, you can connect Virtual PCs (VPCS) to the different interfaces and request IP addresses via DHCP.

1. Test Scenario: Host-Only Connection (Failure)

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.

2. Test Scenario: NAT Connection (Success)

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.

← Back to Guides Homepage