cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
5044
Views
0
Helpful
32
Replies

Dual Internet Link load-balancing,traffic from Outside Issue

rock981119
Level 1
Level 1

Hi All,

  We deploy Cisco Router 2921 at company edge, it has two internet link connect.

Gig0/0 was Fix Public IP:219.134.186.X

Gig0/1 was connect ADSL moden, dialer0 IP was dynamic.

TAC1.png

  Like the topology, we configure inside traffic load balance to internet, it is work well.

  But it has some issue from internet traffic to Router own interface address, If packet visit Gig0/0 Fix IP like "ping" or "ssh"

The router probable return packet from dialer0 IP.

  Router seemingly can't identify the fraffic which interface ingress and egress at the same interface. situation like this the router

can't provide some service on it own address. And idear?

  Some config file in attach.

----------

Rock.

32 Replies 32

rsimoni
Cisco Employee
Cisco Employee

can you elaborate wheat your wrote as I personally did not understand what your problem is

 If packet visit Gig0/0 Fix IP like "ping" or "ssh"

can you define 'visit'?

The router probable return packet from dialer0 IP.

can you elaborate giving a concrete example of the flow you are referring to (i.e. source and destination IP addresses, exit interface and interface traffic comes back from).

Router seemingly can't identify the fraffic which interface ingress and egress at the same interface.

uh?

situation like this the router can't provide some service on it own address. And idear?

sorry I did not get this either

  Like the Topology, traffic from internet, source can be any. For example public IP A.B.C.D ping the router Gig0/0:219.134.186.X.

The router may not reply packet on same-interface, it has some percent reply using Dialer0, cuz we config dual default route.

  If we wanna "ssh" or "IPSec" connect the router Gig0/0 IP, probable fail.

  Sorry, my english not well, hope you can understand.

As far as I know traffic coming from the CPU are always load-balanced per packets as they are necessarily process switched only .

Telent or SSH TO a router forces it to reply using IP process (process switching) hence the load balancing method will be per packets - no matter what you configure on your interface (I saw you disabled CEF switching to get fast-switching from the same interface - but this does not apply in your case).

The reply from the CPU does not come from g0/0 even though the IP address you are telnetting to is configured there, but from the RP engine (whatever model).

As a workaround I suppose you can try configure a static with longer prefix matching the Ip address range you are telnetting from; so in the RIB there will be only 1 possible path for such destination  - via g0/0 of course - and you will not have out-of-order packets.

Riccardo

You mean these not way resolve without config static route to which public ip wanna "ping" or "ssh" router Gig0/0?

But even config static with longer prefix matching, the remote public ip is come from any where, it hard to classify.
In china many inexpensive multi-wan router can do this, Cisco router don't have solution?

Hi,

as Riccardo already explained traffic generated by or destined to a router is always process-switched and process-switching is always doing per-packet load balancing so if you have 2 default routes with same AD, they will get both installed in the RIB and the router when generating packets will always load balance per-packet.

I don't think you can change this behaviour but if you don't need load-balancing for your data traffic then simply configure a higher AD for the second route and track first route  for failover.

Your problem will be solved as there will only be one default route installed in the RIB( the one with lower AD) and if it fails the other one will get installed.

Regards.

Alain

Don't forget to rate helpful posts.

Hi Zhi Yu Zang,

Yes, Cisco have a Solution for your SSH and ICMP Traffic destined to the Router.

  Just follow the below configuration and you should be good to go. I will be using (PBR) Policy Based Routing for your ICMP and SSH Traffic that is destined to you router G0/0 FIxed IP Interface as below:

Configuration:

interface G0/0

ip address 219.134.186.X 255.255.255.248

IP policy route-map SSH                          ------------------------------------------- Add this Configuration

Route-map SSH Permit 10

Match IP address 100

Set ip next-hop 219.134.186.97

 

access-list 100 permit tcp host 219.134.186.x eq 22 any               ------------------------------------- Add this configuration

access-list 100 permict icmp host 219.134.186.x eq echo-reply any ------------------------------------ Add this configuration

The Above should solve your problem, let me know if you still have problem.

Regards,

Mohamed

Mohamed, you say it works because you tried it or because you think it does?

In my opinion a PBR attach to the interface won't help as PBR is effective for traffic entering via that interface. In this case the traffic comes from the CPU.

However it would be interesting trying a local PBR for traffic sourced by the CPU.

ip local policy route-map SSH

since it is a local PBR you just enter it in global config mode (not attached to any interface).

Hi,

local PBR should be working indeed, how didn't  I think about it ? 

Regards.

Alain

Don't forget to rate helpful posts.

well... I did not think of that either 

Mohamed Sobair
Level 7
Level 7

Guys, Ricardo

Its not a thinking, its a logic and awarness. My example Should work. Let me explain further.

The Original Poster indicates traffic hits G0/0 interface is not routed back through the same interface but rather subject to the RIP decision which enforces the outgoing traffic to be loadbalanced. which results in a packet being frequently succeeded and dropped. and this is of course as we all know because the Second ISP will not accept prefixes that is not originated by the ISP itself, So dialer0 which points for an ISP, this ISP willnot accept traffic originating from G0/0 interface.

Now, Let us leave the CPU Ricardo, the problem here is because the router is consulting its routing table for deciding outgoing traffic which is indeed hits the CPU and then performs lookup at its RIP.

To Solve this issue, I have Suggested to implement PBR on the G0/0 interface itself, This means any traffic from the internet (Incoming Traffic) hits Interface G0/0 (which is the situation , as the OP originates ICMP and SSH traffic to G0/0) , this Traffic is Subject to Policy Based Routing Bypassing the Routing table which forwards the Traffic back through the Same Interface and this is the Objective of what the OP is looking for. He needs to SSH and ICP to that Interface and get the Traffic back without Drops.

So, My Solution should suffice with him. You Can Lab it UP and see the Result.

Regards,

Mohamed

i am still convinced that CPU generated traffic does not hit the standard PBR applied to any interface. this is why local PBR was introduced in the first place.

however let's see if our poster friend has some benefit out of it

Riccardo

Hi All,

  I don't think any PBR can solve the issue, Cuz PBR can't match traffic which interface coming from, it just can determine which interface out.

I think VRF would be help. We can put interface in each VRF:

Gig0/0--VRF1                 (add route "ip route vrf 1 0.0.0.0 0.0.0.0 gigabitEthernet 0/0 219.134.186.97")

Gig0/1(dialer0)--VRF2    (add route "ip route vrf 2 0.0.0.0 0.0.0.0 dialer0")

And add route in each VRF to inside subnet, sense can be solve, but config will so complex.

Just wanna know if it have simple method.

Hi,

PBR can ne for locally generated packets or packets entering an interface and its purpose is to not look into the RIB to forward the packet but choose either the outgoing interface or next-hop configured in the policy.

I don't understand how the vrf would solve your problem but I'd like to know why you think PBR won't and also if I understand the problem correctly you have a problem with return packets originated by your router in response to telnet, icmp or ssh ?  Is that so ?

Regards.

Alain

Don't forget to rate helpful posts.

Hi Alain,

  My english is crap, but i would like discuss with you. If you have time we can talk over on skype.

My accout:Rock981119.

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:

Innovations in Cisco Full Stack Observability - A new webinar from Cisco