[Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3 - vozForums
vozForums
Go Back   vozForums > Đại sảnh > Review sản phẩm
Reply
 
Thread Tools
  #1  
Old 14-08-2019, 10:59
babyangelhp babyangelhp is offline
Senior Member
 
Join Date: 09-2010
Location: Đâu đó quanh đây
Posts: 175
[Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Trang chủ nhà SX:
https://mikrotik.com/product/RB750Gr3

E gà nên chỉ viết sơ qua thế thôi, các thím vào đây chia sẻ hiệu năng và cách sử dụng, các tính năng chuyên sâu về e nó nhé
Bổ xung 1 trang web hay các bác chỉ việc nhập theo ý mình và sẽ tự động config hoàn toàn cho các thím 1 số chức năng như FireWall Config, QOS, Loadbancing 2 wan hoặc 3 wan
https://mikrotikconfig.com

Cân bằng tải 4 Wan :
Code:
# IP Addresses for reference purpose
/ip address
add address=192.168.0.1/24 network=192.168.0.0 broadcast=192.168.0.255 interface=Local
add address=192.168.1.2/24 network=192.168.1.0 broadcast=192.168.1.255 interface=WAN1
add address=192.168.2.2/24 network=192.168.2.0 broadcast=192.168.2.255 interface=WAN2
add address=192.168.3.2/24 network=192.168.3.0 broadcast=192.168.3.255 interface=WAN3
add address=192.168.4.2/24 network=192.168.4.0 broadcast=192.168.4.255 interface=WAN4
 
# Add NET ALLOWED users Address list, to make sure only allowed users get internet access. Make sure to modify this as per your requirements, we can use this list later for other management purposes
 
/ip firewall address-list
add address=192.168.0.1-192.168.0.255 list=allowed_users
 
# Accept Connections
/ip firewall mangle
add action=accept chain=prerouting in-interface=WAN1
add action=accept chain=prerouting in-interface=WAN2
add action=accept chain=prerouting in-interface=WAN3
add action=accept chain=prerouting in-interface=WAN4
 
# Mangle Section
# Marking connections for 4 dsl distribution
add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:4/0 action=mark-connection new-connection-mark=WAN1_conn passthrough=yes src-address-list=allowed_users
add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:4/1 action=mark-connection new-connection-mark=WAN2_conn passthrough=yes src-address-list=allowed_users
add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:4/2 action=mark-connection new-connection-mark=WAN3_conn passthrough=yes src-address-list=allowed_users
add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:4/3 action=mark-connection new-connection-mark=WAN4_conn passthrough=yes src-address-list=allowed_users
 
# Marking Routing Marks to be used by ROUTES Section
add chain=prerouting connection-mark=WAN1_conn in-interface=Local action=mark-routing new-routing-mark=to_WAN1
add chain=prerouting connection-mark=WAN2_conn in-interface=Local action=mark-routing new-routing-mark=to_WAN2
add chain=prerouting connection-mark=WAN3_conn in-interface=Local action=mark-routing new-routing-mark=to_WAN3
add chain=prerouting connection-mark=WAN4_conn in-interface=Local action=mark-routing new-routing-mark=to_WAN4
 
# Adding ROUTE for marked routes (done by mangle earlier)
/ip route
add dst-address=0.0.0.0/0 gateway=192.168.1.1 routing-mark=to_WAN1 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.2.1 routing-mark=to_WAN2 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.3.1 routing-mark=to_WAN3 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.4.1 routing-mark=to_WAN4 check-gateway=ping
 
# DEFAULT ROUTES, OR Fail over routes , just incase in any router goes offline, then these default routes as per distance, will be used as default
add dst-address=0.0.0.0/0 gateway=192.168.1.1 distance=1 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.2.1 distance=2 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.3.1 distance=3 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.4.1 distance=4 check-gateway=ping
 
# NAT/MASQUERADE the requests going on each interface (used by ROUTES)
/ip firewall nat
add chain=srcnat out-interface=WAN1 action=masquerade src-address-list=allowed_users
add chain=srcnat out-interface=WAN2 action=masquerade src-address-list=allowed_users
add chain=srcnat out-interface=WAN3 action=masquerade src-address-list=allowed_users
add chain=srcnat out-interface=WAN4 action=masquerade src-address-list=allowed_users
E bổ xung các cách cân bằng tải của thằng Mikrotik cho ae tham khảo :
Kiểu 1 : chỉ cân bằng tải ko gộp băng thông
Code:
/ip firewall mangle

add action=mark-connection chain=input disabled=no in-interface=vnpt1 \
    new-connection-mark=to_vnpt1 passthrough=yes
add action=mark-connection chain=input disabled=no in-interface=vnpt2 \
    new-connection-mark=to_vnpt2 passthrough=yes

	
add action=mark-connection chain=prerouting connection-mark=no-mark disabled=\
    no in-interface=vnpt1 new-connection-mark=to_vnpt1 passthrough=yes
add action=mark-connection chain=prerouting connection-mark=no-mark disabled=\
    no in-interface=vnpt2 new-connection-mark=to_vnpt2 passthrough=yes


add action=mark-connection chain=prerouting connection-mark=no-mark disabled=\
    no dst-address-type=!local in-interface=LAN new-connection-mark=\
    to_vnpt1 passthrough=yes per-connection-classifier=both-addresses:2/0
add action=mark-connection chain=prerouting connection-mark=no-mark disabled=\
    no dst-address-type=!local in-interface=LAN new-connection-mark=\
    to_vnpt2 passthrough=yes per-connection-classifier=both-addresses:2/1


add action=mark-routing chain=prerouting connection-mark=to_vnpt1 disabled=\
    no in-interface=LAN new-routing-mark=to_vnpt1 passthrough=yes
add action=mark-routing chain=prerouting connection-mark=vnpt6_conn disabled=\
    no in-interface=LAN new-routing-mark=to_vnpt6 passthrough=yes

add action=mark-routing chain=output connection-mark=to_vnpt1 disabled=no \
    new-routing-mark=to_vnpt1 passthrough=yes
add action=mark-routing chain=output connection-mark=to_vnpt2 disabled=no \
    new-routing-mark=to_vnpt2 passthrough=yes


/ip firewall nat
add action=masquerade chain=srcnat disabled=no out-interface=vnpt1
add action=masquerade chain=srcnat disabled=no out-interface=vnpt2



/ip route
add check-gateway=ping disabled=no distance=1 dst-address=0.0.0.0/0 gateway=\
    vnpt1 routing-mark=to_vnpt1 scope=30 target-scope=10
add check-gateway=ping disabled=no distance=1 dst-address=0.0.0.0/0 gateway=\
    vnpt2 routing-mark=to_vnpt2 scope=30 target-scope=10
Kiểu 2 : Cân Bằng tải, Gộp băng thông download
Code:
/ip firewall mangle
add action=mark-connection chain=prerouting disabled=no in-interface=Lan_eth \
    new-connection-mark=to_vnpt1 passthrough=yes
add action=mark-connection chain=prerouting disabled=no in-interface=Lan_eth \
    new-connection-mark=to_vnpt2 passthrough=yes


add action=mark-routing chain=prerouting disabled=no in-interface=Lan_eth \
    new-routing-mark=to_vnpt1 passthrough=yes src-address-list=to_vnpt1
add action=mark-routing chain=prerouting disabled=no in-interface=Lan_eth \
    new-routing-mark=to_vnpt2 passthrough=yes src-address-list=to_vnpt2


add action=mark-connection chain=prerouting connection-state=new disabled=no \
    in-interface=Lan_eth new-connection-mark=to_vnpt1 nth=2,1 passthrough=yes
add action=mark-connection chain=prerouting connection-state=new disabled=no \
    in-interface=Lan_eth new-connection-mark=to_vnpt2 nth=2,2 passthrough=yes


add action=add-src-to-address-list address-list=to_vnpt1 address-list-timeout=\
    1d chain=prerouting connection-mark=to_vnpt1 disabled=no in-interface=\
    Lan_eth
add action=add-src-to-address-list address-list=to_vnpt2 address-list-timeout=\
    1d chain=prerouting connection-mark=to_vnpt2 disabled=no in-interface=\
    Lan_eth


add action=mark-routing chain=prerouting connection-mark=to_vnpt1 disabled=no \
    in-interface=Lan_eth new-routing-mark=to_vnpt1 passthrough=yes
add action=mark-routing chain=prerouting connection-mark=to_vnpt2 disabled=no \
    in-interface=Lan_eth new-routing-mark=to_vnpt2 passthrough=yes


/ip firewall nat
add action=masquerade chain=srcnat disabled=no out-interface=vnpt1
add action=masquerade chain=srcnat disabled=no out-interface=vnpt2


/ip route
add check-gateway=ping disabled=no distance=1 dst-address=0.0.0.0/0 gateway=\
    vnpt1 routing-mark=to_vnpt1 scope=30 target-scope=10
add check-gateway=ping disabled=no distance=1 dst-address=0.0.0.0/0 gateway=\
    vnpt2 routing-mark=to_vnpt2 scope=30 target-scope=10
Kiểu 3 : Cân bằng tải, Gộp băng thông download và upload
Code:
/ip firewall mangle
add action=mark-connection chain=input disabled=no in-interface=vnpt1 \
    new-connection-mark=to_vnpt1 passthrough=yes
add action=mark-connection chain=input disabled=no in-interface=vnpt2 \
    new-connection-mark=to_vnpt2 passthrough=yes
add action=mark-routing chain=output connection-mark=to_vnpt1 disabled=no \
    new-routing-mark=to_vnpt1 passthrough=yes
add action=mark-routing chain=output connection-mark=to_vnpt2 disabled=no \
    new-routing-mark=to_vnpt2 passthrough=yes
add action=accept chain=prerouting disabled=no dst-address=192.168.0.0/24 \
    in-interface=Lan_eth
add action=mark-connection chain=prerouting disabled=no dst-address-type=\
    !local in-interface=Lan_eth new-connection-mark=to_vnpt1 passthrough=yes \
    per-connection-classifier=both-addresses-and-ports:2/0
add action=mark-connection chain=prerouting disabled=no dst-address-type=\
    !local in-interface=Lan_eth new-connection-mark=to_vnpt2 passthrough=yes \
    per-connection-classifier=both-addresses-and-ports:1/1
add action=mark-routing chain=prerouting connection-mark=to_vnpt1 disabled=no \
    in-interface=Lan_eth new-routing-mark=to_vnpt1 passthrough=yes
add action=mark-routing chain=prerouting connection-mark=to_vnpt2 disabled=no \
    in-interface=Lan_eth new-routing-mark=to_vnpt2 passthrough=yes


/ip firewall nat
add action=masquerade chain=srcnat disabled=no out-interface=vnpt1
add action=masquerade chain=srcnat disabled=no out-interface=vnpt2


/ip route
add check-gateway=ping disabled=no distance=1 dst-address=0.0.0.0/0 gateway=\
    vnpt1 routing-mark=to_vnpt1 scope=30 target-scope=10
add check-gateway=ping disabled=no distance=2 dst-address=0.0.0.0/0 gateway=\
    vnpt2 routing-mark=to_vnpt2 scope=30 target-scope=10
Made in Latvia

Mikrotik RouterBOARD hEX (RB750Gr3):
- Là mộ bộ định tuyến với 5 cổng Ethernet 1G.
- Mang đầy đủ các tính năng RouterOS: Định tuyến, hostpot gateway, firewall,
- Mikrotik hEX còn là bộ định tuyến có khả năng MPLS
- hEX là sự kết hợp về giá cả và tính năng, với thiết kế nhỏ gọn, thẩm mỹ và dễ sử dụng phù hợp với bất kỳ môi trường SOHO nào
- Hỗ trợ chức năng POE in
Cấu hình:

Details
Product code RB750Gr3
Architecture MMIPS
CPU MT7621A
CPU core count 2
CPU nominal frequency 880 MHz
CPU Threads count 4
Dimensions 113x89x28mm
License level 4
Operating System RouterOS
Size of RAM 256 MB
Storage size 16 MB
Storage type FLASH
Tested ambient temperature -40°C to 60°C
Suggested price $59.95

- Hỗ trợ VLAN, chia LAN subnet:
- Chặn từ khóa và tên miền trong
- VPN (PPPT, IPsec ...):
- Định tuyến động (RIP, OSPF ...):

Một vài hình ảnh em nó :









Last edited by babyangelhp; Yesterday at 09:47.
Reply With Quote
  #2  
Old 14-08-2019, 11:03
tmk1207 tmk1207 is offline
Senior Member
 
Join Date: 09-2009
Location: Thỉnh thoảng tớ cũng biết dịu dàng .................
Posts: 3,756
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Vãi thôi bổ sung cái ảnh.



https://aacable.wordpress.com/2011/0...cript-by-zaib/
Reply With Quote
  #3  
Old 14-08-2019, 11:04
manny1992003 manny1992003 is offline
Senior Member
 
Join Date: 07-2006
Posts: 1,027
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Bác viết luôn cách làm sao có được như cái hình speedtest đó với.
Reply With Quote
  #4  
Old 14-08-2019, 11:10
babyangelhp babyangelhp is offline
Senior Member
 
Join Date: 09-2010
Location: Đâu đó quanh đây
Posts: 175
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Quote:
Originally Posted by tmk1207 View Post
e tưởng thím lấy con Edge Router mà , vẫn lấy mikrotik àh
Reply With Quote
  #5  
Old 14-08-2019, 11:31
tmk1207 tmk1207 is offline
Senior Member
 
Join Date: 09-2009
Location: Thỉnh thoảng tớ cũng biết dịu dàng .................
Posts: 3,756
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Quote:
Originally Posted by babyangelhp View Post
e tưởng thím lấy con Edge Router mà , vẫn lấy mikrotik àh
Nguồn ở trong ảnh kìa bác
Reply With Quote
  #6  
Old 14-08-2019, 11:44
babyangelhp babyangelhp is offline
Senior Member
 
Join Date: 09-2010
Location: Đâu đó quanh đây
Posts: 175
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Quote:
Originally Posted by tmk1207 View Post
Nguồn ở trong ảnh kìa bác
hehe, nãy ko thấy cái nguồn, tưởng bác lại chơi thêm con mikrotik nữa
Reply With Quote
  #7  
Old 14-08-2019, 11:56
casabala casabala is online now
Senior Member
 
Join Date: 11-2011
Location: Lầu ông hoàng
Posts: 210
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Xài qua nhiều dòng nổi tiếng nhưng phải nói rất thích Mikrotik và đã dừng hẳn ở sản phẩm này..........
Reply With Quote
  #8  
Old 14-08-2019, 12:13
tmk1207 tmk1207 is offline
Senior Member
 
Join Date: 09-2009
Location: Thỉnh thoảng tớ cũng biết dịu dàng .................
Posts: 3,756
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Quote:
Originally Posted by babyangelhp View Post
hehe, nãy ko thấy cái nguồn, tưởng bác lại chơi thêm con mikrotik nữa
Thấy ông để cái tít là 4 wan nên kiếm tạm google bổ sung thôi
Reply With Quote
  #9  
Old 14-08-2019, 12:13
ppptran ppptran is offline
Senior Member
 
Join Date: 05-2018
Posts: 1,203
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Quote:
Originally Posted by casabala View Post
Xài qua nhiều dòng nổi tiếng nhưng phải nói rất thích Mikrotik và đã dừng hẳn ở sản phẩm này..........
Chuẩn.

Được làm thep ý mình thoải mái.
Reply With Quote
  #10  
Old 14-08-2019, 12:40
anicedoll123 anicedoll123 is offline
Senior Member
 
Join Date: 07-2012
Posts: 157
Re: [Quick Review] Cân bằng tải 4 wan với Mikrotik RB750gr3

Hóng topic này lâu lắm bây h mới có. 5 xao
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +7. The time now is 16:30.
Steam Powered by vBulletin® 0.1 pre-alpha
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.