Tue 29 Jul 2008
GNS3 - Switching lab part 2 (router on a stick)
Posted by Josh under Cisco , Cisco Routers , Cisco VOIP , GNS3 -This is part two of my gns3 switching tutorial series. In part 1, you learned how to use a 16 port network module (NM-16ESW) to simulate many features of a Cisco switch. In this tutorial, you will learn how to configure vlans on the switch and how to route between vlans with a ‘router on a stick’ configuration.
This ‘router on a stick’ tutorial is only one example of the many labs that can be created using the NM-16ESW module.
References:
http://www.gns3-labs.com/2008/06/15/topology-vlan-trunking-gns3-lab-8021q-router-on-a-stick/

(9 votes, average: 4.44 out of 5)







July 29th, 2008 at 4:38 am
[...] GNS3 - Switching lab part 2 (router on a stick) Reference:GNS3 - How to build a switching lab Part 1 [...]
July 29th, 2008 at 12:52 pm
Hi,
thanks for this really great tool.
Can you make the tutorial downloadable, or am i doing something wrong?
Thanks for your work,
Meik
July 29th, 2008 at 9:48 pm
meik,
The download link was broken…sorry about that. You should be able to download now.
Josh
July 30th, 2008 at 10:36 am
Is there any way to reduce the CPU Usage when the router is idle for the IOS image you are using?
July 30th, 2008 at 10:53 pm
Ki,
1. Right-Click on the router
2. Click ‘Idle PC’
3. Try different Idle PC values until you find a utilization level you are comfortable with.
Josh
July 31st, 2008 at 11:47 am
[...] Link Leave a Reply [...]
August 1st, 2008 at 2:17 pm
Awesome stuff. Incidentally, what ios image is the one that you’re using for the lab ? I tried with a 3620 platform image and GNS3 is unable to find the slot module after loading the IOS.
August 2nd, 2008 at 9:13 pm
[...] one in a two part series. Part 2 will show you how to configure a “router on a stick”. Click here to see Part 2. A router on a stick is basically when a router is configured to route between two vlans with a [...]
August 2nd, 2008 at 9:54 pm
brokenflea,
I think I am using advanced enterprise image.
Josh
August 3rd, 2008 at 5:56 pm
Very usefull vids. Thanks a million
August 4th, 2008 at 3:22 pm
Hi, Thanks for the lab. Just wanted to point out that you wouldn’t need to configure the vlan database on r0 as it is using a routed (not switchport) port. When using a routed port you only need to specify the vlan tag in the encapsulation dot1q command. With switchports, the vlan must be defined in the vlan database before it will become operational on a switchport.
August 6th, 2008 at 7:59 am
@toti - You’re welcome
@Karl - That is nice to know. I had always added it to the vlan database. My switching knowledge only goes so far…:)
Josh
August 8th, 2008 at 3:12 am
Hi Josh,
Thanks for the video, its a great resource
I am using a 3600 just as you are doing in the video with the NM-16ESW and IOS image
c3640-a3js-mz.124-21.bin which is advance interprise. However I cant use the commands that you are using like “switchport mode access” infact there is no command that starts with “switchport” in the interface config mode.
Do you have any idea where i might be wrong??? Do i need some other IOS version??? Thanks in advance
cheers
bilal
August 14th, 2008 at 6:35 am
Hi Josh,
I’m using a 3700 dynamics gns3 router with the ios c3725-adventerprisek9-mz.124-bin, it allows me to create the vlans but when I go back to priviledge mode and type show vlans, it says no vlan is configured. does this have to do with the code I’m using?
Thanks a lot in advance.
August 14th, 2008 at 9:31 pm
Eyambe,
I haven’t had a chance to test this scenario, but …
You might try applying the vlan database configuration with the ‘apply’ command in vlan database configuration mode.
Or, you could add vlans in global config mode.
Josh
August 19th, 2008 at 6:56 am
Great stuff again, Josh. I’m passing this along to some of my buddies who are looking to lab some switching stuff.
August 19th, 2008 at 3:54 pm
Hello Josh. Thanks for the tutorial. ))
I have same problem, that Bilal has. I don’t hawe “switchport” command.
I am using a 3600 with the NM-16ESW
I’m using:c3660-ik9o3s-mz.124-6.T.bin
How can this be fixed???
Thanks )))
August 20th, 2008 at 3:35 am
Sorry, everything’s workin)))
August 22nd, 2008 at 9:23 pm
Aaron,
Thanks!
Wanderer,
What was the problem?
Josh
August 29th, 2008 at 9:59 pm
Hi Josh,
I just wanted to say thanks a million for these great tutorials. At first, when I found gns3 I was very excited, but quickly became frustrated because I couldn’t get it to work the way I wanted. Thanks to your tutorials, I have a great lab to study, & well on my toward my BCMSN and beyond. I can’t thank you enough!
-Julie
August 31st, 2008 at 12:37 am
Julie,
You’re welcome.
Josh
September 5th, 2008 at 5:47 am
Josh,
Thanks for the tutorials, I have just found GNS3 and these have helped me get it going how I want it. I have some MS certs but am just starting on the Cisco track.
Thanks again.
Eddie
September 7th, 2008 at 5:54 pm
Hi.
Which IOS image do you use for this tutorial?
September 9th, 2008 at 11:14 am
Hi Josh,
Big up from South Africa 2 u for the amazing tutorials u’re providing. I have also just discovered GNS3 & its amazing simulation capabilities.
@wanderer & Bilal - I am experiencing exactly the same prob with IOS c3660-js-mz.124-7a.bin and wonder if this IOS does have trunking support cos I too cannot use the switchport command.
Wot I notice is that after creating the VLans and doin a show vlans command, it immediately tells me no vlans configured.
Am I missin sumthin?
*newbie*
Thanks Gino
September 11th, 2008 at 9:12 pm
josh
thanks for everything on this lab
but if you could point me how to create trunk between vlans will appreciate it
which ios are u using for the switch according to your tutorial that does not help me i guess i need an ios image for the switch
thanks
September 19th, 2008 at 5:49 am
Josh, thats a great lab.
I have an issue however. using the 3640 with the NM-16ESW and the same IOS you use: c3640-ik9o3s-mz.124-18c
The thing is, I type the following commands on the router:
!
interface FastEthernet0/5
switchport trunk encapsulation dot1q
switchport trunk allowed vlan add 5
switchport mode trunk
!
and all are taken without problems. But when I do “sh run” the only config I see is:
!
interface FastEthernet0/5
switchport mode trunk
!
thats, I cant setup the encapsulation and I cant see the vlans that Im allowing
would you had the same problem?, how did you fix it?
Thanks
September 23rd, 2008 at 9:18 pm
Eddie,
Glad to hear the tutorials are helping. Good luck on the Cisco Track!
Josh
September 23rd, 2008 at 9:22 pm
galindro & ginobot & dahir,
I am using c3640-ik9o3s-mz.124-18.bin for this tutorial.
Josh
September 23rd, 2008 at 9:24 pm
javi,
I have not tried configuring allowed vlans. Did you add vlan 5 in the vlan database?
router#vlan database
router(vlan)#vlan 5
router(vlan)#apply
router(vlan)#exit
router#
Josh
October 18th, 2008 at 2:03 pm
Keep it up thanks for such cool video
October 18th, 2008 at 10:16 pm
Hi!
I have som problem with the InterVLAN routing. I´m using a “switch”, 3640 with the 16ESW module and a 3640 as the router. When i try to get ip connectivity between these devices the ARP is not succefull in one direction. I´ve used the “debug ip arp” command and i says “wrong cable”.
Does anybody have an idee what to do?
Regards Johan
October 23rd, 2008 at 4:11 pm
I’m stuck. When I enter the switchport mode trunk on sw0, it trunks to f0/0 not f0/1. I went through the steps in the video several times and I can’t find out what I’m doing wrong. Any ideas?
October 23rd, 2008 at 7:35 pm
Ed,
Can you post the output of your session? I am not following you.
Josh
October 24th, 2008 at 6:51 pm
Hi everyone,
I tried to work on vlan using gns3 router 3600.
I used C3640-IS and also c3640-ik9o3s-mz[1].124-18a. but in both IOS I was unable to use #switchport command
could you please tell me why others pple they have no problem and I am facing this problem.
Please reply me back.
Thank you
October 30th, 2008 at 10:17 am
I can’t replicate it because I forgot to have it save the working configs so all the bin files were deleted. Since then I have not been able to even create the setup you have in the video. None of the devices will start.
In the original problem, when I was performing the step to enter the switchport mode trunk command, the response said it trunked to f0/0 on the switch, not to f0/1 like the video showed. I couldn’t get past that point.
November 1st, 2008 at 2:06 pm
sw0(config)#hostname sw01
sw01(config)#switchport trunk encapsulation dot1q
^
% Invalid input detected at ‘^’ marker.
OK I was describing it wrong. When I reproduced what I did, it did the same thing that happened when I tried it originally. As you see below, f0/0 trunks but I don’t get a message about trunking it to f0/1. Could this be a normal message?
sw01(config)#int f0/0
sw01(config-if)#switchport trunk encapsulation dot1q
sw01(config-if)#switchport mode trunk
sw01(config-if)#
sw01(config-if)#
sw01(config-if)#
*Mar 1 00:09:20.395: %DTP-5-TRUNKPORTON: Port Fa0/0 has become dot1q trunk
sw01(config-if)#