Thursday, March 26, 2009

How to setup CCIE Voice Home lab with Dynamips/VMware

This is an attempt to simulate a decent CCIE Voice home lab on a single PC (with oodles of memory and a bleeding edge CPU).

  • What can it do?
    • Frame Relay/OSPF
    • Calls between all sites using 4 digit or full E.164 numbers
    • Full route plans using RG, RL, RP and H323 gateways or trunks
    • SRST
    • AAR
    • Voicemail integration of CCM/CME with Unity
    • IPCC (almost everything)
    • CME , COR, dial plan with 4 digit or full E.164 dialing
    • WAN QoS
    • Call manager Applications - IPMA, Ext Mob, Attendant Console
    • Gatekeepers, IPIP GW, SIP gateways and trunks
  • What doesn't work?
    • Anything that involves a DSP like transcoding, conferencing or calls with multiple codecs
    • Any type of voice port configuration - PRI or CAS, FXO/FXS, E&M..
    • Anything related to the 6500, VG248, ATA (although it might be possible to connect to an ATA externally if you are adventurous - all it needs is a DHCP address and access to CCM), specifically port configuration or QoS.
    • CUE or anything related to it
    • LAN QoS
    • MGCP
  • How is this done?
    • Four routers in dynamips, one for PSTN, one each for HQ, RS1, RS2
    • Frame relay over T1 cross-overs between all three sites
    • All four routers connected by FE to a virtual switch for H.323 traffic
    • VMware server with CCM/IPCC on one VM, Unity on another, 3 virtual networks
    • Third VM running Windows 2000Pro (XP is a hog) with 3 NIC cards
    • Multiple copies of IP Blue 'evaluation' phone on the w2k workstation for HQ, RS1,RS2, PSTN phones.
    • Basic configurations as detailed below for all routers.
    • Lots and lots of memory and a bleeding edge CPU.
    • Did I tell you lots and lots of memory and a bleeding edge CPU?
    • Patience - If all of this stuff is running at once, this thing will be crawling - start up only the stuff you need, and it will rock!

Following is a diagram of how it is all set up





  • VMware is set up with three network adapters vmnet1,vmnet2 and vmnet3 with ip addresses as 10.101.1.1/24, 10.102.1.1/24 and 10.103.1.1/24
  • HQ, RS1 and RS2 connected to PSTN via T1 crossover and frame-relay encapsulation
  • HQ, RS1 and RS2 routers has their fa0/0 interface with 10.[101/102/103].1.254
  • HQ, RS1 and RS2 routers has the loopback0 with 10.[11/12/13].1.254
  • PSTN, HQ, RS1 and RS2 has their fa0/1 interface as 10.100.1.[1/2/3/4]
  • HQ, RS1 and RS2 has VOIP dial-peers with 'session-target ipv4:10.100.1.1'
  • PSTN router has CME enabled and the extensions 911,101xxxyyyy,202xxxyyyy, 303xxxyyyy and so on..
  • PSTN router has VOIP dial peers pointing to the appropriate router for the extensions that belong at that site, for example 'session target ipv4:10.11.1.254' for 'destination-pattern 101xxxyyyy'
  • CME with B-ACD on the RS2 router
  • SRST with AA on the RS1 router
  • IPIPGW must be running on the HQ and RS1 routers - here's why. CCM will have HQ and RS1 routers configured as H.323 gateways - so the call to "PSTN" is a call to the H.323 gateway, which hits the router and.. the router in turn sends the call over h.323 to the "PSTN" simulator. So, the call has two h.323 legs to go one way - 'voice service voip, allow connections h323 to h323' - sound familiar? :-)
Forgot to mention one key part - My laptop is not running Windows - I am a long time Linux fan and is running Slackware 11.0, VMware server 1.0.3 on a Dell D620 with dual Centrino and 2GB of RAM.

That's pretty much what I can think of now.. Configs are included below to have the basic connectivity going as mentioned above. Rack your brains to build out the rest.

There are excellent notes by people elsewhere on the net on how to get CCM installed in a VM, how to launch multiple IP blue phones simultaneously (speaking of IP blue phones, I will write up another tip for getting multiple of those phones running quickly and post it here next), et cetera, et cetera..

Standard Disclaimers, just to avoid any hard feelings going forward :-)

I CANNOT provide you IOS images or CCM/IPCC software, All the trademarks and references of any of the commercial/ non commercial software/hardware referenced in this post are the properties of their respective owners and I do not claim any rights to them whatsoever... and last but not least, I am not responsible for anything that results directly or indirectly from following my instructions here - anything at all including but not limited to 'your computer blowing up' or 'your girlfriend/wife leaving you since you got hooked to VMware or dynamips'.

Three cheers for dynamips , dynagen and VMware.. and good luck for those who are working on their CCIE Voice labs!!

Dynagen .NET file for the network section :

I used 2691 routers since they can do IOS with IPIPGW, Frame relay, dot1q trunks, dhcp server, CME, SRST , h.323, SIP and so on with IOS 12.4 on 128MB RAM. The IOS I used is c2691-adventerprisek9_ivs-mz.124-9.T1. Yes, I know that this is not the same IOS mentioned in the lab blue print at Cisco's site, but this does most of what 'wanted to learn' using this environment. The idlepc values are specific to my IOS, and might not work if you use a different IOS - I get the dynamips CPU/memory usage down to 30%/32% approximately with these values when all of the devices up and running (CPU spikes momentarily to 99% while doing 'show running' or 'write mem' though).

ghostios = True
[localhost]

[[2691]]
image = /data/tftpboot/C2691-IP.BIN
ram = 128
slot1 = NM-4T

[[ROUTER PSTN]]
model = 2691
f0/1 = S4 1
s1/0 = HQ s1/0
s1/1 = RS1 s1/0
s1/2 = RS2 s1/0
idlepc = 0x60af83ec

[[ROUTER HQ]]
model = 2691
f0/0 = S1 1
f0/1 = S4 2
idlepc = 0x61f02640

[[ROUTER RS1]]
model = 2691
f0/0 = S2 1
f0/1 = S4 3
idlepc = 0x61f02640

[[ROUTER RS2]]
model = 2691
f0/0 = S3 1
f0/1 = S4 4
idlepc = 0x61f02640

[[ethsw S1]]
1 = access 1 NIO_linux_eth:vmnet1

[[ethsw S2]]
1 = access 1 NIO_linux_eth:vmnet2

[[ethsw S3]]
1 = access 1 NIO_linux_eth:vmnet3

[[ethsw S4]]
1 = access 100
2 = access 100
3 = access 100
4 = access 100


Relevant sections of the PSTN router

frame-relay switching

interface FastEthernet0/1
ip address 10.100.1.1 255.255.255.0
speed 100
full-duplex
h323-gateway voip interface
h323-gateway voip bind srcaddr 10.100.1.1

interface Serial1/0
description HQ-RTR
no ip address
encapsulation frame-relay IETF
serial restart-delay 0
frame-relay lmi-type ansi
frame-relay intf-type dce
frame-relay route 201 interface Serial1/1 101
frame-relay route 202 interface Serial1/2 102

interface Serial1/1
description BR1-RTR
no ip address
encapsulation frame-relay IETF
no fair-queue
serial restart-delay 0
frame-relay lmi-type ansi
frame-relay intf-type dce
frame-relay route 101 interface Serial1/0 201

interface Serial1/2
description BR2-RTR
no ip address
encapsulation frame-relay IETF
serial restart-delay 0
frame-relay lmi-type ansi
frame-relay intf-type dce
frame-relay route 102 interface Serial1/0 202

ip route 10.11.1.0 255.255.255.0 10.100.1.2
ip route 10.12.1.0 255.255.255.0 10.100.1.3
ip route 10.13.1.0 255.255.255.0 10.100.1.4

tftp-server flash:P00307020200.bin
tftp-server flash:P00307020200.loads
tftp-server flash:P00307020200.sb2
tftp-server flash:P00307020200.sbn

dial-peer voice 2000 voip
destination-pattern 1011111...
session target ipv4:10.11.1.254
dtmf-relay h245-alphanumeric
codec g711ulaw
no vad

dial-peer voice 3000 voip
destination-pattern 2022222...
session target ipv4:10.12.1.254
dtmf-relay h245-alphanumeric
codec g711ulaw
no vad

dial-peer voice 4000 voip
destination-pattern 3033333...
session target ipv4:10.13.1.254
dtmf-relay h245-alphanumeric
codec g711ulaw
no vad

dial-peer voice 1 voip
incoming called-number .
dtmf-relay h245-alphanumeric
codec g711ulaw
no vad

telephony-service
load 7960-7940 P00307020200
max-ephones 1
max-dn 5
ip source-address 10.100.1.1 port 2000

ephone-dn 1 dual-line
number 911

ephone-dn 2 dual-line
number 1015551111

ephone-dn 3 dual-line
number 2025552222

ephone-dn 4 dual-line
number 3035553333

ephone-dn 5 dual-line
number 55987654321

ephone 1
mac-address 0000.0000.0000
type 7960
button 1:1 2:2 3:3 4:4 5:5

gateway

Sample Site router HQ:

voice service voip
allow-connections h323 to h323

interface Loopback0
ip address 10.11.1.254 255.255.255.255
h323-gateway voip interface
h323-gateway voip bind srcaddr 10.11.1.254

interface FastEthernet0/0
ip address 10.101.1.254 255.255.255.0
speed 100
full-duplex

interface FastEthernet0/1
ip address 10.100.1.2 255.255.255.0
speed 100
full-duplex
no cdp enable

interface Serial1/0
no ip address
encapsulation frame-relay IETF
serial restart-delay 0
frame-relay lmi-type ansi

interface Serial1/0.1 point-to-point
ip address 10.200.1.1 255.255.255.0
ip ospf mtu-ignore
frame-relay interface-dlci 201

interface Serial1/0.2 point-to-point
ip address 10.200.2.1 255.255.255.0
ip ospf mtu-ignore
frame-relay interface-dlci 202

router ospf 1
network 10.200.1.0 0.0.0.255 area 0
network 10.200.2.0 0.0.0.255 area 0
network 10.101.1.0 0.0.0.255 area 0
network 10.102.1.0 0.0.0.255 area 0
network 10.103.1.0 0.0.0.255 area 0

dial-peer voice 1 voip
destination-pattern .T
session target ipv4:10.100.1.1
incoming called-number .
dtmf-relay h245-alphanumeric
codec g711ulaw
no vad

dial-peer voice 2010 voip
destination-pattern 1011111...
session target ipv4:10.101.1.10
dtmf-relay h245-alphanumeric
codec g711ulaw
no vad

gateway


In addition, create static routes on the workstation redirecting traffic for the HQ, RS1 and PSTN loopback interfaces through HQ router, and the CME related traffic to the CME router. This reduces delay to the PSTN phone (which again is on your w2k desktop with TFTP address pointing to 10.100.1.1)

..now let the comments begin.

posted by jayanm

Tuesday, March 24, 2009

HOWTO: Tell dynagen to open new screen windows in *nix

I realized I posted this in another window, but it looks like it belongs here.

You can configure dynagen in linux, mac, freebsd - pick your poison, to open console windows in existing screen sessions with proper naming.

To do this, simply add to your dynagen.ini file commenting out the existing telnet option:

# Uncomment below for Linux
#telnet = xterm -T %d -e telnet %h %p > /dev/null 2>&1 &
telnet = screen -X screen -t "%d Dynamips (%h:%p)" -l `if [ -z "\`ps axu | grep 'telnet %h %p' | grep -v grep\`" ]; then echo telnet %h %p; else echo '/bin/false'; fi`

Then, in dynagen, all you have to do is run con /all. This will only open each window -once-, and the small bash script we embedded in the telnet command will check for existing windows and abort opening any duplicates. See the screenshot for details.


=> con /all

This will go through each of the routers that appers in dynagen and open only one window under screen.

=> list
Name Type State Server Console
Client1 3640 running localhost:7200 2000
Client2 3640 running localhost:7200 2001
ISP 3640 running localhost:7200 2002
Hub 3640 running localhost:7200 2003
Server 3640 running localhost:7200 2004
fw1 525 running localhost:10525 4000
fw2 525 running localhost:10525 4001


To manipulate screen, the default meta-key is CTRL+A. Combine this with another key, like space, to scroll through windows. Use a specific number to go to that window number CTRL+A, space or CTRL+A, 1.
Renaming a window is CTRL+A, a and listing current windows is done by CTRL+A, ".

For a list of other screen metakeys and functions read the screen manual or type CTRL+A, ? for other options

Posted by JP

Saturday, June 7, 2008

Finding Cisco IOS with Google

As I promised, I will show you a little trick to digging IOS out of the Internet by using a powerful search engine...Goolgle.com

This trick is just use google search option "intitle:index.of" and follow by the IOS Series then filter out the results from cisco.com

For example,
7200 search with >>> intitle:index.of c7200*.bin -site:cisco.com TRY
3660 search with >>> intitle:index.of c3660*.bin -site:cisco.com TRY
PIX search with >>> intitle:index.of cisco pix*.bin -site:cisco.com TRY

Another good resource that worth to check it out is Sadikhov forums in Cisco sharing section HERE


Enjoy!!

Friday, May 16, 2008

Some posts were deleted..

i found that some posts about download stuffs were deleted from my blog. i guess direct links to illegal stuffs are against Blogger.com's rule but those files still necessary for us who study about cisco. so i will post some url that your can find IOS for use in your study with in next few days.

Cheers.

Thursday, May 8, 2008

Dynagen v.0.11.0 released

Finally, new version of Dynagen released after a long waiting period (for me^^).
Despite using the same Dynamips core which is release half year ago, Greg adds some useful features such as dynamic configuration for .net file and Pemu support (PIX Emulator).

Which mean with new version of Dynagen we can edit .net file without restart the whole lab and we can manage PIX or ASA instances in Dyangen console. This surely makes our life easier ^^

Thanks Greg!


More info: Dynagen change log

Friday, March 21, 2008

Dynagen Interim Build Released

As Greg's post in his blog , new version of Dynagen has many significant changes such as
- merging code with confDynagen to achieve the ablility to reconfigure lab files while it's running.
- support Pemu server which mean we can emulate router as well as PIX or ASA boxes together in Dynagen.
download here

With these new features, we can build CCIE Security Lab and run it in PCs. More info about this at Hacki's forums

However, the code still in beta phrases and has some bugs, if u don't wanna waste your time for those unexpected errors, choose released version and wait until the new release version come out.

As now, Dynagen doesn't has any help for these new features, you can see tutorials from this >> Tutorial

Saturday, September 15, 2007

Become a CCIE with Simulator

Several months ago I wrote 'How to Become a CCIE', a step-by-step for wanna-be-CCIE out there based on my own experience passing two lab exams. In point no. 3 I mentioned that it's compulsory to have a home lab to be able to practice anytime.

How if we can save some money by not buying the equipment but using simulator instead? Thanks to Christophe Fillot, the author of Dynamips - Cisco 7200 Simulator, now it's possible to have a full CCIE lab in our PC.

The idea of this simulator is to emulate Cisco 7200 environment with MIPS processor in normal PC, so we can boot the genuine IOS for Cisco 7200 with 12.2 and 12.4 version. It can simulate various type of network modules such as PA-4T or PA-TE-FX to provide enough serial and ethernet interfaces. The simulator offers virtual ATM, FR and ethernet switch too. If we can simulate 8-9 routers, with ATM, FR and ethernet switch, and put proper interconnection between those routers..voila! we have a complete CCIE lab!

READ MORE...

Credit: Original published in Himawan Nugroho's blog