Thu 27 Sep 2007
Cisco - Using Dynamips as your personal Internet router
Posted by Josh under Cisco , Cisco Routers , Dynamips , Linux , virtualization -We all know dynamips is a great tool for creating virtual networks and testing router configurations. However, I can never seem to really understand a concept unless I use it in a "real" scenario. I will show you how I have started using dynamips as my personal internet router.
The tap (or loopback in windows) interface on my PC connects to the f0/0 interface on the router and my local area network is connected to interface f1/0.
| 1) How to install Dynamips on Linux: | Watch Video |
| 2) How to connect dynamips to a Linux tap interface: | Watch Video |
| 3) How to connect dynamips to a physical network: | Watch Video |
| 4) How to Configure NAT on your dynamips router: | Watch Video |
For Windows Users, the following tutorials are not actually designed to show you how to create a personal internet router, but hopefully, they can fill in the gaps for the above tutorials.
| 1) How to install dynamips on Windows: | Watch Video |
| 2) How to connect dynamips to a Windows Loopback Interface: | Watch Video |
| 3) How to Connect Dynamips to a physical network: | Watch Video |

(50 votes, average: 4.08 out of 5)







September 28th, 2007 at 3:01 pm
hi ,
i like it, one of the easy way to learn.can u show vlan video
September 29th, 2007 at 4:36 pm
Really helpfull. Thanks for this tutorial.
October 2nd, 2007 at 5:07 am
how can i create lab & interconnect routers via dynamips……… ? once i loaded the image to dynamips and how to create scenarios ….i
October 2nd, 2007 at 7:18 am
Here are a lot of other tutorials for creating lots of scenarios. Linux and Windows.
http://www.blindhog.net/category/dynamips/
Also, see the official tutorial here…
http://dynagen.org/tutorial.htm
Or visit the Hacki’s forums…
http://7200emu.hacki.at/index.php
October 30th, 2007 at 5:48 pm
This is one of the best hands-on tutorial I have enjoyed for a long time. It contains step-by-step guide for anyone to understand
October 31st, 2007 at 6:24 am
Very helpful thanks, but i am not able to connect to server. when i click on dynamips server it opens the CLI giving message press any key to continue but as i press the enter key the CLI closes.
November 14th, 2007 at 7:47 am
Thank you for the tutorials. They are most helpful. It helped me get started and understand dynagen.
November 19th, 2007 at 12:16 am
Very helpfull, Though what kind of routers have you used?
November 21st, 2007 at 10:57 am
Thanks. I normally use 3640 images for dynamips. They have smaller RAM requirements than other images.
December 19th, 2007 at 8:16 am
this tutorial rocks. Very helpful and it saved me a lot of money from building the equipment. Way better than the network simulators because usually the IOS on them are stripped down. Meaning, it leaves out a lot of the features. Using blindhog’s way gives me the full blown router.
December 19th, 2007 at 10:39 pm
Great tutorial. I was thinking about this but not sure if it was feasible. What else have you had to do to lock down the router from outside attacks? A tutorial on that would be a great addition. Also, what’s the performance like? Can it keep up with DSL speed?
December 19th, 2007 at 11:20 pm
Greg,
I really don’t know about performance. I basically just use it to test theories and configuration examples. Other people have reported to me that the performance is not that great. Good enough for testing on a single PC, but not a router replacement.
Josh
January 3rd, 2008 at 5:11 pm
Josh, which IOS image are you using. My 7200 provider image doesn’t have NAT support.
January 4th, 2008 at 12:08 am
I am using a 3640 image.
January 9th, 2008 at 8:58 pm
Hebat Banget ” It Is Very Kind Of you ” Thank’s A lot , I’m Really happy Coz I finish My Exam In Realize Work Study . I’m In Indonesia . Salam KenAl Bro .When u want To came In Bali .In this Place Is A Good Place
February 4th, 2008 at 6:06 pm
You aren’t serious right?? Dynamips is sooo slow… not to mention it’s use like this is surely breaking some sort of law… just install monowall and be done with it.
Articles like this are going to make cisco get sticky with the dynamips project and cause us all to loose a tool so many of us have come to use for so many great things.
February 4th, 2008 at 11:09 pm
Please relax Jayme…
This tutorial series is only meant to test theories and configuration examples.
It is not meant to offend Cisco and cause them to get “sticky”.
February 18th, 2008 at 6:32 pm
I watched the windows video, Looks really good I will try it for sure. I am learning DynaGen with your tutorials. They dont go to waste. Keep it up.
Cheers
March 1st, 2008 at 3:36 pm
nice tutorials!
I always loved this kind of learning. Keep the good work
March 11th, 2008 at 2:47 pm
I have a actual machine that I have setup for dynamips/dynagen and gns3. I would like to have a virtual router used for my home internet connection to test. I get everythig running but I cannot connec it to my network. Virtual connections are fine. Even the MSloopback. I cannot get my dsl router 192.168.1.1 to see the 192.168.1.250 machine. I recreated the tutorial hoping I made a mistake but it was same.
Real xp pro running dynamips and real linksys wrt330N router. Any ideas?
March 11th, 2008 at 3:55 pm
Could be a windows firewall problem.
March 12th, 2008 at 7:29 am
I’m in the same boat as Shawn. I have got the loopback up and connected, but cant ping it or the router from anywhere on the network . I can ping the loopback from the localhost, but cannot ping the router.
There is no firewall running.
Any ideas?
LBS
March 12th, 2008 at 7:44 am
Post the output of the ‘network device list’ batch file and also the .net configuration file.
March 12th, 2008 at 6:25 pm
Josh here it is ..
Network adapters on this machine:
rommon_load_file: unable to create file c7200_i0_rommon_vars (No such file
rectory)
NIO_gen_eth:\Device\NPF_GenericDialupAdapter
Desciption: Adapter for generic dialup and VPN capture
NIO_gen_eth:\Device\NPF_{BF1DD6B0-9923-47CD-ADE1-E9061AC87137}
Name : Local Area Connection
Desciption: Intel(R) PRO”
NIO_gen_eth:\Device\NPF_{576343F0-2C58-4A72-83AD-A2FB7FF25D46}
Name : Local Area Connection 3
Desciption: MS LoopBack Driver
Use as follows:
F0/0 = NIO_gen_eth:\Device\NPF_{…}
==========================================
.net file
autostart = False
[localhost:7200]
workingdir = C:/Program Files/GNS3-04/setups/Chris.Bryant/Core/Working
[[3640]]
chassis = 3640
iomem = 5
ghostios = True
sparsemem = True
idlepc = 0×604f5514
exec_area = 64
image = C:/Program Files/GNS3-04/Images/c3640-jk9s-mz.124-16a/C3640-JK.BIN
[[ETHSW SW1]]
1 = access 1
2 = access 1 nio_gen_eth:\Device\NPF_{576343F0-2C58-4A72-83AD-A2FB7FF25D46}
x = -114.5
y = -88.0
[[ROUTER R0]]
model = 3640
ghostios = False
slot0 = NM-1FE-TX
f0/0 = SW1 1
x = -314.0
y = -249.0
[GNS3-DATA]
[[Cloud C1]]
x = -12.8615777713
y = 125.611157904
connections = SW1:2:nio_gen_eth:\device\npf_{576343f0-2c58-4a72-83ad-a2fb7ff25d46}
Thanks for the help!
LBS
March 12th, 2008 at 7:20 pm
From the router I cant even ping the loopback. I can ping the loopback though from the localhost pc.
LBS
March 12th, 2008 at 7:53 pm
LBS,
What do your arp tables look like?
Windows:
c:\>arp -a
IOS:
router#show arp
Are the ARP resolutions working correctly?
Also, try connecting your loopback interface directly to the router instead of going through the switch….
March 12th, 2008 at 7:56 pm
Josh ..
Here are the results to the commands..
Router#show arp
Protocol Address Age (min) Hardware Addr Type Interface
Internet 10.1.25.1 5 001c.0000.0000 ARPA FastEthernet0/0
Internet 10.1.25.101 - cc00.0000.0000 ARPA FastEthernet0/0
Internet 10.1.25.132 5 00c0.0000.0000 ARPA FastEthernet0/0
Router#
C:\WINDOWS>arp -a
Interface: 10.1.25.132 — 0×3
Internet Address Physical Address Type
10.1.25.101 cc-00-02-30-00-00 dynamic
10.1.25.131 00-13-72-2f-6a-9e dynamic
C:\WINDOWS>
Yep those are my hosts on my network!
I’ve tried the direct config and its also failing.
The loopback is 10.1.25.100 & the router IP is 10.1.25.101
March 12th, 2008 at 8:03 pm
Download wireshark and see if you can see what is going on.
Or, on the router…you can try this:
router(config)#access-list 150 permit tcp any any gt 0 log
router(config)#access-list 150 permit udp any any gt 0 log
router(config)#access-list 150 icmp permit any any log
router(config)#
router(config)#int f0/0
router(config-if)#ip access-group 150 in
router(config-if)#ip access-group 150 out
router(config-if)#
router(config-if)#do term mon
March 12th, 2008 at 8:16 pm
Yep .. I’m seeing the network traffic of other hosts on the LAN..
*Mar 1 00:07:45.263: %SEC-6-IPACCESSLOGP: list 150 permitted udp 10.1.25.130(3321) -> 239.255.255.250(1900), 1 packet
*Mar 1 00:07:56.527: %SEC-6-IPACCESSLOGP: list 150 permitted udp 10.1.25.131(137) -> 10.1.25.255(137),!
!
I can ping hosts on the network now, but cant ping the router or the loopback from the hosts
March 12th, 2008 at 8:47 pm
I must be missing something … This looks pretty strange. The loopback interface and the router should be isolated to their own network.
I do not believe you should be seeing traffic from other hosts on the network…
Send output of ‘ipconfig’ command on your PC.
March 12th, 2008 at 8:57 pm
OMG .. Cant believe thats where the error was at!
I also realized that this isn’t the way I want this setup!
I want to bridge my PC NIC so it can have a true IP on the LAN and use it somewhere in the network and as my edge router if I wanted to .. Doh!
Am I right?
Josh thanks for your help.. Really sorry about the confusion! Your help is outstanding! you’re and awesome (and patient) guy
LBS
March 27th, 2008 at 1:22 am
hi Guys,
I am having the same problem. So what actually is the problem? Is for instant i have vmware and i want all my vmhost to be able to access the router on dynamips. One interface of the router is connected to Ms LOOPBack. So what would be the best way to put all the VM hosts on the same segement and the routers running on the dynamips would be able to ping each of them ? Any ideas guysss
Thanks
March 27th, 2008 at 2:12 am
Veekash,
If I understand what you are trying to do, I would not use the MS Loopback. Instead, use a connection to your actual lan interface. This way, your router should be able to communicate with your LAN as well as your VMWare machines if they are in bridge mode.
Josh
April 4th, 2008 at 8:51 am
Hi
could you please tell me if it is possible to creat a voice lab in dynamips ? thanks
April 4th, 2008 at 8:52 am
Any details will be much appreciated
April 4th, 2008 at 9:50 pm
bilgisayer,
I do have plans of creating videos for a voice lab. It just takes time though…
There are several things you cannot do.
- Unity Express
- hardware conference bridges
- transcoding
- voice-ports
- mgcp
- anything that requires a voice card or dsps.
Here are a few things you can do.
- h323 dial-peers
- sip dial-peers
- gatekeeper
- call manager express
- ip2ip gateways
- voice related tcl scripts
Josh
April 5th, 2008 at 10:58 am
If we can not use voice ports, how can routers support voice and do those things above?
which ios to use for configuring h323, sip or others ? thanks
April 10th, 2008 at 7:28 pm
using windows loopback…when I ping to router, I can see only 50 or 75% sucsess. I am confused as what may be the reason that packets are dropped/not responded…why not 100% is success rate
April 15th, 2008 at 2:22 pm
@bilgisayar, Here is the link with specifics… - Josh
@HKSS, Have you tried using wireshark or another packet sniffer to see what is going on ? - Josh
April 23rd, 2008 at 4:01 am
Hi Josh,
Thanks Josh for creating such nice vidio. There is a demand for Voice lab in this mailer. I am thinking of contribution in respect of voice. Can you please suggest the tool you used for creating the vedio.
Madhukar
April 24th, 2008 at 1:14 am
@Madhukar,
You are welcome. There is a demand for voice labs. However, there are not a lot of cisco voice “blogs” that I have found.
I will be turning more focus on voice in the next few months as I am studying voice pretty hard right now and there is not a lot of information for voice outside of Cisco.com.
The video software I prefer is Camtasia Studio it is $299 at Amazon but very worth it. Some of my older videos were done with Wink. It is free and very easy to use. Another product is camstudio . It is hard to edit your videos.
April 24th, 2008 at 2:08 pm
Hi Josh,
Thanks for your reply. Really CCIE voice requires sustantial amount of time to grasp the technology.
Once we get control over the topic, it becomes easy to present in vedio.
All the best for your voice preparation!
April 30th, 2008 at 8:03 am
Thank you very much for the tutorials. Please keep them coming
May 7th, 2008 at 11:12 am
this videos are really usefull
May 21st, 2008 at 8:34 am
I tried creating the tap interface with a SuSE linux host computer.
It is important to first edit the .net file and start dynagen to automatically create the tap interface. I first tried to manually create it and then start dynagen but that conflicted –
*** Error: Connecting R1 E0/2 to NIO_tap:tap0 resulted in
206-unable to create TAP NIO
With SuSE I didn’t need the special tunctl (package) but could manually add the ip address and bring up the tap0 interface. Just check to see that the ‘tun’ module is already on your linux.
linux:# modprobe tun
linux:# lsmod
Module Size Used by
tun 26752 0
….
So after starting dynagen the tap0 appears.
linux:# ip link show tap0
12: tap0: mtu 1500 qdisc pfifo_fast qlen 1000
link/ether 00:ff:86:58:91:67 brd ff:ff:ff:ff:ff:ff
Then you can manually assign an address and bring ip up. After that you can communicate with the particular ethernet interface defined in your net file.
ip addr add 20.100.100.100/24 dev tap0
ip link set tap0 up
July 5th, 2008 at 4:31 am
how can i sniff the packets i mean i want to use sharkwire so how to mirror the traffic to my loopback switch port…
July 30th, 2008 at 11:04 am
I must say U guys are wonderful! And for the the “Admin” - I will always be ur fan . Keep up the guud job.
I need ur guide on this subject please; I have Dynamips + GNS3 working perfectly on my Windows Vista box with Kaspersky Antivirus, I have the Loopback adapters working as expected & even working well for virtual machines.
The problem i keep having is that “Network Devices” are never listed whenever I try to do “Network Device List” ERROR:No Interface found, make sure winpcap is installed.
I disabled Kasperky, Windows Firewall, Added dynamips.exe to firewall exceptions on both - all to no avail.
All I need is how to get my virtual routers(2)of them connected to the loopback interfaces (2) and enjoy. I have seen the nice video but still stocked.
Any clue will be appreciated - Thanks alot.