Discussion stats
  • 1 reply
  • 6381 views
  • 0 kudos
  • 2 in conversation
Announcements

Top Contributors
Reply
Highlighted
Follower

Connecting to IP cameras behind 2 routers

I have two IP cameras setup inside my network and I can access them just fine when I am on my network. My cameras sit behind 2 routers (long story but required). I setup port forwarding in order to access from outside my network. If a hook up only one camera, I can access it fine from inside and outside the network. When I add a second one, that's when I stop seeing both from the outside (both still visible inside the network).

Here is my setup in sequence from the ISP feed to the cameras:

Cable modem (not wireless, does not assign IP)
Router 1: wired router (DHCP enabled)
Router 2: wireless router (DHCP enabled), Static IP assigned from Router 1

I have 2 cameras attached to router 2 and assigned static IP addresses.

Test 1: I opened port XXXX1 on Router 1 and forwarded it to Router 2's IP address, and opened the same port number on Router 2 and forward to Camera 1's IP address. Result: works both inside and outside my network

Test 2: I added a second camera. I opened port XXXX1 on Router 1 and forwarded it to Router 2's IP address, and opened 2 different ports XXXX2 and XXXX3 on Router 2 and forwarded to Camera 1's and Camera 2's IP addresses. Result: works inside my network (when I don't have to use the port from the Router 1), neither camera is visible outside my network.

Any ideas? is this the right way to set this up? Any advice would be appreciated.

Thanks

Message 1 of 2
Highlighted
Mentor

Re: Connecting to IP cameras behind 2 routers

I ALWAYS recommend against the use of more than one router in a network unless you know what you're doing. First - the NAT process will not allow two devices to be accessed using the same "socket" or address/port combination. Here's where your problem appears to lie ... You forward port XXXX1 on Router1 to Router2 and XXXX1 on Router2 to Camera1 - and all is good - you can access Camera1 on /XXXX1. You now forward XXXX2 on Router2 to Camera1 and XXXX3 on Router2 to Camera2 - and nothing works - the problem is that the connection request to /XXXX1 which are forwarded to Router2 is discarded by Router2 because it is no longer forwarded, and the requests to /XXXX2 and /XXXX3 never make it to Router2 because they are discarded by Router1. I'll leave you to figure out how best to fix the issue - for my recommendation see above...

Give a man a fish, feed him for a day
Teach a man to fish, feed him for life.
Message 2 of 2