Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Two PC's "A" and "B" are connected on the office LAN network having ip address range like 199.63.31.X.

"A" has 2 NIC cards in it - One connected to the LAN (199.63.31.x) and other connected(10.1.1.x) to PC "C" via a private hub.

"C" and "A" have a different ip address range : 10.1.1.X.

Is it possible to for m/c "B" to communicate with "C" via "A", considering "B" and "C" are on different ip address range?

share|improve this question

migrated from Dec 11 '09 at 9:40

This question came from our site for professional and enthusiast programmers.

This is possible. The most basic configuration that allows TCP/IP connections between your two networks is the following:

  • "A" needs to be configured to route between the two networks.
  • "B" needs a route telling it that "A" (199.63.31.x) is the gateway to network
  • "C" needs a route telling it that "A" (10.10.1.y) is the gateway to network
  • You probably need to add hosts entries on "B" and "C" so they can address each other by hostname. Without this, you must use IP addresses directly.

The exact steps needed will depend on what OS(es) these machines run. For example, Linux distributions put their hosts file at /etc/hosts; Windows machines use C:\Windows\system32\drivers\etc\hosts; Mac OSX uses /private/etc/hosts.

Other considerations you need to take into account are whether "C" needs to be able to access machines other than "B", if you care, or if "C" explicitly needs not to access other machines. You may also want to supply "C" with other services -- access to a DNS server, connections to a Windows Domain, or access to network file shares, for example. These are all possible, but you should know ahead of time exactly what you need to accomplish so you can configure "A" properly.

share|improve this answer
remeber if it is windows you will have to use the ROUTE command.. IE Route add 10.10.1.x mask 199.63.31.x -p to make the gateways "talk" to eachother... i created some intresting routes with this .. one i vpn'd into a system . then with a route from the host computer i ACTUALY could access the ROUTER of the vpn system...very cool... – mike Dec 12 '09 at 6:25

You can do this if you install IP router software on A. Without knowing what operating system A runs, it would be difficult to recommend specific software.

share|improve this answer

As others said, you need setup routing software for "A".

For Linux use iptables. If you asked such a question here, this is not what you may want to mess with.

On Windows there is an easy way to use bridged connections. Google for that, it's really to setup using wizard.

share|improve this answer
iptables might be helpful here but it's not what is needed to enable packet forwarding on a linux kernel. at this juncture it's overkill. – quack quixote Dec 11 '09 at 10:37

An evil genius would use GNS3 to emulate a Cisco router/managed switch so that when you don't need to route using a computer, you can just copy the router/switch configuration over with about 3 seconds worth of downtime.

share|improve this answer

Why not just put in a hardware router? It looks like all network cables are already at A, so just put a router there, plug in A, B, and C. Every computer can be on the same network, which will simplify sharing files etc.

Routers are not terribly expensive, and it will get rid of:

  1. Configuring sharing between B and C
  2. Loss of connectivity when A is not turned on.
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.