Installing GNS3 on Fedora, CentOS and RHEL

Posted on Posted in Linux, Networks

In my never ending quest to find out how “stuff” works, I have decided that now would be a good time to brush up on my networking skills.  After looking around I have found a network emulator which by all counts should be the bees knees, it goes by the name GNS3.

It covers most major brands of network equipment (the links below refer to the manufacturer specific pages on gns3.com);

You can download it from here; https://community.gns3.com/community/software/download

Stuff to download

  • Simply download the latest version of GNS3 using the link above
  • Your machine will need to have access to a yum repository to complete the pre-requisites

Pre-requisites packages

For simplicity I have bundled up all packages I had to install to get GNS3 up and running on my workstation.

sudo yum install python3-setuptools python3-devel python3-sip.i686 python3-sip.x86_64 python3-PyQt4.i686 python3-PyQt4.x86_64 python3-PyQt4-devel.i686 python3-PyQt4-devel.x86_64 python3-net*

Note – It may be possible to install fewer packages, but I will save that for either someone to comment on or I may follow up at a later date on what exactly is required.

Installation

The installation takes a number of different steps to complete everything but hopefully the following list is pretty complete;

  1. Extract the GNS3 Source zip file (I just extracted into a folder with the same name – GNS3-1.3.2.source
  2. Extract each individual component zip file under the same directory that the source was extracted to
    1. dynamips-0.2.14
    2. gns3-gui-1.3.2
    3. gns3-server-1.3.2
    4. iouyap-0.95
    5. vpcs-0.6

Installation of dynamips

So, having read the https://github.com/GNS3/dynamips/blob/master/README.md, I now know what the pre-reqs are and also what needs to be done, so lets get started.

$ sudo yum install elfutils-libelf-devel libuuid-devel libuuid-devel cmake

The above should sort out the pre-reqs.  Now on to compiling the dynamips;

$ cd /path/to/gns3/source/dynamips_extracted_folder
$ mkdir build$ cd build
$ cmake ..
$ sudo make install

End result should be lots of text in the console, and that at the end you should be informed that dynamips can be found here; /usr/local/bin/dynamips

Note – In order to make full use of dynamips, you must use Cisco IOS firmware.  This can be obtained by backing up a router you have in your possession, or failing that, I’m sure that a bit of googling will yield suitable results.

Installation of GNS3-GUI

Assuming all of the above pre-reqs were installed it should simply be a case of running the following;

$ sudo python3 setup.py install 

Assuming the above command ran flawlessly, you should now be able to run gns3 from the command line.

$ gns3

You should get the initial welcome screen appear.  At this point exit from GNS3 and continue with the rest of the installation.

Installation of GNS3-Server

The pre-requisites should already have been dealt with, and therefore you can kick of the installation with;

$ sudo python3 setup.py install 

Installation of IOUYAP

OK, so having got this far, things get a little more involved.  As the iouyap zip file only seems to contain the source code, we need to compile it.

First let’s check to make sure you have the correct packages already installed

$ sudo yum install gcc flex bison glibc-devel iniparser-devel

Now we get our fingers dirty with the following commands;

$ bison --yacc -dv netmap_parse.y
$ flex netmap_scan.l
$ gcc -Wall -g *.c -o iouyap -liniparser -lpthread

The end result should be a a newly created executable file in the sam directory as the source for iouyap.

As always, credit, were credit is due.  The above came from http://forum.gns3.net/topic9886.html.

Installation of VCPS

So you’ve made it this far, now is not the time to give up!!

cd into the directory which you extracted the vpcs zip into and run the following;

$ src/mk.sh 64

The above should work, but it is not something I have built or enabled as for my purposes it wasn’t necessary.

Putting everything together

At this point you should be able to launch gns3 from the command line.

$ gns3 &

Navigate your way to the Edit > Preferences screen and ensure that the configuration is correct for your environment.

From here on you should be able to create routers and start experimenting within your very own personal lab.

Let me know how you get on.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.