I need some help with 2 diferent subnets

What I need to do seems easy, and it probably is for most of you…so I need to ask you for help! ´cause I´m loosing job and time with this!!!

Let´s see…I have a server with MikroTik license 4. It´s working with 1 ISP with a static IP, and 1 subnet for my clients. I have 20 clients already but the line doesn´t support any more conections…so I decided to install another ISP…So, up to now, the server has 2 interfaces being used (one for the wan entry (first ISP, lets call it WAN1), and the other for the local clients (call it Local1). I have the 1º and 2º DNS set with the first ISP DNS addresses, clients as set as simple queues, the interfase Local1 is set to arp reply-only, so I have static mac entries with static IP from the Local1 range). I also have a masquerade in-interfase Wan1, and some firewall rules.
As far as this the server worked great.
Now, my idea is to administrate with the server another subnet for clients (suppose Local2), BUT this one has to use the new ISP2 gateway. In this way, both subnets will be completely independet. (using each one a different gateway). I DON´T WANT TO USE LOAD BALANCING FOR THIS.
However, I´ve been trying to configure the server, adding the IP addresses and gateway for each inteface, but I does´t work. Addresses appears in blue, and instead of the ¨AS¨ state, it is showed as ¨S¨..When I set the new gateway, the Local1 stops working, and I need to desactivate this gateway in order to let the Local1 clients running again…WHY??
Besides, I have some difficult in understanding how I need to configure the DNS, knowing that the 1º and 2º are set with the ISP1 addresses, where do I have to put the ISP2 DNS???

Any help is grateful…

What you have to do is to flow mark the traffic generated from the second loccal subnet, like:

ip firewall mangle add chain=prerouting src-address=second-subnet action=mark-packet new-packet-mark=second

then place this mark in the default route
ip route add gateway=second-ISP mark=second

Do not forget to src-nat out the second WAN interface.

Regards.

Faton

Hi Faton, I appreciate your suggestion…and I´ve been probing it all night, but I have some problems that I didn´t expect:
First, when trying to add the packet mark created in mangle to the default route, I couldn´t find the mark name in the list of usable marks. However, I put it manually, but the gateway apreared in blue, as Static, and the service didn´t work. I did this tests for the subnet1 (the one that already works with many clients), and so it´s obvious I would find the same problems in trying to make the second subnet run…In fact, I had to remove the marks and set the gateway1 to destination 0.0.0.0/0 AND reboot the system in order to let the service run again…I tried also with routing marks instead of packets, as showed in the manual, but dind´t work either…
Then I found that, without working with marks (only setting gateways for each subnet), both gateways couldn´t be active at the same time in route list. I had to desactivate the gateway2 entry in way to let subnet1 work.

That being all,
best regards, and hope I can resolve this soon! :open_mouth:

HI!!! finally I could resolve the situation…the thing is that I was following your comments, and also helping with the manual, but the real problem was the DNS!! Look, I have many clients with an ISP1, the server resolved the ISP1´s DNS, but now, when I put paket marks, I can´t open any web page if I don´t set first the current ISP´s DNS in the TCP/IP configuration in my PC. The same occurs with the new ISP2, I works great, but only setting its DNS in TCP/IP. Although I put in DNS Settings the primary and secondary DNS of the ISP, the server couldn´t resolve them. How can I configure this?? As I have now 4 DNS to set, I probed setting all of them as Static, with any name and default TTL, but it didn´t work either.

Please some help with this last stuff!!!
Thank you!!!