cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
619
Views
0
Helpful
5
Replies

Static Routes for load balancing

sophaunsim
Level 1
Level 1

I have 2 ISP links to my router how can i config the load balancing? Can u send me example command for load balancing?

5 Replies 5

ekhoo
Level 1
Level 1

sophaunsim,

You can configure two equal cost static route for load balancing. see example below.

ip route 0.0.0.0 0.0.0.0 XX.XX.XX.XX name ISP-1

ip route 0.0.0.0 0.0.0.0 XX.XX.XX.XX name ISP-2

However, your ISP may only allow traffic coming from the ip address they allocated for you. Any ip address from other ISP may get block.

what cost static route can you explance me?

Thanks,

By default, static route with next hop ip address and connected to local interface have admin distace of 1 and cost/metric of 0 as you can see from the sh ip route output below.

the defaul route has two entries 10.10.10.2 and 20.20.20.2

Router#sh ip route

[deleted]

20.0.0.0/24 is subnetted, 1 subnets

C 20.20.20.0 is directly connected, GigabitEthernet0/1

10.0.0.0/24 is subnetted, 1 subnets

C 10.10.10.0 is directly connected, GigabitEthernet0/0

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

[1/0] via 10.10.10.2

As you can see the traffic share count is 1. this mean router is using equal cost load balance between two ISPs. .

Router#sh ip route 0.0.0.0

Routing entry for 0.0.0.0/0, supernet

Known via "static", distance 1, metric 0, candidate default path

Routing Descriptor Blocks:

20.20.20.2

Route metric is 0, traffic share count is 1

* 10.10.10.2

Route metric is 0, traffic share count is 1

sample config

!

!

!

interface GigabitEthernet0/0

ip address 10.10.10.1 255.255.255.0

duplex auto

speed auto

!

interface GigabitEthernet0/1

ip address 20.20.20.1 255.255.255.0

duplex auto

speed auto

!

!

ip classless

ip route 0.0.0.0 0.0.0.0 10.10.10.2 name ISP-1

ip route 0.0.0.0 0.0.0.0 20.20.20.2 name ISP-2

!

Router#sh ip route

Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

E1 - OSPF external type 1, E2 - OSPF external type 2

i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2

ia - IS-IS inter area, * - candidate default, U - per-user static route

o - ODR, P - periodic downloaded static route

Gateway of last resort is 20.20.20.2 to network 0.0.0.0

20.0.0.0/24 is subnetted, 1 subnets

C 20.20.20.0 is directly connected, GigabitEthernet0/1

10.0.0.0/24 is subnetted, 1 subnets

C 10.10.10.0 is directly connected, GigabitEthernet0/0

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

[1/0] via 10.10.10.2

I ready to configured follow that you explance me so how can I test connections? because I don't know it is work realy or not.

Hi,

Execute "show interface [interface-id]" in the router for both interface connecting to your two ISP.

You should see TXLOAD and RXLOAD for both.

Regards,

Dandy

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: