0

Sorry for my poor english in advance.

I don't know how to config my adapters for this specific situation as i explain below.

i have two NICs, one for web server and internet vpn and another for internet proxy server.

let's say for example my first NIC config is:
IP:198.25.143.196
Subnet:255.255.255.0
Gateway:198.25.143.209

and my secound NIC config is:
IP : 185.43.12.154
Subnet: 255.255.255.240
Gateway: 185.43.12.145

Also consider that i enabled routing and remote access for NIC1 and in NAT/Basic firwall i added my 1st NIC and selected public interface connected to the internet and just checked Enable NAT on this interface. when i don't config default gateway for NIC2 vpn works fine but proxy doesn't. when i don't config default gateway for NIC1 proxy server works fine but vpn doesn't. and when i config default gateway for both NIC (even though i know this is wrong), windows shoes me a warning and both vpn and proxy server works randomly and very slow.

So here is the question: how do i config my gateways (or maybe add static routes i don't know) for my NICs to both vpn and proxy server working correctly?

Saman
  • 1
  • 1
  • 1

4 Answers4

1

You can setup static route for the 2nd gateway.

how to add static route manually :

  1. open command line (CMD)

  2. Command format "route ADD destination_network MASK subnet_mask gateway_ip metric_cost", for example :

route ADD 185.43.12.154 MASK 255.255.255.240 185.43.12.145
  1. write on cmd "route print -4"

  2. tries to check the static route working or not using "tracert"

zulkarnaen
  • 36
  • 5
  • While providing links is useful, it would be _more_ helpful to the asker if you posted a summary of the steps involved on the link you posted as external links can go dead / be removed at any time. For more tips, see [answer]. – Daniele Santi Apr 04 '19 at 08:52
  • i'm new here & wasn't involved in this forum for a long time. thx for the info anyway – zulkarnaen Apr 04 '19 at 08:55
1

Mike gave you the best response by pointing out that you cannot have 2 default gateways. You should not have to modify the routing table to pull this off. Configure the two nics with an IP address and mask, then decide which interface is most critical to your needs and add the gateway information to that nic. leave the gateway on the other nic blank. Routing will still take place through both nics as needed so if you made any changes to the roouting table, remove them. Whoever provided you with the configuration information should know that you do not want to enter two gateways, and should have told you to choose one or the other.

Larryc
  • 305
  • 1
  • 5
0

You can not have 2 default gateways. May be policy routing (aka policy based routing) is what you need here.

Mike
  • 598
  • 7
  • 16
  • thanks. but as if i understood correctly, policy based routing is not supported by windows server base on this link [link](http://blogs.technet.com/b/nettracer/archive/2010/06/16/do-we-support-quot-policy-based-routing-quot-on-windows-server-operating-systems.aspx), and if it is supported i'm not familiar with it even a single bit, could you give me some links and article about it to help me learning it setp by setp? – Saman Apr 29 '13 at 18:36
0

If your net is 55.55.55.55 to gateway 55.55.55.1 place that in one nic if the otherone is 192.168.55.55 to gateway 192.168.55.1 put only the ip in nic2 then run in a bat file ex.

route add 192.168.0.0 MASK 255.255.0.0 192.168.55.1

works

imcas.no
  • 1
  • 1
  • You know you can use the *-p* switch as part of your route add command to make it stick across reboots rather than running a batch file each time, right? – Rob Moir Apr 29 '13 at 11:19
  • i guessed routing must be a solution but i don't know how to do it. every example i saw was based on lan and wan but as i mentioned with my ips example, both of my nics are wan. if you could tell me what route command i must put on my batch it would be very helfull(base on my ips config that i wroute on my question above). and if not it would be helful to refer me to a good and easy learning article. – Saman Apr 29 '13 at 18:29