Community discussions

 
mshahid85
newbie
Topic Author
Posts: 26
Joined: Thu Mar 01, 2018 12:19 pm

Dual Wan configuration on same switch

Tue Aug 20, 2019 2:46 pm

Hi,

I am using mikrotik router hEX Lite and i want to configure dual wan on it. One ISP is PPPoe and other is Static live ip. i want to configure dual wan with 1 LAN 192.168.10./24.
i do not want to configure any load balancing on it. just want to run dual wans on same LAN. i do not want to use DHCP server, i want to share my ip with manual services, so please just tell me how to configure this type of router.


Regard,,,

Mshahid85
 
anav
Forum Guru
Forum Guru
Posts: 3122
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada

Re: Dual Wan configuration on same switch

Tue Aug 20, 2019 4:54 pm

That is not all that unusual. The router from defaults should be good to go for your purposes for one LAN.
You simply need to add the second WAN.
Post a config when you have progressed.
/export hide-sensitive file=yourconfig20Aug
I'd rather manage rats than software. Follow my advice at your own risk! (Sob & mkx forced me to write that!)
 
mshahid85
newbie
Topic Author
Posts: 26
Joined: Thu Mar 01, 2018 12:19 pm

Re: Dual Wan configuration on same switch

Thu Aug 22, 2019 1:29 pm

That is not all that unusual. The router from defaults should be good to go for your purposes for one LAN.
You simply need to add the second WAN.
Post a config when you have progressed.
/export hide-sensitive file=yourconfig20Aug
Let me explain what i want>>> my router have 5 ports,

i want to set port 1 for WAN-01 static IP
Router IP and Gateway = 10.1.1.1

Port 2 want to set for WAN-02 pppoe
Router IP and Gateway = 192.168.1.1

now port 5 want to set for LAN
for both WAN connection distribute internet on this LAN IP 192.168.20.0/24

like, i want to set WAN-1 ip for internet is 192.168.20.50
and want to set WAN-2 ip for internet is 192.168.20.100

just switch the gateway and shift my internet (50 to 100 or 100 to 50)

hope you will understand what i want,
now tell me how to configure it in mikrotik router???

Thanks,,

Mshahid
 
Exiver
Member Candidate
Member Candidate
Posts: 113
Joined: Sat Jan 10, 2015 6:45 pm

Re: Dual Wan configuration on same switch

Thu Aug 22, 2019 2:28 pm

Please dont forget that people here are spending their free time to support other users and - in this case - you. So you cannot really demand that people will tell you "how to configure your router properly", but you may ask for help.

As anav has stated: This setup is not that uncommon and could be done with reading a little bit in the mikrotik wiki:
https://wiki.mikrotik.com/wiki/Main_Page


To give you some points where to start:

- Setup Address-Lists where you can add your clients to list "wan1" or "wan2"

/ip firewall address-list
add name=wan1 address=192.168.20.50
add name=wan1 address=192.168.20.51
add name=wan2 address=192.168.20.100
add name=wan2 address=192.168.20.101
(and so forth)

- Mark routing for the specific ips you want to send out via wan1 or wan2:

/ip firewall mangle
add chain=prerouting action=mark-routing new-routing-mark=wan1 src-address-list=wan1
add chain=prerouting action=mark-routing new-routing-mark=wan2 src-address-list=wan2

- Setup routes for both WANs

/ip route
add distance=0 routing-mark=wan1 gateway=10.1.1.1 dst-address=0.0.0.0/0
add distance=0 routing-mark=wan2 gateway=192.168.1.1 dst-address=0.0.0.0/0
 
mshahid85
newbie
Topic Author
Posts: 26
Joined: Thu Mar 01, 2018 12:19 pm

Re: Dual Wan configuration on same switch

Fri Aug 23, 2019 7:50 am

Please dont forget that people here are spending their free time to support other users and - in this case - you. So you cannot really demand that people will tell you "how to configure your router properly", but you may ask for help.

As anav has stated: This setup is not that uncommon and could be done with reading a little bit in the mikrotik wiki:
https://wiki.mikrotik.com/wiki/Main_Page


To give you some points where to start:

- Setup Address-Lists where you can add your clients to list "wan1" or "wan2"

/ip firewall address-list
add name=wan1 address=192.168.20.50
add name=wan1 address=192.168.20.51
add name=wan2 address=192.168.20.100
add name=wan2 address=192.168.20.101
(and so forth)

- Mark routing for the specific ips you want to send out via wan1 or wan2:

/ip firewall mangle
add chain=prerouting action=mark-routing new-routing-mark=wan1 src-address-list=wan1
add chain=prerouting action=mark-routing new-routing-mark=wan2 src-address-list=wan2

- Setup routes for both WANs

/ip route
add distance=0 routing-mark=wan1 gateway=10.1.1.1 dst-address=0.0.0.0/0
add distance=0 routing-mark=wan2 gateway=192.168.1.1 dst-address=0.0.0.0/0


first of all it wasnt mean that all members are my servant, they doing there job as a volunteer free of cost, so i really respect them and it wasn't demand it was just a request, i forgot to mention request so if they get hurt then i apology for that, really excuse for my wording.... because i really respect all those persons who works for humanity.....

So please tell me why my LAN IP pool is not mention in my routing ??
0.0.0.0/0??
and i have read somewhere that port 3 and 4 is not good for LAN, so use port 5 for your LAN. is it so???

i m new in mikrotik so please help,,,
 
Exiver
Member Candidate
Member Candidate
Posts: 113
Joined: Sat Jan 10, 2015 6:45 pm

Re: Dual Wan configuration on same switch

Fri Aug 23, 2019 12:17 pm

The logic behind my example is that you add different clients to different named address lists (wan1 and wan2). Afterwards you mark all packets coming from addresses on list wan1 with a wan1-routing mark. The same is done to addresses from list wan2. Afterwards you can define which upstream should take care of addresses from list wan1 or wan2. Its a much more easy option to setup multiple clients - if you would have only two clients in your network your mangle rule could look like this (and you wouldnt need the address list):

/ip firewall mangle
add chain=prerouting action=mark-routing new-routing-mark=wan1 src-address=192.168.20.50
add chain=prerouting action=mark-routing new-routing-mark=wan2 src-address=192.168.20.100

Who is online

Users browsing this forum: No registered users and 35 guests