Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 373
  • Last Modified:

Specifying absolute IP addresses

I have five Windows computers in a lab - a server running Windows Server 2003 and four XP clients.  I use the setup to test the server under various loads.The server has four Ethernet ports and  I've specified absolute IP addresses for the server ports  so that I can point each client to a different port on the server by defining the server name in each etc/hosts of each client to  a different server port. Then when I tell the load software in  each client to read from the server's name,  "SVR," each client reads through a different server network port and I avoid network bottleneck where all the clients try to read through the same server port.

But now I'd like to give all these machines internet access by plugging a port on the 16X Ethernet router that connects the machine into a DSL router that has four  Ethernet ports in and one DSL out.   But the computers plugged into the DSL router all have "Obtain an IP Address Automatically" checked for their IP address,  and thinking about it, it seems that this  probably has to be the case if you're connecting to the Internet.  

Is this true?  If you connect to the internet do you have to let your IP be chosen by the Internet  (assuming you  have no way to choose an absolute address that's unique in  the world).  

And if I let the internet set my IP addresses how can I guarantee that the clients on my local subnet here won't all access the server at the same port?  I can't define the server differently in each client's  etc/hosts anymore because I don't know what IP address will be assigned to the server ports the next time I bring the system up.

Thanks for any ideas.

steva
0
steva
Asked:
steva
  • 4
  • 4
1 Solution
 
rfportillaCommented:
I'm not quite sure where to start.  You should probably do a little reading up on networking.  That is my first recommendation.  It sounds like you have an interesting setup, but you should try to learn a little more about routing so that you can do effective testing.  

The typical setup is that the DSL router will use NAT.  This means that you are not actually assigned an Internet IP.  Instead you are given an internal IP that is translated on the Internet as needed.  You do not have to assign an IP address as it sounds like you have a DHCP.  The DHCP is a service that gives IP addresses out on the network to devices that ask for them.  The question is whether or not the IP configuration that gets assigned will be able to access both the Internet connection and your server.  To know this you have to have the IP settings for both networks.  You should also have the settings for the DHCP server.  Ask your administrator about this or log on to the router and see what the range is.

OK, with that said.  The hosts file will not be affected by where the IP address comes from.  There are three ways to do this (possibly more).

1.  Assign a "static" IP address (what you call absolute).  This IP address/subnet has to be able to communicate on both networks and have the GW pointing to your DSL device.  Make sure that this address is not an address that is in the DHCP range.   You don't want a static IP to be automatically assigned to another computer.  That's bad.  You may need to shorten the DHCP range to do this.

2. Assign two "static" IP addresses to each computer.  If the server and the DSL router do not exist on the same network, then you can assign one IP address from each card to the NIC.  In Windows networking you can set two IP addresses to a network card.  You would need to set 2 IP's to each of your four client computers.  You have to set the gateway to the IP of your DSL device.  Once again, make sure that you do not use IP's that are in your DHCP range.  

3. Reconfigure your server's networking so that it can communicate with the DSL router if this is not already configured this way.  Just let the DHCP assign IP's to your client computers.  If this is the case, the DHCP will assign unique IP's, configure the gateway and everything will be right in the world.  

If you want/need more specifics, I need the Server IP and subnet mask, the DSL IP and subnet mask, and DHCP range (IP's that it is configured to assign) and mask.

Let me know if this answers it for you.
0
 
stevaAuthor Commented:
First, thank you for all the information.  I appreciate your help.

The computers are in a spare bedroom converted to a lab, so theres no administrator here to ask anything.  Theres no DHCP server here, unless that function is being done in the 2Wire2701HG DSL gateway that I use to get onto the Internet.  I always suspected that the DHCP function was being done somewhere out on the internet, since you just have to specify Obtain an IP Address Automatically when configuring the Ethernet port and you get one.
 
Ive included a few figures that should show you more about the setup here.

Figure 1 shows the ipconfig /all for a computer  (Dell690)  thats connected to the Internet through the 2Wire box (and not connected to the local test network).  

Figure 2 shows the ipconfig /all for the server, with its static IP addresses.

Figure 3 shows some details for the Dell690 that were available from the 2Wire box.

Figure 4 shows some connection details that were available from the 2Wire box.

You talk about a DHCP range and working with the DHCP server, but since the DHCP server doesnt appear to here Im not sure how to do that.

Also, you mention assigning two IP addresses to a single NIC.  Could you explain how you do this in Windows?

Thanks again for your help.

steva



Fig-1---Dell690-ipconfig.jpg
Fig-2---Sun-ipconfig.jpg
Fig-3---Dell690-details-from-2Wi.jpg
Fig-4---DSL-Details-from-2Wire-b.jpg
0
 
rfportillaCommented:
The DHCP function is being handled by the DSL router (2Wire 2701HG).  You only have one Internet IP address that is assigned by your Internet service provider.  The IP's that you see on your computers are only internal IP's assigned by the DSL router.  I would guess that the DHCP configuration screen would be somewhere under the Local Network Configuration.  I would look for the DHCP setting on the DSL Router and use a DHCP range of 192.168.1.101-192.168.1.150 with a subnet mask of 255.255.255.0.  This gives you a maximum of 50 automatically configured devices.  That should be more than plenty for your network.  

O.K.  I have one question.  Do you want the server to have access to the Internet?  

If yes, then you have to reconfigure the IP's on the server.  Here is a sample configuration.

Server 1
  NIC 1: IP-192.168.1.201
         Mask-255.255.255.0
         GW-192.168.1.254
         DNS-192.168.1.254
  NIC 2: IP-192.168.1.202
         Mask-255.255.255.0
         GW-<blank>
  NIC 3: IP-192.168.1.203
         Mask-255.255.255.0
         GW-<blank>
  NIC 4: IP-192.168.1.204
         Mask-255.255.255.0
         GW-<blank>

Clients
  NIC  : <Obtain an IP automatically>
 
That's it.    

The second option is if you do not want to or can not reconfigure the server.  This a sample configuration

Server 1 - leave as is

Client 1 -
  NIC 1: IP-192.168.1.201
         Mask-255.255.255.0
         GW-192.168.1.254
         DNS-192.168.1.254
  NIC 2: IP-14.0.0.201
         Mask-255.0.0.0
         GW-<blank>

Client 2 -
  NIC 1: IP-192.168.1.202 #Notice this increments by 1 over Client 1
         Mask-255.255.255.0
         GW-192.168.1.254
         DNS-192.168.1.254
  NIC 2: IP-14.0.0.202 #This increments, too
         Mask-255.0.0.0
         GW-<blank>

Follow this pattern for Clients 3 and 4.

For multiple IP's on the same machine, do the following:
1. In Windows XP, goto Control Panel->Network Connections.  If you are using Vista, goto the Control Panel, click Network and Internet, click Network and Sharing Center, then click Manage Network Connections on the left side.
2. Right-click on the network connection (probably "Local Area Connection") and click on properties.
3. In the list, select "Internet Protocol (TCP/IP)" and click the Properties button.
4. Select "Use the Following IP address:" and click the "Advanced" button on the bottom right.
5. Under IP addresses, click add.  You can add multiple IP's here.  Put the 192.168.1.X IP address in their first.
6. Under Default Gateways, click add and type in the 192.168.1.254 address.  
7. Click "OK" and click "OK" again.

0
 The Evil-ution of Network Security Threats

What are the hacks that forever changed the security industry? To answer that question, we created an exciting new eBook that takes you on a trip through hacking history. It explores the top hacks from the 80s to 2010s, why they mattered, and how the security industry responded.

 
stevaAuthor Commented:
Yes, the 2Wire 2701 performs the DHCP function and I was able to find where DHCP is configured and see how I could change the range of addresses assigned, if I wanted to.  But the addresses 2Wire chooses are fine, as long as I know what they are and they dont change every time the machines boot, so I can put them into etc/hosts.

Yes, I do want the server to have access to the Internet.  And I was able to do this by just connecting a port on the Netgear GS116 switch, that connects all  the local machines together, into an Ethernet port of the 2Wire.  If I then tell all the machines  the server and the clients  to Obtain an IP address automatically they all get back these private addresses given out by the 2Wire  and, of course, that puts them on a local network that lets them access the server.
 
Now whats really amazing to me is that the local network is operating at 1Gbps while the 2Wire link is only 100Mbps. That is, when the clients are accessing the server they all seem to realize that they all have 1Gbps capability and so the transfers operate at that speed.  But when any of the machines  the server or one of the clients -  goes onto the Internet they realize that the 2Wire box can only operate at 100Mbps so they go out onto the Internet at 100Mbps.  

Still more amazing (to me), a client machine can go out to the Internet at 100Mbps WHILE it is accessing the server at 1Gbps.  The link operates at both speed concurrently.

I checked out the procedure you specified to give multiple IPs to a NIC.  Nothing hard here, but Im wondering how the NIC makes use of two addresses.  Does that mean that the port can be accessed at either IP?  Which one is used to send data?

One last point.  The last networking text I read was Tannenbaum 3rd edition, which has nothing about NATs and  the like.  Could you perhaps recommend the best current book that would bring me up to date?

Thank you for all the great, clear answers.  Youve done much more than answer my original question and Im very grateful.  I hope I havent been too much of a pest.

Thanks,
steva  
0
 
rfportillaCommented:
O.K. Let me go in order.  Regarding the DHCP, just remember that if you assign any static I.P. addresses that you exclude them from DHCP.  You don't want the I.P. to be assigned by you to one machine and assigned by the DHCP to another.

Regarding the server, you probably don't want to have the server getting dynamic addresses from the DHCP.  You are relying on those I.P. addresses to stay the same so that you can access them consistently, with the help of the hosts file.  It may seem to work for now, but if the DHCP decides to assign different addresses to the server the hosts file will point to the wrong place.  Let me know if this doesn't make sense.

Regarding 1Gb/100 Mb network, this is actually a requirement for networking.  Your connection to the Internet is only about 1-2 Mb/s.  So the routers have to take that into account as well.  Just imagine how many routers your packets have to go through on the Internet to get somewhere.  How many of those links change in speed because of hardware limitations and/or traffic.  The important thing is that TCP/IP ensures that all of those packets get there completely.

Regarding Windows networking with multiple I.P.'s  (also called multi-homed), Windows has a different set of rules from other networking devices.  The important thing to know is that when you add I.P. addresses to a NIC in Windows, it will use the first I.P. address for outgoing primarily.  But, it also uses routing rules to connect to I.P. addresses.  For example, if it knows that an I.P. address is supposed to be on the same network as address "B" then it will not try to access it using address "A."  It also uses the gateway to determine how to get to the Internet.  This is for outgoing.  For incoming, Windows will generally respond to all of the I.P.'s that are configured.  Some services will allow you to choose which I.P.'s to respond on, but that is done in that services configuration.  

I haven't read a networking book in a long time.   I generally look online, however, the tendency on the Internet is to not dumb things down.  When I feel I need more basic explanations I check out the "for Dummies" books or O'Reillys series.  "For Dummies" is more basic, obviously, but O'Reillys has great explanations, too.  As far as bringing you up to date, there is a lot of study on networking that you can do.  You would be surprised at how deep the rabbit hole goes.  I have read some on Linux networking which includes combinations of NAT, proxy, routing, and firewalling, which allows you to manipulate packets for redirection, scripting, thresholding, etc.  This is way more info than you really need.  Perhaps some basic concepts would be useful: ports, pat, nat, D.O.S. attacks, and I.P. routing.

Here are a few good links:
http://computer.howstuffworks.com/nat.htm
http://en.wikipedia.org/wiki/Network_address_translation
http://en.wikipedia.org/wiki/Multihoming

I'm glad you found the info useful.  Let me know if you have any more questions.  Please don't forget to assign some points.  I know it's just for fun, but it makes it worth it!  Thanks ;)
0
 
stevaAuthor Commented:
First, I gave you the points.  I wish there was more I could do.

Probing the 2Wire box, the range of addresses it will assign is 192.168.1.64 to 192.168.1.253 and the subnet mask is 255.255.255.0.  The router (DHCP service, DNS service, and Gateway) is at 192.168.1.254, so Ill stay away from that one. So that leaves the 63 addresses from 192.168.1.1 to 192.168.1.63  (192.168.1.0 gets an error about the subnet mask)  that I should be able to statically assign to my machines, and still get out to the Internet by pointing the Gateway to 192.168.1.254.  But this doesnt work.  It appears that the 2Wire box will only perform the DNS resolution for the IPs that it assigned itself.  Does  this seem unusual to you?
0
 
stevaAuthor Commented:
Ah!  I didn't assign the Default Gateway of the port to the 2Wire 192,168.1.254.    When I do  this all works as expected.

Thanks again for all your help.  

steva
0
 
rfportillaCommented:
Shur thing.  I'm glad it's working.  Thanks for the points and good luck.
0

Featured Post

A Cyber Security RX to Protect Your Organization

Join us on December 13th for a webinar to learn how medical providers can defend against malware with a cyber security "Rx" that supports a healthy technology adoption plan for every healthcare organization.

  • 4
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now