Windows 7 with two network cards doesn’t route traffic

networkingrouterroutingwindows 7

I have simple task to do:
I have wni7 with two nics.I want to connect another comp(osx) to win7 through second nic to connect it to internet.

  • I already changed the registry.
  • Win7 interface with 192.168.2.1 has no gateway set (no point to do that)
  • OSX interface with 192.168.2.2 has gateway set to 192.168.2.1
  • I do not add any routes on win7, every thing seems to be already there
  • network on second nic is detected as "undefined network" (probably effect of no gateway)
  • i can achieve any connectivity to internet from OSX only by enabling network connection sharing on nic with 192.168.2.1, but it enables NAT and I'm interested only in pure routing without nat(it's a setup for some research).
  • firewall is off.

It seems to me that win7 refuses to forward packets for some reason. Perhaps "undefined network" and NLA service is to blame, although i couldn't find any info about that.

Below ascii schematics of my setup:

internet<–>router(192.168.1.1)<–>(192.168.1.2) WIN7 (192.168.2.1)<–>(192.168.2.2)OSX

Thanks

Best Answer

Check that your router has a route to the 192.168.2.x network. Unless you can add one or it is able to discover it your out of luck. It needs a route to tell it to send traffic for 192.168.2.x through the Windows 7 machine acting as a router/gateway at 192.168.1.2.

Make sure routing is enabled on the WIndows 7 machine (do a ipconfig /all at the command prompt and check for a line that says IP Routing Enabled . . . . . . . : Yes.

If it is not enable you can change this by setting the value of the following registry key to 1: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\ Services\Tcpip\Parameters\IPEnableRouter

Related Question