Wednesday, June 26, 2013

GNS3 non superuser setup

GNS3 non superuser setup

What is GNS3 ? Who can use it ?   
    http://www.gns3.net/

The video-tutorial section under site has a tutorial on how to setup GNS3 in linux at /opt/ through sudo (superuser). But I had some issues while I tried to setup VirtualBox along with it to Link guest PCs. So tried installing it as non superuser, here is how I did it

GNS3 non superuser setup


>Download gns3 and dynamips
    gns3(tar.bz2) : http://www.gns3.net/download/
    dynamips(bin) : http://www.gns3.net/dynamips/

>Unzip gns3 to a folder, say GNS3/
  (I did it in a dir in /home/melwin/Downloads)

>Move dynamips to GNS3/

>Make dynamips executable
    chmod +x dynamips-0.2.8-RC3-community-x86.bin

>Run GNS3/gns3.pyw (either from terminal or GUI)

>Enter Project Name. Change Project Dir location if required

>Locate dynamips
    Edit>Preference>Dynamips>Settings>Executable path to Dynamips
    Locate the .bin that we justed moved to GNS3/
    To test click "Test Settings"
        If "Dynamips 0.2.8-RC3 successfully started" message then OK

>Locate IOS dir
    Edit>Preference>General>General Settings[tab]>Paths>OS images
    Locate the Cisco IOS image directory

>Locate project dir [if not during startup]
    Edit>Preference>General>General Settings[tab]>Paths>Project Directory
    Locate the project directory

>Add IOS images
    Edit>IOS images and hypervisiors>IOS Images[tab]>Settings>Image file
    Locate the Cisco IOS image file (.bin)
    If asked for uncompression, allow
    Select Platform and Model based on the IOS image
    Click Save
        There will be a "waring:IDLE PC will have to be configured" we will get there
    Click Close
    (    My Image : c7200-adventerprisek9-mz.124-2.T2.bin
        so platform:c7200 and model:7200
    )

>Drag-drop router
    From the left panel drag and drop the router whose image has been uploaded
    Right click the router (in the middle panel) and click start to start the router

>Select Idle PC value
    Check CPU History, if any of your CPU has high utilization then IDLE PC value has to been configured
    Right the running router and click "IDLE-PC"
    Wait for GNS3 to calculate and show the list of IDLE PC value(s)
    Select the IDLE-PC value that has a * with it.
    If * not present on any value, select the one with minimum value within the []
    Check CPU History, if CPU utilization drops then OK else repeat these steps.

>Save topology
    File>Save or Save As
    Located the topology.net file in the Project Dir if asked

Since we have installed GNS3 as non-superuser, an error("Can't start dynamips at 127.0.0.1 port 7200") might occur. In this case, you will have to locate and test the dynamips everytime you start GNS3.