Andras Dosztal
Andras Dosztal
Network architect
Mar 5, 2018 5 min read

Running GNS3 on Scaleway

thumbnail for this post

I mentioned in the “Sizing your computer…” post that you can run your GNS3 remotely in the cloud. The two bare metal providers were Packet and Scaleway. Packet is described at docs.gns3.com so we’ll focus on Scaleway in this article. Scaleway offers very competitive prices. They have two data centers, both located in Europe. Although they’re currently running low of resources (some servers are either low on or temporarily out of stock), they’re expanding so check back often if the type of server you wanted is not available. Now let’s see what needs to be done to have a remote server running GNS3 on Scaleway!

1) Create and upload your SSH key

Cloud providers usually don’t provide a root password for your server and Scaleway is no different (however you can set a root password after installing the server, then you can access the serial console through the dashboard). After creating an account, follow the steps described by Scaleway to add your SSH key.

2) Create a server

Do the following steps to have the appropriate Ubuntu server created:

  1. Select Servers on the Scaleway dashborad
  2. Click on “Create server”
  3. Enter the server’s name; I used “gns3_remote”.
  4. Optional: Select the location. Note: When I created my server, there were no available resources in Amsterdam.
  5. Select “Baremetal” at “Server range”. You can’t use the other types for GNS3 because those are virtual servers without nested virtualization support.
  6. Look at the X86 row; GNS3 does not support ARM.
  7. Choose the server type that fulfills your needs.
  8. Select Ubuntu Xenial as the host OS.
  9. Optional: If you’ll require more space for your images/projects, you can add more storage space.
  10. Click on “Create server”

The workflow above is shown in these screenshots:

Create new server
Choose bare metal and size
Select OS
Summary

3) Access your server with SSH

After your server’s been created, you can login to it. If you’re running Linux or OSX, just simply access it from the terminal:

ssh root@<PUB_IP>

If you’re accessing your server from Windows using PuTTY, you have to specify the private key that you generated. You can do it under Connection / SSH / Auth:

PuTTY authentication settings

4) Install GNS3

After login, install GNS3 by typing the following commands:

cd /tmp
curl https://raw.githubusercontent.com/GNS3/gns3-server/master/scripts/remote-install.sh > gns3-remote-install.sh
bash gns3-remote-install.sh --with-openvpn --with-iou --with-i386-repository

If the installation is successful, reboot the server.

5) Set up OpenVPN

After reboot, login with SSH again. You’ll receive this MOTD:

               _
 ___  ___ __ _| | _____      ____ _ _   _
/ __|/ __/ _` | |/ _ \ \ /\ / / _` | | | |
\__ \ (_| (_| | |  __/\ V  V / (_| | |_| |
|___/\___\__,_|_|\___| \_/\_/ \__,_|\__, |
                                    |___/
Welcome on Ubuntu Xenial (16.04 LTS) (GNU/Linux 4.4.117-mainline-rev1 x86_64 )
System information as of: Sun Mar  4 09:41:30 UTC 2018
System load: 1.63  Int IP Address: <PRIV_IP>
Memory usage: 0.0%  Pub IP Address: <PUB_IP>
Usage on /: 5%  Swap usage: 0.0%
Local Users: 0  Processes: 122
Image build: 2017-01-05 System uptime: 0 min
Disk nbd0: l_ssd 50G
Documentation: https://scaleway.com/docs
Community: https://community.scaleway.com
Image source: https://github.com/scaleway/image-ubuntu

________________________________________________________________________________
Download the VPN configuration here:
http://:8003/5898bfbc-1b74-11e8-bd43-0007cb03d984/gns3-remote.ovpn
And add it to your openvpn client.
apt-get remove nginx-light to disable the HTTP server.
And remove this file with rm /etc/update-motd.d/70-openvpn

Download the ovpn file from the link highlighted with red above, then remove nginx-light and trim the MOTD with the following commands:

apt-get remove nginx-light
rm /etc/update-motd.d/70-openvpn

Linux

You can simply connect from CLI by typing the following command: sudo openvpn <your_ovpn_file>

Please note that OpenVPN must be installed; if it’s not present on your system, you can install it using this command:

# Debian / Ubuntu
sudo apt-get install openvpn

# SUSE
sudo zypper in openvpn

# Red Hat / Fedora / CentOS (depending on version)
sudo yum install openvpn
- or -
sudo dnf install openvpn

Windows

Download OpenVPN from [here](https://openvpn.net/index.php/open-source/downloads.html).
Next, Next, Install.
Right click on the .ovpn and open it with OpenVPN.

OSX

Install Tunnelblick; it can be downloaded from [here](https://tunnelblick.net/).
Double click on the ovpn file.
Click on the Tunnelblick icon on the top bar to initiate the connection.

6) Configure GNS3

If the VPN connection is up, install GNS3 and configure it the same way as shown below:

Choosing the main server to be remote in GNS3
Remote server settings

Done! Now you can start importing appliances and creating your first project.

Additional notes

  • You don’t need to run the server 24/7; boot it up before doing a lab then shut it down when you’re finished. This lowers your costs as well. Note: it won’t be zero because you still have to pay a small amount of fee for the storage and the public IP address.
  • Your data is saved only if you shut down the server from the dashboard with the “Archive” option selected.
  • I had issues with setting ACLs on the “Security” page. Even though the necessary ports were opened, it seemed like the server stopped responding after a few minutes.
  • If you choose not to use the server for a longer period, you can either delete the server, its IP address, or its volume too.
    • In the first case all your data remains and your can associate it later to another server but you still have to pay for the public IP and the storage.
    • If you delete the server + the public IP, your projects and images are kept but you’ll need to recreate the OpenVPN connection.
    • If you delete everything, you’ll have to do the whole procedure, including importing your projects and appliances, again.