Connecting two networks with different IP range

smartgenesis

Junior Member
Jun 16, 2015
1
0
0
Hello everyone.,

This is the the first time i m posting a query in this forum, i have a IP CCTV network installed in my office,
i need to access the NVR from my office network PC's for local viewing. both the networks have routers and different network settings(IP, gateway, subnet).,
Sorry, But i m a rookie in computer networking. So, it will be a great help if some can guide me through this in laymans language.

I am posting an image below depicting how exactly existing networks are present & some details that i could notice. Hope to find a solution here ASAP. Thank You

http://www.filefactory.com/file/48xvq0o8n9tl/MY CCTV IP NETWORK jpeg_Page_1.jpg
 

kevnich2

Platinum Member
Apr 10, 2004
2,465
8
76
Assign nic2 on the nvr an IP address outside dhcpp range on your computer network and that should take care of it.
 

Gryz

Golden Member
Aug 28, 2010
1,551
204
106
Nice picture. Thanks. That makes it a lot clearer.

First you need a physical connection between the 2 networks. Do you have an idea or preference or requirement how you want to do that ?

The normal thing to do would be to plug a cable into Nic2 of "Router". And plug the other end of the cable into an unused port on "company router".

You then assign an unused subnet to that cable.
Example: 192.168.2.0 subnet 255.255.255.0
You give both interfaces on both routers an ip-address, taken from that range. On the two interfaces where you plugged in the cable, of course.
Example: 192.168.2.1 on Router and 192.168.2.2 on CompanyRouter.

Now you need to make sure that both Router and CompanyRouter know about the networks they are not connected to themselves. You can do that with a "routing protocol" like RIP. But that's probably overkill. The easiest way is to do it via "static routing". Static routing means you manually configure routes on a router. And nothing will need to be discovered (via a dynamic routing protocol like RIP).
Almost all routers, even cheap home-routers, have the ability to configure static routes. You might need to read the manual.

You need to configure two static routes. One static route on each router.

Router needs to know about the existence of the 10.0.89.0/24 network.
CompanyRouter needs to know about the existence of the 192.168.1.0/24 network.
(BTW, the /24 notation means: the subnet consists of 24 1-bits, which is 255.255.255.0).

So on Router you configure a static route:
destination network 10.0.89.0 subnet 255.255.255.0 next-hop 192.168.2.2
And on CompanyRouter you configure a static route:
destination network 192.168.1.0 subnet 255.255.255.0 next-hop 192.168.2.1

That is the most clean way to do it.
No other configuration (with DHCP or whatever) should be needed.
Good luck.
 
Last edited:

kevnich2

Platinum Member
Apr 10, 2004
2,465
8
76
If the OP assigned nic2 an IP of 192.168.2.x - that's not in his company LAN and he still wouldn't be able to use it. If the NVR has two NIC's on it, one of them unused and the other for communicating with the camera network, he can simply use that second NIC to bridge into the company network. All that's needed is a network cable and to program the NIC2 in the nvr an IP address of subnet 10.0.89.x There's no reason the OP needs to be able to see the cameras, he only needs to see the NVR.

OP - What is the purpose of the router with IP 192.168.1.1?
 

Gryz

Golden Member
Aug 28, 2010
1,551
204
106
If the OP assigned nic2 an IP of 192.168.2.x - that's not in his company LAN and he still wouldn't be able to use it.
PC1-PC4 send traffic to CompanyRouter, because it's their default gateway. CompanyRouter has knowledge of where 192.168.1/24, and will send packets via Router to the cameras. No problem. This is how routing is supposed to work.

If the NVR has two NIC's on it, one of them unused and the other for communicating with the camera network, he can simply use that second NIC to bridge into the company network. All that's needed is a network cable and to program the NIC2 in the nvr an IP address of subnet 10.0.89.x There's no reason the OP needs to be able to see the cameras, he only needs to see the NVR.
If you just plug in a cable, and assign an IP-address, then still PC1-PC4 will send their traffic to CompanyRouter (their default gateway). And CompanyRouter has no idea where 192.168.1/24 is. So it will drop the packets. You need to make CompanyRouter aware of 192.168.1/24. As I wrote, you can do that by running a routing protocol. Or with a static route. But it requires configuration. Besides, you'll run into problems when both Router and CompanyRouter think they are the DHCP-server on a network.

It seems that what you want to do is rip out all routers, and make it one flat LAN. The OP wants to know what he needs to add to his network. Not what he needs to remove to make it simpler.
 

kevnich2

Platinum Member
Apr 10, 2004
2,465
8
76
PC1-PC4 send traffic to CompanyRouter, because it's their default gateway. CompanyRouter has knowledge of where 192.168.1/24, and will send packets via Router to the cameras. No problem. This is how routing is supposed to work.


If you just plug in a cable, and assign an IP-address, then still PC1-PC4 will send their traffic to CompanyRouter (their default gateway). And CompanyRouter has no idea where 192.168.1/24 is. So it will drop the packets. You need to make CompanyRouter aware of 192.168.1/24. As I wrote, you can do that by running a routing protocol. Or with a static route. But it requires configuration. Besides, you'll run into problems when both Router and CompanyRouter think they are the DHCP-server on a network.

It seems that what you want to do is rip out all routers, and make it one flat LAN. The OP wants to know what he needs to add to his network. Not what he needs to remove to make it simpler.

NO! That's not what I said at all. Did you even read my post??? The OP's NVR has TWO NIC's...that's two interfaces. One of the interfaces is NOT USED. If you assign the secondary NIC an IP in the 10.0.89.x subnet and attach a cable to "Company Router" - VOILA. No additional routes are needed at all. The OP would then access the NVR via the 10.0.89.x IP address that's assigned to NIC2. It's the same idea as connecting a computer with two NIC's to two different networks.

Your idea would work, but it's by far more complicated to setup and not needed if the NVR has two NIC's in it.
 

Gryz

Golden Member
Aug 28, 2010
1,551
204
106
Oh, the NVR has 2 NICs. I thought the router had a spare NIC.
Yes, multihoming the NVR would work.

Then one week down the line, the OP would wonder why he can't ping his cameras from his PC. Or something similar. But yeah, just multihoming the NVR would solve the OP's current problem.

(Personally I still don't like it. Hacking networks will cause more problems in the long run then starting with a clean solution. On the other hand, the quick solution can also considered to have more "security benefits").
 

kevnich2

Platinum Member
Apr 10, 2004
2,465
8
76
I don't consider this a "hack" It's common for NVR's to have dual NIC's for this purpose. The OP has no need at all to access the individual camera's, that's the NVR's job. His only need it accessibility to the NVR. It's also more secure, IMO, to have the cameras segregated so only the NVR is accessible. But to each his own on that one.