We have some servers running Windows Web Server 2008. They have two network cards. One with a private IP of the 172.X address space and one with the 10.X address space. The one with the 10.X address space is deactivated.
Both have their own switch and both are connected to a pfesense server.
The network with the 172.X addresses uses 1:1 NAT from pfsense to connect it with the public static IP. So for every private 172.X address we have public IP addresses. Our servers can connect to the Internet and users can connect to the servers. Everything works fine.
But as soon as we activate the second NIC with the 10.X address space, Windows Web Server 2008 isn't able to connect to the Internet anymore.
So I think it is a routing issue.
How can I tell Windows Web Server 2008 to use the 172.X NIC to connect to the Internet?
EDIT:
The following command will work till the dhcp lease of the 10.X NIC gets refreshed or the card gets deactivated and reactivated. Then I need to enter the command again:
route -p delete 0.0.0.0 mask 0.0.0.0 10.0.1.1
EDIT 2:
Yes, static IPs would make it a lot easier, but the network plan (I cannot change) says private IPs for internal network (10.X) and for internal network (172.X) that is 1:1 NAT to public IPs based on MAC.
My current plan is to use a task that runs the command
route -p delete 0.0.0.0 mask 0.0.0.0 10.0.1.1
every minute or so. And to higher the lease time for DHCP a lot. Do you have other suggestions?
EDIT 3:
When I only use the permanent route, my routing table looks like the following. But it is not working. I can not access the internet with this routing table:
IPv4-Route Table
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 172.16.0.1 172.16.1.30 5
0.0.0.0 0.0.0.0 10.0.1.1 10.0.1.30 5
10.0.0.0 255.255.0.0 On-link 10.0.1.30 261
10.0.1.30 255.255.255.255 On-link 10.0.1.30 261
10.0.255.255 255.255.255.255 On-link 10.0.1.30 261
127.0.0.0 255.0.0.0 On-link 127.0.0.1 306
127.0.0.1 255.255.255.255 On-link 127.0.0.1 306
127.255.255.255 255.255.255.255 On-link 127.0.0.1 306
172.16.0.0 255.240.0.0 On-link 172.16.1.30 261
172.16.1.30 255.255.255.255 On-link 172.16.1.30 261
172.31.255.255 255.255.255.255 On-link 172.16.1.30 261
224.0.0.0 240.0.0.0 On-link 127.0.0.1 306
224.0.0.0 240.0.0.0 On-link 172.16.1.30 261
224.0.0.0 240.0.0.0 On-link 10.0.1.30 261
255.255.255.255 255.255.255.255 On-link 127.0.0.1 306
255.255.255.255 255.255.255.255 On-link 172.16.1.30 261
255.255.255.255 255.255.255.255 On-link 10.0.1.30 261
===========================================================================
Persistent Routes:
Network Destination Netmask Gateway Metric
0.0.0.0 0.0.0.0 172.16.0.1 1
===========================================================================
It only works when I use the following command:
route -p delete 0.0.0.0 mask 0.0.0.0 10.0.1.1
Without this command it does not work, why?