Showing posts with label dynamips. Show all posts
Showing posts with label dynamips. Show all posts
What is NAT?
Network Address Translation translates your local or private IP addresses to public IP addresses so you can communicate with the internet world.
Why NAT? Because its expensive to buy public IP addresses to each and every computer in a network.

Types of NAT:
Static NAT: This is like one-to-one i.e. your one particular private ip address is always translated to one dedicated public ip address.
Dynamic NAT: This is like many-to-many. Your list of private ip addresses are translated to a pool of public addresses, a public ip dynamically picked from that pool for your private ip addresses.
PAT-Port Address Translation: This is like one to many. Your list of private ip addresses are translated to one public ip address. This uses source port no. of your local network to differentiate individual hosts or computers in your local network. This is also called NAT Overload.


Lab:
Local router:
f0/0 - desktop
f0/1 - vpcs1
s1/0 - border router

Border router:
s1/0 - local router
s1/1 - isp router

Isp router:
s1/1 - border router and f0/0 - vpcs2

Local router configuration:

Border router configuration:

 
Isp router Configuration:

Vpcs Configuration:








  • Desktop( MS Loop back Adapter) gets 10.0.0.2   255.255.255.252, GW: 10.0.0.1, DNS:  10.0.0.1
  • We will use EIGRP in Local and Border routers for routing protocol, so that desktop and vpcs can communicate with Border router via Local router. We will configure them both routers in Autonomous system no 10 so they become neighbours and exchange topology database.

local(config)#router  eigrp 10
local(config-router)#network   10.0.0.0

  • Border router should be able to communicate with both public and private networks. With Eigrp, border router is already communicating with our local networks. In real world, all local computers connect to border router and border router knows how to get to ISP router, these settings are given by ISP provider. For this lab, we will need to configure border router ourselves, it needs to know the routes. We can use any routing protocol but because we only have one network 99.0.1.0 to be included in the routing table, since 99.0.0.0 is directly connected, lets use static routing.

border(config)#router eigrp 10
border(config-router)#network   10.0.0.0
border(config-router)#network   99.0.0.0
border(config)#ip   route   99.0.1.0    255.255.255.252     99.0.0.2
border(config)#ip    default-network    99.0.0.0

  • I also used 'ip default-network' command so EIGRP can adveterise it to local router.
  • With all the above setup we should be able to succefully ping within our local network and within our public i.e. 99.0.0.0 and 99.0.1.0 network. But we can not ping from local network to public network and thats where NAT comes into picture. NAT will translate our local ip addresses to public ip address so we can communicate with our public networks. We are going to implement NAT overload or PAT in our border router.

border(config)#ip   nat   pool   test   99.0.0.1   99.0.0.1  netmast    255.255.255.252
border(config)# access-list   10   permit   10.0.0.0    0.0.255.255
border(config)# ip   nat   inside   source   list   10  pool   test   overload

  • First line creates a pool called 'test' with a range of public addresses. In this case only 99.0.0.1 because we're implementing NAT overload i.e. many-to-one. However, we can use more than one public IP.
  • Second line creates a list of our local addresses identified by no. '10' with 'permit' option.
  • Third line tells NAT to translate inside addresses that are specified in list no. 10 to addresses in pool named 'test', the 'overload' tells NAT to use port no.'s to identify a particular host in the local network.
  • Now we're left configuring interfaces as belonging to inside network or outside network in our border router. In this lab, s1/0 of border router belongs to inside network and s1/1 to the outside.

border(config)#int s1/0
border(config-if)# ip nat inside
border(config-if)#int s1/1
border(config-if)#ip nat outside

Verification:


References:
http://www.cisco.com/en/US/tech/tk365/technologies_tech_note09186a0080094374.shtml
Posted by Freeman On 3:27 AM 0 comments
Stumble ThisFav This With TechnoratiAdd To Del.icio.usDigg ThisAdd To RedditAdd To FacebookAdd To Yahoo
Of all the features of gns3 the one i like is to be able to include my real PC in the topology I created. Lets see how we can do this:

Prereq: You have to run gns3 as Administrator for this. How? type 'gns3' in the windows start menu bar, right click on the 'gns3' program, and then 'Run as administrator.'
  • Now drag your router in the main window, right click on it start it, then right click choose console. keep it like that.
  • In the gns3 main window, click edit, symbol manager, from 'availabe symbols' select computer and click on the '>' the right arrow button. Now on the top right of the symbol manager type name as 'computer' and SELECT TYPE AS 'CLOUD' from the drop down list, then click OK. you should see this computer symbol in the left panel of gns3 main window.
  • Drag that computer into the work space, right click on it, choose configure, select 'c0'( this may be c1 or c2 .... ) under the clouds section.
  • OK now you should see bunch of tabs, first one is 'NIO ethernet'. In this tab, under "Generic ethernet NIO.. bla bla" choose your network adapter and then click on ADD, Apply, OK.
Note: If you have only one network adapter you're fine. But if you have more than one like on my laptop( wireless and lan) you wanna make sure you chose the one that is active.

OK now your router and your real PC is in the picture, lets connect them and test communication:
  • In the router console lets configure any of the fastethernet ports first.
  1. router>enable
  2. router#configure terminal
  3. router(config)#interface fastethernet 0/0
  4. router(config-if)#no shutdown
  5. router(config-if)#ip address 192.168.1.222 255.255.255.0
  6. NOTE:choose an ip address that would be in the same network as your pc. ex: my pc has 192.168.1.105
Alright, the ethernet is interface is ready on the router and the active network adapter on your pc is ready, now we need a ethernet cable to connect these two.
  • click on 'add a link' button on the top front panel, choose manual.
  • Now click on the router, it displays a list availabe interfaces, we've configured fastethernet 0/0 so lets choose f0/0.
  • Click on the computer, it will show the only availabe interface which is your network adaptor. so, choose that and we are done with connecting the router to your real pc.
Lets check if the connection is working:
  • In the command prompt
  • C:\>ping 192.168.1.222

    Pinging 192.168.1.222 with 32 bytes of data:
    Reply from 192.168.1.222: bytes=32 time=63ms TTL=255
    Reply from 192.168.1.222: bytes=32 time=22ms TTL=255
    Reply from 192.168.1.222: bytes=32 time=2ms TTL=255
    Reply from 192.168.1.222: bytes=32 time=2ms TTL=255

    Ping statistics for 192.168.1.222:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
    Approximate round trip times in milli-seconds:
    Minimum = 2ms, Maximum = 63ms, Average = 22ms

  • In the telnet console of your router do the same
  • Router#ping 192.168.1.105

    Sending 5, 100-byte ICMP Echos to 192.168.1.105, timeout is 2 seconds:
    !!!!!
    Success rate is 100 percent (5/5), round-trip min/avg/max = 4/21/40 ms
    Router#

OK... so that shows we achieved what we wanted! Have fun.
Posted by Freeman On 1:59 PM 0 comments
Stumble ThisFav This With TechnoratiAdd To Del.icio.usDigg ThisAdd To RedditAdd To FacebookAdd To Yahoo
Hello people,

why look around for a pirated packet tracer. download the gns3 all in one, it is very beautiful and works like a charm in Vista. All your CCNA lab practice, building complex topologies and experiments can be done in GNS3 with drag and drop features. GNS3 works with a real cisco IOS image, so you get to practice each and every possible command.

Prereqs:
  • ->First get a Cisco IOS image file from any of your friends who own a cisco router.

Install Telnet client:
  • ->Open control panel/Programs/programs and feature OR just type "appwiz.cpl" in the RUN window and hit enter, that will open the 'programs and features' window
  • ->In this window, on the left panel click on 'Turn windows features on or off'
  • ->That will open 'windows features' window, in that tick mark the 'telnet client' and then click OK. It'll take some time to install the telnet client. Done with telnet client.
Now lets make sure if your telnet client is working: (courtesy: www.thundernews.com)
  • ->open command prompt.
  • ->type "telnet news.thundernews.com 119", hit enter, if you see 'welcome or connected' your telnet client is working.
  • -> If that didn't work you can try with these different port no.'s instead of 119, they are 119, 7000, 8000, 9000, 23, 25, 80, or 3128.
Now the stage is set, lets move on to installing GNS3:
  1. Download the gns3 all in one here
  2. Click on the downloaded file and run it (installation)
  3. I'd suggest to choose 4 options in the "components to install"
  4. After installation, type 'gns3' in windows start menu bar, click on it, opens gns3
  5. You get two options, click on 1
  6. In the window provide a working directory path, then click on 'test' button, you should see 'dynamips successfully started', then click apply and then ok.
  7. Now click on button 2, you'll get "IOS images and Hypervisors" window, in 'image file' section provide the path to Cisco IOS image on your computer. Then click OK and then apply. Depending on the IOS version, the platform and model fields gets automatically populated. Take note of the model. we're done.
Now we're at the GNS3 main window, lets make use of it.


  • Now, press Ctrl+Shift+Esc to open 'windows task manager' and minimise it.
  • In the left panel you can see all kinds of network devices. Drag a router model which your IOS supports, right click on it, click start.
  • From the 'windows task manager' you'll notice that your CPU usage goes upto 60% or even more. To fix this, right click on your router, click 'idle pc', let it calculate a value, choose any one from the list with '*' mark, see if your CPU usage drops down to somewhere around 10%, if not repeat this until it drops and dont forget to be patient for it is possible!
  • After that, right click on your router, choose 'console', that opens a telnet session to your router. This is as good as telnetting any real router so now you can use what you learned or do whatever.

Posted by Freeman On 12:37 PM 0 comments
Stumble ThisFav This With TechnoratiAdd To Del.icio.usDigg ThisAdd To RedditAdd To FacebookAdd To Yahoo

Blog Archive

Related Posts with Thumbnails

counter

HTML hit counter - Quick-counter.net
Copyright 2009 - tips .. come on in. Protected by Copyscape plagiarism checker - duplicate content and unique article detection software. Designed by Gaganpreet Singh