2 NICs in one box, to link another PC into the network? With WHS.

Techrat

Senior Member
Joined
Nov 15, 2009
Messages
990
Setting up a WHS (Windows Home Server) box to serve video to an HTPC and backup files from LAN PCs.

My router only has 4 ports and I have 5 boxes that I need to connect, so I put a spare NIC into the WHS server, which is connecting the HTPC to the server. At this point I seem to have it working but I cannot get Internet access on the HTPC, nor can I access the HTPC from any machine other than the server. (Actually it did seem to be working but it just stopped, and I didn't change anything.)

I'm not sure if it's possible, and it's not the most important aspect of my setup but I would like to fix it is possible.

This table demonstrates how my IPs are set, I've also added an entry to HOSTS on the server and HTPC reflecting the name of the server "Server" and it's second NIC's IP "192.168.192.3". After that I've been able to get the Server and HTPC to see each other. (As per this thread that I found, http://techrepublic.com.com/5208-10...=303543&messageID=3029239&tag=content;leftCol)

Router
IP 192.168.192.1
Subnet 255.255.255.0
Gateway none
DNS none
|
|
V
Server
IP 192.168.192.2
Subnet 255.255.255.0
Gateway 192.168.192.1
DNS 192.168.192.1
|
|
V
Server NIC2
IP 192.168.192.3
Subnet 255.255.255.0
Gateway none
DNS none
|
|
V
HTPC
IP 192.168.192.4
Subnet 255.255.255.0
Gateway none
DNS none

My other machines are set as the Server's first NIC is, but differing IPs obviously, they are ok though so can be ruled out for now at least.

Would adding the routes as in the thread I mentioned fix me up? I've tried it but something must be wrong with my syntax as I get an error message. The specified mask parameter is invalid.

The command I enter is route add 192.168.192.3 Mask 255.255.255.0 192.168.192.4 metric 1 -p

I know I could just get a switch but I don't want to spend money if possible.
 
Last edited:

ponder

Honorary Master
Joined
Jan 22, 2005
Messages
92,825
Server
IP 192.168.192.2
Subnet 255.255.255.0
Gateway 192.168.192.1
DNS 192.168.192.1
|
|
V
Server NIC2
IP 192.168.192.3
Subnet 255.255.255.0
Gateway none
DNS none

There's your problem, you have both server nics in the same subnet. Put the second nic & htpc in a different subnet and let the box route between the two nics. Alternatively go and buy a 8-port switch which you can connect directly to the router or nic 2 on the server and then hand all the devices of that. This way you can firewall one central box, add proxy services, parental controls and a whole lot of other stuff if you feel inclined.
 
Last edited:

Ivork

Expert Member
Joined
Nov 9, 2005
Messages
1,217
The HTPC is never going to work setup like that. I would do what ^^ says. Change the ip range on the second nic and bind them together - use ICS probably easiest.

Your route add is senseless- delete that if it's still in your routing table.

Ping all those addresses from your HTPC box and tell us what you can see: 192.168.192.1/2/3
 

eddief1

Expert Member
Joined
Feb 26, 2008
Messages
1,418
Also remember to check if ip forwarding is enabled on your windows home server ... well at least for XP you had to enable this manually with a registry change. Your WHS is essentially a router and will not route any packets without ip forwarding enabled
 

Ivork

Expert Member
Joined
Nov 9, 2005
Messages
1,217
Ja, What he says ^^^

|
|
V
HTPC
IP 192.168.192.4
Subnet 255.255.255.0
Gateway none
DNS none

It has to have a gateway, and DNS must be the router (or any other of your choice but there must be one).
 

Techrat

Senior Member
Joined
Nov 15, 2009
Messages
990
Ok now I have deleted the entires from the hosts files that I added, I had not added the routes I mentioned at all. Now the IPs are as follows, hopefully correct.

Router
IP 192.168.192.1
Subnet 255.255.255.0
Gateway none
DNS none
|
|
V
Server
IP 192.168.192.2
Subnet 255.255.255.0
Gateway 192.168.192.1
DNS 192.168.192.1
|
|
V
Server NIC2
IP 192.168.192.3
Subnet 255.255.255.248
Gateway none
DNS none
|
|
V
HTPC
IP 192.168.192.4
Subnet 255.255.255.248
Gateway 192.168.192.1
DNS 192.168.192.1

Am I also correct in thinking that computers on different subnets should be on different workgroups, or does that not matter? I've put the server and HTPC on the "media" workgroup now anyway.

At this stage I'm basically still in the same place, the only PC I can access from the HTPC is the server (and no Internet), and I can't access the HTPC from the other PCs on the network, only the server.

So next I need to enable IP forwarding? I found the Microsoft article on how to do that, it's pretty straightforward, but in an a post I read (http://www.markwilson.co.uk/blog/2005/10/setting-up-ip-forwarding-on-windows.htm) the writer mentioned having to set up a static route to something in his router as well to get it working. Will I need to do that?

EDIT: Looks like it as it's not just working after the registry edit.

I've found where to enter static routes in my router.

Route Name
Destination IP Address
IP Subnet Mask
Gateway IP Address

I'm pretty confused as to what I should be putting in there.

EDIT: I've looked at that guys article and tried to understand how I should set the static route, I've tried the following settings.

Destination IP Address 192.168.192.3
IP Subnet Mask 255.255.255.0
Gateway IP Address 192.168.192.2

and

Destination IP Address 192.168.192.3
IP Subnet Mask 255.255.255.248
Gateway IP Address 192.168.192.2

My router is a ZyXel P-2602HWL-D1A, it has a firewall, do I need to make any changes to that to get it working as well?
 
Last edited:

EasyUp Web Hosting

EasyUp Web Hosting
Company Rep
Joined
Mar 18, 2008
Messages
8,517
On the server, bridge the 2 nics and give the bridged connection an ip address and then everything should work.

Or go buy a switch, a gigabit switch can be had for about R450.
 

ramar

Well-Known Member
Joined
Jul 24, 2007
Messages
291
Still incorrect. All your PC's are still on the same subnet. As said above you need the two NICs in the server on separate subnets. Currenty everything is on the 192.168.192.0/255.255.255.0 subnet.

Separate your subnets something like this: server NIC1 and anything connected to that nic on 192.168.192.x/255.255.255.0. Server NIC2 and HTPC on subnet 192.168.193.x/255.255.255.0.

If you are using a class C subnet (255.255.255.0) the xxx.xxx.xxx.0 are the subnet bits (bits in bold). The last 3 bits are the host bits.

Edit - or do as Sharkbait suggests - simpler.
 

Techrat

Senior Member
Joined
Nov 15, 2009
Messages
990
Ok, well the problem with that was that I didn't understand what a subnet is till now. :D

So now it's like this,

Router
IP 192.168.192.1
Subnet 255.255.255.0
Gateway none
DNS none
|
|
V
Server
IP 192.168.192.2
Subnet 255.255.255.0
Gateway 192.168.192.1
DNS 192.168.192.1
|
|
V
Server NIC2
IP 192.168.193.1
Subnet 255.255.255.0
Gateway none
DNS none
|
|
V
HTPC
IP 192.168.193.2
Subnet 255.255.255.0
Gateway 192.168.192.1
DNS 192.168.192.1

But it still hasn't changed anything. I still have IP Forwarding enabled, should I? Is bridging the NICs needed to get this working? As WHS does not let you do that.

Do I need to set up the static route now in my router maybe? Otherwise I guess it's a lost cause?

Not 100% if the gateway and dns for the HTPC is correct.
 

ramar

Well-Known Member
Joined
Jul 24, 2007
Messages
291
Gateway for the HTPC is wrong. It should be 192.168.193.1. Same with DNS.

You would also need to add a static route to route the two subnets on the server Nics. This can be done through Routing and Remote access or command line.

Forgot that WHS does not have bridging by default. I know there is a hack to allow bridging on WHS. Something to do with dovecon.exe if i remember. If you dont come right with the routing tr googling it.

Alternatively buy yourself a cheap 5 port switch.
 
Top