vara separating two internet line in a Mikrotik Router Wireless router-proxy

with 2 modems we separate his path in mikrotik for each computer that you specify in a network ..

Topology:
Modem
Modem1 = 192.168.1.1
Modem2 = 192.168.9.1

Mikrotik
Eth1 = 192.168.1.2
Eth2 = 192.168.9.16
Eth3 = 192.168.3.1

Client Computers
Client1 = 192.168.3.2 ---- On To navigate Modem1
Client2 = 192.168.3.3 ---- On To navigate Modem2

Let's get started:

The first step is to name each interface on mikrotik, with the command "New Terminal":

/ Interface set 0 name = public-modem1
/ Interface set 1 name = public-modem2
/ Interface set 2 name = local-client

Furthermore, given ip to ethernet in mikrotik, with the command:

/ Ip address add address = 192.168.1.2 \
netmask = 255.255.255.0 \
interface = public-modem1

/ Ip address add address = 192.168.9.16 \
netmask = 255.255.255.0 \
interface = public-modem2

/ Ip address add address = 192.168.3.1 \
netmask = 255.255.255.0 \
interface = local-client


Next enter the DNS, adjust your dns masing2, with the command:

/ Ip set dns servers = 203.130.193.74,203.130.206.250 \
allow-remote-requests = yes

then enter the ip route modem1, modem2 along with its routing mark:

/ Ip route add gateway = 192.168.1.1
/ Ip route add gateway = 192.168.1.1 routing-mark = MODEM1

/ Ip route add gateway = 192.168.9.1
/ Ip route add gateway = 192.168.1.1 routing-mark = MODEM2

Next enter the IP NAT firewall for each modem with action masquerade, printahnya:

/ Ip firewall nat add chain = srcnat \
out-interface = public-modem1 \
action = masquerade

/ Ip firewall nat add chain = srcnat \
out-interface = public-modem2 \
action = masquerade

Next enter the ip firewall clinet ip address list to be in a mangle rule in later topology on top of her ... there are 2 ip address is 192.168.3.2 and 192.168.3.3, the command as follows:

ip firewall address-list \
add address = 192.168.3.2 \
list = "IP leads to MODEM1"

ip firewall address-list \
add address = 192.168.3.3 \
list = "IP leads to MODEM2"

if let's say your computer is a lot you just add his ip address


Next we create a mangle for the connection of the address lists that we have made along with routing mark that would mangle the ip route with routing arrested earlier mark, and marks the packet for the opportunistic queue trees, with the command:

/ Ip firewall mangle add chain = prerouting \
action = mark-connection \
new-connection-mark = MODEM1 passthrough = yes \
src-address-list = "IP leads to MODEM1" \
in-interface = local-client

/ Ip firewall mangle add chain = prerouting \
action = mark-routing new-routing-mark = MODEM1 \
passthrough = no in-interface = local-client \
connection-mark = MODEM1

/ Ip firewall mangle add chain = forward \
action = mark-packet new-packet-mark = "MODEM1 DOWN" \
passthrough = no dst-address = 192.168.3.2 \
connection-mark = MODEM1

/ Ip firewall mangle add chain = forward \
action = mark-packet new-packet-mark = "MODEM1 UP" \
passthrough = no src-address = 192.168.3.2 \
connection-mark = MODEM1

/ Ip firewall mangle add chain = prerouting \
action = mark-connection \
new-connection-mark = MODEM2 passthrough = yes \
src-address-list = "IP leads to MODEM2" \
in-interface = local-client

/ Ip firewall mangle add chain = prerouting \
action = mark-routing new-routing-mark = MODEM2 \
passthrough = no in-interface = local-client \
connection-mark = MODEM2

/ Ip firewall mangle add chain = forward \
action = mark-packet new-packet-mark = "MODEM2 DOWN" \
passthrough = no dst-address = 192.168.3.3 \
connection-mark = MODEM2

/ Ip firewall mangle add chain = forward \
action = mark-packet new-packet-mark = "MODEM2 UP" \
passthrough = no src-address = 192.168.3.3 \
connection-mark = MODEM2

Next we create a queue type with pcq to the mark in the queue trees with less download and upload it automatically to the average bandwidth, the command:

/ Queue type add name = DOWN \
kind = pcq pcq-classifier = dst-address, dst-port

/ Queue type add name = UP \
kind = pcq pcq-classifier = src-address, src-port

Next we create its queue trees, to download and upload, the command:

/ Queue tree add name = "CLIENT MODEM1 DOWN" \
parent = global-out packet-mark = "MODEM1 DOWN" \
limit-at = 0 queue = DOWN priority = 1 \
max-limit = 0 burst-limit = 0 burst-threshold = 0 burst-time = 0s

/ Queue tree add name = "CLIENT MODEM2 DOWN" \
parent = global-out packet-mark = "MODEM2 DOWN" \
limit-at = 0 queue = DOWN priority = 1 max-limit = 0 \
burst-limit = 0 burst-threshold = 0 burst-time = 0s

/ Queue tree add name = "CLIENT MODEM1 UP" \
-modem1 parent = public packet-mark = "MODEM1 UP" \
limit-at = 0 queue = Up priority = 2 max-limit = 0 \
burst-limit = 0 burst-threshold = 0 burst-time = 0s

/ Queue tree add name = "CLIENT MODEM2 UP" \
-modem2 parent = public packet-mark = "MODEM2 UP" \
limit-at = 0 queue = Up priority = 2 max-limit = 0 \
burst-limit = 0 burst-threshold = 0 burst-time = 0s

Further test results, I first created in the computer ip address 192.168.3.2
Then I test and the results are browsing traffic headed modem1 and its queue toward modem1 also, means have been running

Further test results, I first created in the computer ip address 192.168.3.3

Then I test and the results are browsing traffic headed modem2 and its queue toward modem2 also, means have been running

Done and good luck .......