Hi! I have two ip’s in one subnet, and i need to forward traffic from clients of addresslist1 through $ether1 whith $addr1 and of addresslist2 through $ether2 whith $addr2.
It works when packets go from subnet to inet, but when responce is coming back packets go through wrong interface.
Example:
$localaddr1($iface1) → $inetaddr($outiface)
$inetaddr($outiface) → $localaddr1($IFACE2)
Sometimes ifaces are selected in a correct way but sometimes just on the contrary.
So what I try to do:
/ip firewall mangle add chain=prerouting action=mark-routing new-routing-mark=ether1 passthrough=no dst-address-list=allowether1
/ip firewall mangle add chain=prerouting action=mark-routing new-routing-mark=ether2 passthrough=no dst-address-list=allowether2
I thought you had two customers. Are they both sharing 10.1.1.0/24?
I do not understand your setup. Can you be more specific about your ip and subnet assignments for ether1 and ether2? If the WAN ips are in the same subnet, why not assign them both to one interface?
So I’ll try to explain you what I need to do and what for. I’ve got a hostile switch that monitors our subnet. I’m providing the internet illegally. So I’m trying to transport traffic bypassing that switch. Three up-links go from the switch to 10.1.1.1/24 subnet. I have three interfaces with its own ip address each and they are connected to br1, br2, br3(switches) the way you can see in the picture attached. You’ll probably offer me to use one ip for a bridge of these three interfaces. But it doesn’t work. Packets just go the longer way through the evil switch. Now I’m trying to make my mikrotik forward packets the way shown in the picture.