cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
8744
Views
0
Helpful
72
Replies

Routing to the internet

wilsonleonardy
Level 1
Level 1

Hi, I'm new to Cisco router.

I've been asked to create a network for a hotel internet service.

I'm currently configuring Cisco 1941 (non-wireless), and I've been stuck for a while now.

So, I have 2 network

192.168.0.* (ethernet0/0) and 192.168.1.* (ethernet0/1)

i connect my modem to ethernet0/0 and the client switch to ethernet0/1

I manage to ping the modem from a client, and it's working great.

the problem is i couldn't get through the internet.

is there any configuration that i missed?

and also, is it possible to manage the bandwidth to the client?

Thanks.

72 Replies 72

Hi Alain,

I've tried pinging 8.8.8.8 and do the debug, here attached the log file you've asked, and it's not as long as the last one

And this is the ip static route config:

Gateway of last resort is 192.168.0.1 to network 0.0.0.0

S*    0.0.0.0/0 [1/0] via 192.168.0.1

S     192.168.1.0/24 is directly connected, GigabitEthernet0/0

---------

Regards,

Wilson

Hi,

I still don't see the packets sent from the PC  but only the icmp unreachables. that come from the soho router.

But there is something in your routing table that shouldn't be:

S*    0.0.0.0/0 [1/0] via 192.168.0.1

S     192.168.1.0/24 is directly connected, GigabitEthernet0/0

it should be a directly connected route  like this:

C     192.168.1.0/24 is directly connected, GigabitEthernet0/1

Can you post output of sh run | in ip route and a screenshot of the routes on the soho modem/router

Regards.

Alain.

Don't forget to rate helpful posts.

Alain,

Notice somewhere in the word document theres an attempted send packet to 8.8.8.8 from 192.168.1.11, that is from the pc

Here attached

1. running config

2. ip route

3. ip route from the soho router

Hi Wilson,

effectively I had missed those ones.

All the config are correct. Why is it not working? I'm gonna think it over one more time to see what troubleshooting we could do to find out why it is not working.

But I'm wondering how the output from the routing table became suddenly correct was it a typo when you first posted it?

Regards.

Alain

Don't forget to rate helpful posts.

Hi Alain,

The current situation is almost the same as our situation a few days ago where it was possible to ping to anywhere from anywhere in the network but impossible to ping to the internet through any of the interfaces (g0/0 and g0/1) but this problem was solved with the "ip route 0.0.0.0 0.0.0.0 192.168.0.1" command, that command allows interface g0/0 to ping to any outside network. g0/1 on the other hand still unable to ping to the internet.

However it is still possible to ping to anywhere locally from the g0/1 network, just not the internet.

the previously incorrect routing table output posted to you was caused by my trial and error that i forgot to undo. I undid it just before I posted the most recent show config, and ip routing table output to you.

Could this have anything with bridging/tunneling/loopbacking between g0/0 and g0/1 ?

Also, what about the ip default-network or ip default-gateway command?

cheers

Wilson

Wilson / Alain

Apologies for jumping in as i don't want to cause any confusion but i suspect after reading the thread that the issue may be, as already suggested, that the modem is only natting for it's own local subnet. Could you, as Alain has already mentioned, try adding this to your 1941 config and retest -

int gi0/0

ip nat outside

int gi0/1

ip nat inside

access-list 101 permit ip 192.168.1.0 0.0.0.255 any

ip nat inside source list 101 interface gi0/0 overload

and then retest from a PC in the 192.168.1.x network (not the router itself).

Alternatively adding a route for the 192.168.1.0/24 network to the modem pointing to 192.168.0.2 would also be an option but not sure how easy this would be to do.

Can you try the above and retest.

Jon

Hi jon,

thanks for trying to help us out of this mayhem.

This puzzling me because on some other model of soho modem/router I already did this kind of setup and it wasn't needed to do the NAT on the Cisco device and a simple route to the source subnet on the modem did the trick but apparently not here.

If I recall Wilson did begin with natting on Cisco but I don't know if he tried the correct setting you posted, in fact it would be great indeed to try it out while leaving the route on the modem.

Looking forward for your opinion.

Regards.

Alain

Don't forget to rate helpful posts.

Jon & Alain

I THINK I did try your proposed solution, but I can't recall anymore. I'll try it once more, but I'm more inclined to believe that it isnt a nat problem, because it is still possible to ping to the internet using the g0/0 interface.

I tried "ip route 192.168.1.0 255.255.255.0 g0/0" instead of "ip route 192.168.1.0 255.255.255.0 192.168.0.2" because putting 192.168.0.2 gave me an error saying something like 192.168.0.2 is an ip address from this router hence disabling it from routing to itself from itself. on the other hand ip route 192.168.1.0 255.255.255.0 g0/0 command gave no result.

I'll try the nat again just to be sure. Darn. I only have 4 days left before this project is due.After this internet routing part is done, I'll still have two major things to do for this project:

1. routing the internet connection from g0/1 to wireless access point attached to the g0/1 interface through a network switch

2. making sure the dhcp from 192.168.1.0 network works on 120 clients.

Thanks for the support through this mayhem for the last week or so.

Wilson

Hi Wilson,

a static route pointing to a multipoint interface should never be configured, you must use the next-hop IP in this case so indeed the IP adress of the router on the other end which is in the same subnet.

So ip route 192.168.1.0 255.255.255.0 g0/0 is not correct and you don't have to do this on the cisco router the only static route on the cisco router must be the default route pointing to your modem so 192.168.0.1

The route to 192.168.1.0 must be on the modem and also using the next-hop not the interface even though it could work here because the Cisco router is doing proxy-arp but it is highly discouraged to do so.

If you have the correct routes on both devices and the correct gateway on the PC and if even with NAT on the Cisco device it is still not working then I have no idea what could be the problem.

But I just noticed something in the debug logs, you have icmp type 3 which is destination unreachable but code 3 which is

Port unreachable error.

This is sent when the designated transport protocol is unable to demultiplex  the datagram but has no protocol mechanism to inform the sender. But here you just did an icmp so there is no port involved,I wonder if this is not a symptom of the NAT problem or something else I really can't think of.

Concerning the 120 IP from DHCP as you have a /24 it should be no problem but choose your lease time carefully especially for the wireless devices.

Regards.

Alain

Don't forget to rate helpful posts.

Wilson

You are basically right, it is a routing problem. You can ping the internet from the gi0/0 interface because the modem and the gi0/0 interface are in the same subnet so the modem knows where to send the return traffic from the internet to.

But when you ping from a 192.168.1.x address the modem does not appear to know where this network is. So you have 2 options -

1) add a static route to the modem to tell it where to send the return packets ie. in on a cisco router it would look like -

ip route 192.168.1.0 255.255.255.0 192.168.0.2 

however i don't know how or whether this is possible on the modem. If you already have that route then simply try pinging from the modem to a PC or the gi0/1 interface on your router - does it work ?

If you can't add the route then -

2) the other option is to use natting to hide all the 192.168.1.x addresses to the gi0/0 IP address. Then the modem knows where to send the return traffic to. So in this case we are really only using nat on the router so the modem knows how to route the traffic back.

Like i say, a simple test to see if we are on the right lines is from the modem try and ping any 192.168.1.x address and see if it works.

Jon

Hi Jon,

he's already got that route to the 192.168.1.0 network on the modem. But what do you think about the icmp type 3 code 3,

it should be code 0 or 1 but not 3? What is your opinion about it?

Regards.

Alain

Don't forget to rate helpful posts.

I'm sorry but the static route setting from the soho router I posted before was incomplete. This is the whole routing table from the soho router

Alain & Jon,

It turns out Jon is correct. The problem holding us back was the NAT, once I inputted the NAT setting it works like a charm.

Everything works now.

The internet connection I'm going to be connecting to the router is a 2mbps connection. It's one of the best available connection here in Indonesia. So if possible, I'd like to manage the amount of bandwidth available to each client so one client with a heavy traffic won't slow down another client's connection.

Also, I'd like to apply some website blocking/filtering so resource hungry website cant be accessed.

Thanks heaps for all the supports, advices and help from all of you.

Wilson

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card