09-20-2006 06:27 AM - edited 03-03-2019 02:03 PM
i have four adsl links terminating in a single 2811. i need help in configuring
load sharing/load balancing across these
4 links.a lil bit of configuration script would be a great help.
regards
09-20-2006 11:35 PM
Hello,
here is a sample configuration for 4 links on the same router configured for load balancing. At the bottom of this post, you can find a couple remarks regarding this configuration:
R1 Configuration
ip cef
!
interface FastEthernet0/1
ip address 192.168.1.1 255.255.255.0
ip nat inside
!
interface ATM0
no ip address
no ip route-cache
no atm ilmi-keepalive
dsl operating-mode auto
!
interface ATM0.1 point-to-point
no ip route-cache
pvc 0/38
encapsulation aal5mux ppp dialer
dialer pool-member 1
!
interface ATM0.2 point-to-point
no ip route-cache
pvc 0/38
encapsulation aal5mux ppp dialer
dialer pool-member 2
!
interface ATM0.3 point-to-point
no ip route-cache
pvc 0/38
encapsulation aal5mux ppp dialer
dialer pool-member 3
!
interface ATM0.4 point-to-point
no ip route-cache
pvc 0/38
encapsulation aal5mux ppp dialer
dialer pool-member 4
!
interface Dialer1
description ISP1_Connection_1
ip address dhcp
ip mtu 1452
encapsulation ppp
dialer pool 1
dialer-group 1
ppp authentication chap pap callin
ppp chap hostname USERNAME
ppp chap password 0 PASSWORD
ppp pap sent-username USERNAME password PASSWORD
!
interface Dialer2
description ISP1_Connection_2
ip address dhcp
ip mtu 1452
encapsulation ppp
dialer pool 2
dialer-group 1
ppp authentication chap pap callin
ppp chap hostname USERNAME
ppp chap password 0 PASSWORD
ppp pap sent-username USERNAME password PASSWORD
!
interface Dialer3
description ISP1_Connection_3
ip address dhcp
ip mtu 1452
encapsulation ppp
dialer pool 3
dialer-group 1
ppp authentication chap pap callin
ppp chap hostname USERNAME
ppp chap password 0 PASSWORD
ppp pap sent-username USERNAME password PASSWORD
interface Dialer4
description ISP1_Connection_4
ip address dhcp
ip mtu 1452
encapsulation ppp
dialer pool 4
dialer-group 1
ppp authentication chap pap callin
ppp chap hostname USERNAME
ppp chap password 0 PASSWORD
ppp pap sent-username USERNAME password PASSWORD
!
ip nat inside source route-map ISP1_Connection_1 interface Dialer1 overload
ip nat inside source route-map ISP1_Connection_2 interface Dialer2 overload
ip nat inside source route-map ISP1_Connection_3 interface Dialer3 overload
ip nat inside source route-map ISP1_Connection_4 interface Dialer4 overload
!
access-list 1 permit 192.168.1.0
!
route-map ISP1_Connection_1 permit 10
match ip address 1
match interface Dialer1
!
route-map ISP1_Connection_2 permit 10
match ip address 1
match interface Dialer2
!
route-map ISP1_Connection_3 permit 10
match ip address 1
match interface Dialer3
!
route-map ISP1_Connection_4 permit 10
match ip address 1
match interface Dialer4
!
ip route 0.0.0.0 0.0.0.0 Dialer1
ip route 0.0.0.0 0.0.0.0 Dialer2
ip route 0.0.0.0 0.0.0.0 Dialer3
ip route 0.0.0.0 0.0.0.0 Dialer4
!
dialer-list 1 protocol ip permit
The following applies:
- the use of four static routes will allow load-balancing over the four links and provide redundancy at the same time
- the NAT configuration will dynamically choose the NAT'ed address depending on which interface CEF has been chosen to send the packet out of
- enabling CEF with four default routes will by default load balance per-destination, which means for every source and destination address pair, CEF creates a hash and chooses one of the routes in the routing table.
- enabling CEF on a router will load balance outgoing traffic only, not incoming traffic. If your ISP uses Cisco, you could ask for the ISP to enable CEF on their end as well, which would result in inbound load balancing.
To verify load balancing, use the EXEC command:
sh ip cef 0.0.0.0
HTH,
GNT
09-21-2006 02:57 PM
hi thanks a lot for your reply man
okk i tried the config that u provided and it seems pretty good but there are some things that are different on my side
first of all on my router the atm interfaces appear as atm0/0/0,0/1/0,0/2/0,0/3/0 ( these are 4 adsl wics) and the router is not letting me create four point to point links under one physical interface.
so what i did was i created one point to point subinterface under each physical atm0/0/0 as atm0/0/0.1 point-to-point
atm0/1/0 as atm0/1/0.1 point-to-point
atm0/2/0 as atm0/2/0.1 point-to-point
atm0/3/0 as atm0/3/0.1 point-to-point
rest of the config was all the same as you provided.
now the interfaces on the router seem to have come up but the nat is not working.
and so i am not able to access internet from behind the router.
Please suggest if i need to change something in the nating part somewhere due to this difference of interfaces(i.e. atm0/0/0 instead of atm0)
Regards
09-22-2006 01:44 AM
Hello Wagar,
it might be easiest if you post the configuration of the router, maybe I can spot something. It shouldn't actually matter wether you use physical interfaces or point-to-point subinterfaces...
Regards,
GNT
09-22-2006 10:28 AM
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide