1

enter image description here I just configured PAT in a router but it doesn't work ,,

I write this commands in R1

    access-list 4 permit 172.16.0.0 0.0.255.255
    ip nat pool AdeNet 80.80.10.20 80.80.10.20 netmask 255.255.255.255
    ip nat inside source list 4 pool AdeNet overload

    int s0/0/0
ip address 172.16.15.21 255.255.255.252
    ip nat outside

    int s0/0/1
ip address 172.16.15.2 255.255.255.252
    ip nat inside

    int s0/1/0
ip address 172.16.15.10 255.255.255.252
    ip nat inside

    int s0/1/1
ip address 172.16.15.17 255.255.255.252
    ip nat inside

    int f0/0
ip address 172.16.0.150 255.255.248.0
    ip nat inside
    exit

Here are the ISP router ip address

int s0/0/0
ip address 172.16.15.22 255.255.255.252
int f0/0
ip address 10.10.1.1 255.255.0.0

80.80.10.20/32 is the public IP address for the NAT

These are the result of Show Run commands in 3 routers,, I hope it to be useful

ISP

FastEthernet0/0        10.10.1.1/16

Serial0/0/0            172.16.15.22/30

=========================================

R1

interface FastEthernet0/0
 ip address 172.16.0.150 255.255.248.0
 ip nat inside

interface FastEthernet0/1
 no ip address

interface FastEthernet0/1.10
 encapsulation dot1Q 10
 ip address 192.168.1.10 255.255.255.0

interface FastEthernet0/1.20
 encapsulation dot1Q 20
 ip address 192.168.2.10 255.255.255.0

interface FastEthernet0/1.30
 encapsulation dot1Q 30
 ip address 192.168.3.10 255.255.255.0

interface FastEthernet0/1.40
 encapsulation dot1Q 40
 ip address 192.168.4.10 255.255.255.0

interface Serial0/0/0
 ip address 172.16.15.21 255.255.255.252
 ip nat outside
 clock rate 2000000

interface Serial0/0/1
 ip address 172.16.15.2 255.255.255.252
 ip nat inside
 clock rate 64000

interface Serial0/1/0
 ip address 172.16.15.10 255.255.255.252
 ip nat inside
 clock rate 64000

interface Serial0/1/1
 ip address 172.16.15.17 255.255.255.252
 ip nat inside
 clock rate 64000

router ospf 12

 network 172.16.0.0 0.0.7.255 area 0
 network 172.16.15.0 0.0.0.3 area 0
 network 172.16.15.8 0.0.0.3 area 0
 network 172.16.15.16 0.0.0.3 area 0
 network 172.16.15.20 0.0.0.3 area 0
 network 192.168.0.0 0.0.7.255 area 0
exit
ip nat pool AdeNet 80.80.10.20 80.80.10.20 netmask 255.255.255.255
ip nat inside source list 4 pool AdeNet overload
ip route 0.0.0.0 0.0.0.0 Serial0/0/0 
access-list 4 permit 172.16.0.0 0.0.255.255
access-list 4 permit 192.168.0.0 0.0.7.255

=========================

R2

interface FastEthernet0/0
 ip address 172.16.8.150 255.255.252.0

interface Serial0/0/0
 ip address 172.16.15.1 255.255.255.252
 clock rate 2000000

interface Serial0/0/1
 ip address 172.16.15.5 255.255.255.252
 clock rate 64000

router ospf 12
 passive-interface FastEthernet0/0
 network 172.16.8.0 0.0.3.255 area 0
 network 172.16.15.0 0.0.0.3 area 0
 network 172.16.15.4 0.0.0.3 area 0

I ospf area 0 to conncet all WAN networks and connected,

and static routing between ISP and the R1 router and default routing between ISP and R1

so , is there any thing missing , that prevent WANs from connecting the internet

  • What is the config on the ISP router? Does it have a route to 80.80.10.20/32? What address are you trying to connect to? – Ron Trunk Mar 2 '15 at 18:18
  • Mr.@Mike Pennington & Mr. @Ron I need help ,please – user3423060 Mar 2 '15 at 21:26
  • does it work without nat? Can you ping 10.10.1.100 when NAT is turned off? What are the routes of the ISP router? – Ron Trunk Mar 2 '15 at 21:37
  • Now, only R1 can ping 10.10.1.100 other router can't ping ,, – user3423060 Mar 2 '15 at 22:05
  • this the result of : sh ip route in ISP router 10.0.0.0/16 is subnetted, 1 subnets C 10.10.0.0 is directly connected, FastEthernet0/0 80.0.0.0/32 is subnetted, 1 subnets S 80.80.10.20 is directly connected, Serial0/0/0 172.16.0.0/16 is variably subnetted, 2 subnets, 2 masks S 172.16.0.0/16 is directly connected, Serial0/0/0 C 172.16.15.20/30 is directly connected, Serial0/0/0 – user3423060 Mar 2 '15 at 22:07
1

Change the static routes on the ISP router to use the next hop address 172.16.15.21 instead of the interface.

| improve this answer | |
  • It doesn't work , still routers can't ping ISP router – user3423060 Mar 3 '15 at 7:12
  • Something is wrong with your configurations. Can you post the complete configs for ISP, R1 and one other router? – Ron Trunk Mar 3 '15 at 20:21
  • Well ,, I hope it a little bit clear ,now. – user3423060 Mar 3 '15 at 20:43
  • Please post all of the ISP router – Ron Trunk Mar 3 '15 at 20:50
  • I wrote only a static routing between ISP and R1 ip route 80.80.10.20 255.255.255.255 s0/0/0 – user3423060 Mar 3 '15 at 20:57
1

I write a default routing command in the R2 and it start ping to the ISP server ,, ip route 0.0.0.0 0.0.0.0 Serial0/0/0

may I should write in all other routers , still don't understand why !! while I'm using OSPF protocol between routers , except ISP router ..

| improve this answer | |
  • I should have seen that. Sorry. Your other routers don't know how to get to 10.10.1.0 because they don't have that route. You can add it to R1 by the command "default-information originate" under the ospf configuration. – Ron Trunk Mar 4 '15 at 2:26
  • Thank you so much Mr. @Ron I do understand now why , and thanks for this magic command "default-information originate" I like it , it better than writing command in all other router :)) ,, Thanks for giving me some of your time ^_^ – user3423060 Mar 4 '15 at 8:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.