[stordis-toc]
Introduction
GNS3 lets you build and test SONiC networks without physical switches. The GNS3 VM is a ready virtual machine with the GNS3 server. You do not need to install GNS3 manually.
This guide shows how to deploy the GNS3 VM on VMware ESXi, configure it, start it and open the GNS3 web interface.
Prerequisites
- VMware ESXi 8.0 and access to its web interface (ESXi Host Client). The GNS3 VM also operates on ESXi 5.5–7.0, but the screens are different. This guide does not show vSphere.
- A CPU with hardware virtualization (Intel VT-x with EPT or AMD-V with RVI). GNS3 runs SONiC as nested virtual machines.
| Resource | Recommended for the GNS3 VM |
|---|---|
| CPU | 8 or more cores (for example Intel Core i7/i9, AMD Ryzen 7/9 or a server CPU) |
| RAM | 32 GB or more |
| Disk | 80 GB or more on an SSD datastore |
What you need
- The GNS3 VM for VMware ESXi (refer to Step 1). Use the same version as your GNS3 client.
- A datastore with enough free space.
- A network with a DHCP server for the GNS3 VM.
Step 1: Download the GNS3 VM
- Go to https://gns3.com/software/download-vm.
- Select VMware ESXi.
- Go to https://github.com/GNS3/gns3-gui/releases.
- In the Assets of the release, download the GNS3 VM file for VMware ESXi.
The file is a ZIP archive. Extract it. It contains the file GNS3 VM.ova.
Step 2: Deploy the VM from the OVA file
-
Open the ESXi web interface and click Create/Register VM.
-
Select Deploy a virtual machine from an OVF or OVA file and click Next.
-
Type a name for the VM. Drag the file
GNS3 VM.ovainto the blue box, or click it to select the file. -
Select the datastore and click Next.
-
Set the deployment options (network mapping, disk provisioning) and click Next.
-
Click Finish. Wait until the upload of the disks is complete. Do not close the browser tab during the upload.
Step 3: Create a port group for GNS3
GNS3 connects lab devices to the network. The port group must accept traffic of other MAC addresses.
-
Select Networking > Port groups > Add port group.
-
Type the name
GNS3and select the virtual switch. Open Security and set Promiscuous mode, MAC address changes and Forged transmits to Accept. Click Add.
Step 4: Configure the VM
-
Select the GNS3 VM and click Edit settings.
-
Set CPU and Memory (refer to the table in Prerequisites). Set Network Adapter 1 to the port group
GNS3. -
Open CPU and select Expose hardware assisted virtualization to the guest OS. Click Save.
CAUTION
Without hardware assisted virtualization, GNS3 cannot start SONiC with KVM.
Step 5: Start the VM and open the GNS3 web interface
-
Select the GNS3 VM and click Power on.
-
The console shows the start of the VM.
-
When the VM is ready, the console shows the IP address of the GNS3 server. Write down the address.
-
In a web browser, open the IP address. The GNS3 web interface opens.
To add SONiC to GNS3, create an appliance template (refer to the links at the end of this guide).
Troubleshooting
Power off the VM. In Edit settings > CPU, select Expose hardware assisted virtualization to the guest OS (Step 4). Make sure that virtualization is enabled in the BIOS of the ESXi host.
The web interface can have problems with large OVA files. Extract the OVA file (for example with 7-Zip or tar -xvf "GNS3 VM.ova"). Then in Step 2, select the .ovf file and the .vmdk files together.
The GNS3 VM gets its address from DHCP. Make sure that the port group GNS3 is on a virtual switch with an uplink to a network with a DHCP server.
Procedure completion
Congratulations!
You have successfully set up the GNS3 server on VMware ESXi. Now you can add SONiC and build virtual networks for tests and training.
Happy networking!
Useful links:
How to install and configure GNS3 Desktop Client (Windows / Linux / Mac)?
How to create a new GNS3 appliance template to work with SONiC using GNS3 Desktop Client?
How to create a new GNS3 appliance template to work with SONiC using GNS3 Web UI?
How do I set the full connection speed for the cloud in GNS3 running on VMware ESXi?
For more free resources, visit: https://stordis.com/free-resources/
Comments 0
Comments
Please sign in to leave a comment.