cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2348
Views
35
Helpful
7
Replies

PC can't access the internet through the Router--> Default Route isn't working

Vasconcelos
Level 1
Level 1

Good night, everyone, I'm learning network and I'm facing the problem bellow for hours. I'll rate the users who help

situation.png

 

 

Note: I'm using real equipment, used GNS3 for the Image. The Ports are specified on the image

 

PC

 IP--> 172.30.100.50

 Mask--> 255.255.255.0

 D.Gateway--> 172.30.100.1

 

Router

 Fa0/0

     IP--> 172.30.100.1

     Mask--> 255.255.255.0

 Fa0/1

     IP--> 192.168.0.11 (DHCP)

     Mask--> 255.255.255.0

Modem (ISP)

 IP-->192.168.0.1

 

 

I've issued the command "ip route 0.0.0.0 0.0.0.0 192.168.0.1"

 

From the PC, I can ping the Interface Fa0/0 and Fa0/1 of the Router, but I can't ping the Modem (ISP)

 

From the Router, I can ping the PC, both Interfaces of the Router and the Modem (ISP)

 

Since I can ping the Modem from the Router and I can ping the Interface Fa0/1 of the Router from the PC, the problem must be on the routing process

 

Router's Running-Config

 

Current configuration : 920 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
no network-clock-participate slot 1
no network-clock-participate wic 0
ip cef
!
!
!
!
ip auth-proxy max-nodata-conns 3
ip admission max-nodata-conns 3
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface FastEthernet0/0
ip address 172.30.100.1 255.255.255.0
duplex auto
speed auto
!
interface Serial0/0
no ip address
shutdown
!
interface FastEthernet0/1
ip address dhcp
duplex auto
speed auto
!
interface Serial0/1
no ip address
shutdown
!
ip forward-protocol nd
ip route 0.0.0.0 0.0.0.0 192.168.0.1
ip route 192.168.0.0 255.255.255.0 192.168.0.1
!
!
ip http server
no ip http secure-server
!
!
!
!
control-plane
!
!
!
!
!
!
!
!
!
!
line con 0
logging synchronous
line aux 0
line vty 0 4
login
!
!
end

 

3 Accepted Solutions

Accepted Solutions

Larry Sullivan
Level 3
Level 3

What happens if you NAT/PAT the PC IP to the Router's F0/1 interface IP?

View solution in original post

I think Larry is right. Your router can ping the modem, because it's on the same network subnet as the modem. The PC cannot ping the modem because you are attempting to route 172.30.100.x through the router, but the modem won't know about that subnet, so will not route the return traffic back to the router....it would use it's default route which points to the internet.

If you NAT the local network (172.30.100.x) behind the router using the Fa0/1 interface the router will know how to return that traffic.

View solution in original post

Hello,

 

for the sake of clarity, here is what the config should look like (important parts are in bold):

 

Current configuration : 920 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
no aaa new-model
no network-clock-participate slot 1
no network-clock-participate wic 0
ip cef
!
ip auth-proxy max-nodata-conns 3
ip admission max-nodata-conns 3
!
interface FastEthernet0/0
ip address 172.30.100.1 255.255.255.0
ip nat inside
duplex auto
speed auto
!
interface Serial0/0
no ip address
shutdown
!
interface FastEthernet0/1
ip address dhcp
ip nat outside
duplex auto
speed auto
!
interface Serial0/1
no ip address
shutdown
!
ip forward-protocol nd
ip route 0.0.0.0 0.0.0.0 FastEthernet0/1 dhcp
!
ip nat inside source list 1 interface FastEthernet0/1 overload
!
access-list 1 permit 172.30.100.0 0.0.0.255
!
ip http server
no ip http secure-server
!
control-plane
!
line con 0
logging synchronous
line aux 0
line vty 0 4
login
!
end

View solution in original post

7 Replies 7

Larry Sullivan
Level 3
Level 3

What happens if you NAT/PAT the PC IP to the Router's F0/1 interface IP?

By using the command traceroute on the Router, I can see that the Modem provided by my ISP is using a Private IP (192.168.0.1) and so is the next hop after it (10.x.x.x). Only after that the IPs begin to be Global with the IP 189.x.x.x

 

So, Doing NAT or PAT in the FA0/1 wouldn't work

I think Larry is right. Your router can ping the modem, because it's on the same network subnet as the modem. The PC cannot ping the modem because you are attempting to route 172.30.100.x through the router, but the modem won't know about that subnet, so will not route the return traffic back to the router....it would use it's default route which points to the internet.

If you NAT the local network (172.30.100.x) behind the router using the Fa0/1 interface the router will know how to return that traffic.

Globally routable address has nothing to do with it.  You can NAT private to private.  RJI covered exactly what I think the issue is.

Skywalker
Level 1
Level 1

True, i also side with Larry. Also, before testing from your PC, you should be able to ping the outside networks from the router while sourcing the ping from the LAN gateway.

Like;
ping 8.8.8.8 source 172.30.100.1

__
Regards,

Hello,

 

for the sake of clarity, here is what the config should look like (important parts are in bold):

 

Current configuration : 920 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
no aaa new-model
no network-clock-participate slot 1
no network-clock-participate wic 0
ip cef
!
ip auth-proxy max-nodata-conns 3
ip admission max-nodata-conns 3
!
interface FastEthernet0/0
ip address 172.30.100.1 255.255.255.0
ip nat inside
duplex auto
speed auto
!
interface Serial0/0
no ip address
shutdown
!
interface FastEthernet0/1
ip address dhcp
ip nat outside
duplex auto
speed auto
!
interface Serial0/1
no ip address
shutdown
!
ip forward-protocol nd
ip route 0.0.0.0 0.0.0.0 FastEthernet0/1 dhcp
!
ip nat inside source list 1 interface FastEthernet0/1 overload
!
access-list 1 permit 172.30.100.0 0.0.0.255
!
ip http server
no ip http secure-server
!
control-plane
!
line con 0
logging synchronous
line aux 0
line vty 0 4
login
!
end

Vasconcelos
Level 1
Level 1

Since I can't reply to everyone in just one message, I'll use this

 

Thanks, everyone. I've rated every post.