Prepare Virtual Lab on Ubuntu Using Dynamips and Dynagen

Dedicated to

This post might not be written without the inspiration of Farid Mohammad Rashed Amin aka Biddut-bhai, for whom I have my deepest respect. A tech lover with such an enthusiastic mind at this level just blown my mind.


Routing trainers across the globe wouldn’t be that happier if Christophe Fillot didn’t create an wonderful emulator in 2005 called Dynamips. This application just made our life easier than ever. It’s basically written to simulate some selected Cisco IOS. “Of course, this emulator cannot replace a real router, it is simply a complementary tool to real labs for administrators of Cisco networks or people wanting to pass their CCNA/CCNP/CCIE exams.” Refer to its Git page for more info.

Dynagen is a text-based front end for Dynamips, which uses the “Hypervisor” mode for communication with Dynamips. It uses a simple, easy to understand configuration file for specifying virtual router hardware configurations. It provides a management CLI for listing devices, starting, stopping, reloading, suspending, resuming, and connecting to the consoles of virtual routers.


  1. OS: Ubuntu
  2. Dynamips: dynamips-0.2.8-RC2-amd64.bin
  3. Dynagen: dynagen-0.11.0.tar.gz
  4. Cisco IOS: c7200-advipservicesk9-mz.152-4.S3

Installation of Dynamips and Dynagen on Ubuntu

1. Prepare the system by installing the following applications, just in case if you haven’t done it yet and if it requires.

awal@rnd:~$ sudo apt-get install wget rpm unzip python-flask python-crypto

2. Create a new directory for Dynamips

awal@rnd:~$ sudo mkdir /opt/dynamips

3. Download latest Dynamips and Dynagen software, move them to /opt/dynamips and extract there.

awal@rnd:~$ cd /tmp
awal@rnd:/tmp$ sudo wget
awal@rnd:/tmp$ sudo wget
awal@rnd:/tmp$ sudo mv dynagen-0.11.0.tar.gz /opt/dynamips
awal@rnd:/tmp$ sudo mv dynamips-0.2.8-RC2-amd64.bin /opt/dynamips
awal@rnd:/tmp$ cd /opt/dynamips
awal@rnd:/opt/dynamips$ tar -zxvf dynagen-0.11.0.tar.gz

4. Create a symbolic link for Dynamips and Dynagen.

sudo ln -s /opt/dynamips/dynamips-0.2.8-RC2-amd64.bin dynamips
sudo ln -s /opt/dynamips/dynagen-0.11.0/dynagen dynagen
sudo updatedb

5. Change the folder’s permissions.

awal@rnd:/opt/dynamips$ sudo chmod -R 755 /opt/dynamips

6. [Optional] Create a directory to store IOS image. In my case, I am using Cisco IOS c7200-advipservicesk9-mz.152-4.S3.bin. Multiple images can be stored here so and can be used according to the requirement Once copied, extract it as well.

awal@rnd:/opt/dynamips$ sudo mkdir images
awal@rnd:/opt/dynamips$ cd images
awal@rnd:/opt/dynamips/images$ sudo unzip c7200-advipservicesk9-mz.152-4.S3.bin > c7200-advipservicesk9-mz.152-4.S3.image

7. [Optional] Create a project directory just to keep your projects organised. And, under the projects directory create a work directory as well so that necessary working files related to a particular project can be stored there.

awal@rnd:/opt/dynamips$ sudo mkdir projects
awal@rnd:/opt/dynamips$ sudo mkdir projects/works

Configure a Test Lab

[…To be continued]

* Due to my preoccupation I couldn’t finish this post today. I’ll do it very soon. Please stay tuned.

Leave a Reply

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