Thursday, June 4, 2009

IP over ATM Configuration on Dynamips

Introduction

After searching everywhere with limited success for a tutorial on ATM configuration on Dynamips, I decided to write one here bringing together the whole process to make it easier for others. In this virtual lab, I will setup a lab for IP over ATM configuration on a single laptop running Windows XP, dual-core 1.8 GHz CPU with 1.5 GB RAM.


Scenario

In this lab, I will show how to configure IP over ATM using two Cisco 7200 routers and one ATM switch provided by Dynamips. Since the ATM function is only simulated at a simplistic level, we will not be able to get full ATM switch functionalities. However, this is still useful for someone to have some hands-on ATM experience. I will setup one PVC for data access. I will also connect one router to an Ethernet switch, which is linked to my laptop's loopback adapter. This permits testing from the command prompt, as well as to use the TFTP client on my XP to download the configs from the routers. Finally, once the IP connection is established, OSPF routing protocol is enabled to allow end-to-end access.



Dynagen .net file

To map the above network design for emulation, you need to understand the syntax of dynagen’s .net. I have realized the setup using the following:

autostart = false
ghostios = true
sparsesmem = true
mmap = true
model = 7200

[localhost]
[[7200]]
image = \Program Files\Dynamips\images\C7200-AD.image
ram = 256
idlepc = 0x62b0b568
[[ROUTER R1]]
f0/0 = S1 1
a4/0 = A1 1

[[ETHSW S1]]
1 = access 1
2 = dot1q 1 NIO_gen_eth:\Device\NPF_{192F6952-5AEA-4B4A-8AC0-B07086BA6FAC} #loopback0
[[ATMSW A1]]
1:0:5 = 2:0:5 # qsaal (pvc 0/5)
1:0:16 = 2:0:16 # ilmi (pvc 0/16)
1:1:10 = 2:1:20 # user (pvc 1/10 at R1 and pvc 1/20 at R2)

[[ROUTER R2]]
a4/0 = A1 2

The most important part of this setup is the VPI:VCI details of the ATM switch. There are three lines of VCs here, which represent a PVC for ATM signalling, a PVC for ILMI messages and a PVC for user data connection, respectively. These numbers must then match accordingly with the device configuration.


Detail Device Configuration

Since this is a rather simple and straightforward process, I will go direct to the specific configurations.

1. Configure the IP address of ATM interfaces of R1 and R2. Then bring up those interfaces. Here is R1’s interface configuration:

interface ATM4/0

ip address 10.1.1.1 255.255.255.0
atm ilmi-keepalive 10

2. Configure the QSAAL and ILMI PVCs on both routers. QSAAL is not necessary for PVCs but included here for completeness. On R1:

pvc 0/5 qsaal
!
pvc 0/16 ilmi
!

3. Configure the PVC for data access. The PVC must match the values you have specified in the .net file. Specify IP protocol and remote peer's IP address. Then, specify the encapsulation. On R1, it will look like this:

pvc Data 1/10
protocol ip 10.1.1.2 broadcast
encapsulation aal5snap

4. Verify the configurations.

R1#sh atm vc
VCD / Peak Avg/Min Burst
Interface Name VPI VCI Type Encaps SC Kbps Kbps Cells Sts
4/0 1 0 5 PVC SAAL UBR 155000 UP
4/0 2 0 16 PVC ILMI UBR 155000 UP
4/0 Data 1 10 PVC SNAP UBR 155000 UP

The following output shows that ILMI state is UpAndNormal and the peer address. In this case, the peer is actually R2. In a real setting, this should be the ATM switch providing the UNI interface.

R1#sh atm ilmi-status
Interface : ATM4/0 Interface Type : Private UNI (User-side)
ILMI VCC : (0, 16) ILMI Keepalive : Enabled/Up (10 Sec 4 Retries)
ILMI State: UpAndNormal
Peer IP Addr: 10.1.1.2 Peer IF Name: ATM4/0
Peer MaxVPIbits: 8 Peer MaxVCIbits: 10

5. If all appears as above, ATM configuration is complete! Ping the remote ATM interface for verification.

R1#ping 10.1.1.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.1.1.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/32/88 ms

6. You now have an IP link across the ATM cloud. So you can run anything else above it. Let’s try a routing protocol, like OSPF, which will then allow R2 to be reachable from XP’s loopback. On R1, you will have:

interface FastEthernet0/0
ip address 192.168.10.1 255.255.255.0
!
router ospf 1
network 10.1.1.0 0.0.0.255 area 0
network 192.168.10.0 0.0.0.255 area 1

To enable XP’s loopback to get a dynamic address, I enabled DHCP server on R1 (configuration is not shown here). Also, as OSPF supports different types of network, we need to designate a suitable type for the ATM interface, which is a non-broadcast multi-access (NBMA) medium. In this network, we only have two routers, so a point-to-point type is sufficient.

interface ATM4/0
ip address 10.1.1.1 255.255.255.0
ip ospf network point-to-point

7. Verify that OSPF is working.

R2#sh ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface
192.168.10.1 0 FULL/ - 00:00:38 10.1.1.1 ATM4/0

R2#sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
...text snipped...

Gateway of last resort is not set

O IA 192.168.10.0/24 [110/2] via 10.1.1.1, 00:06:01, ATM4/0
10.0.0.0/24 is subnetted, 1 subnets
C 10.1.1.0 is directly connected, ATM4/0

8. Ping the XP’s loopback interface from R2 to verify end-to-end connectivity.

R2#ping 192.168.10.11
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.10.11, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/35/84 ms

That’s it! Hope you find this useful.

5 comments:

  1. Can you comment on the versions of dynamips and IOS you are using for this configuraion? I'm trying to get ATM working using this setup, and the ilmi status as:

    Interface Type: Unknown
    ILMI State: WaitStartAck

    I'm using dynamips 2.8 and 7200 IOS 12.4(19) and 12.4(25b) enterprise images with no success.

    ReplyDelete
  2. The motherboard as the laptop for me must to be efficient, quality and of course with a reasonable price. That is why costa rica homes for sale i think is the best option in the market if you want to know a beautiful country and to a get a house quality.

    ReplyDelete
  3. i have problem te configure this lab can you help me plz

    ReplyDelete