Camers not viewable on lan when no internet connection.

Forum for questions and support relating to the 1.34.x releases only.
Post Reply
iitywygms
Posts: 123
Joined: Thu Nov 08, 2012 5:19 am

Camers not viewable on lan when no internet connection.

Post by iitywygms »

Hi everyone.

Ubuntu 18.04 Zoneminder 1.34
Recently I lost internet to the house. During that time I could log onto zoneminder locally but could not view cameras. I saw no information in the log files but the cameras were not viewable. I believe that had to do with the way I have my server configured in zoneminder.
I have my server url under the configuration options as my dns address
Example https://myservername.thisip.com
I tried using the internal ip address in the server configuration but that did not work.
Question is can I configure zoneminder differently so I can always view cameras on my lan and from outside my network? Or am I doing something else wrong? Should I have configured something else differently?
Zoneminder works perfectly if the internet is up and running. Just when I lost internet connection that I ran into this issue.

Appreciate all the work the devs put into this.
alabamatoy
Posts: 349
Joined: Sun Jun 05, 2016 2:53 pm

Re: Camers not viewable on lan when no internet connection.

Post by alabamatoy »

I use local IP address for this situation, usually https://192.168.1.X/zm instead of the DNS name. Your browser may cry and whine about cert mismatch...but this approach always works for me.

Also, the monitor source should be local IP, not any alpha name.
bbunge
Posts: 2930
Joined: Mon Mar 26, 2012 11:40 am
Location: Pennsylvania

Re: Camers not viewable on lan when no internet connection.

Post by bbunge »

Loosing "internet" WAN connection should not impact devices on your LAN. With that said if your router goes offline the ZM server may not be able to see the cameras. To get around this last problem use a switch downstream from your router, run Ethernet cables from the cameras and ZM server to the switch, assign static IP addresses to the cameras and ZM server and set the DHCP in the router to exclude the IP addresses statically assigned to your camera system. The most secure way to access Zoneminder from outside your LAN is to run a VPN server on your router then access the VPN server from your phone or laptop. An alternative is to port forward your router to the Zoneminder server but I recommend you set up Apache2 to do HTTPS an do forwarding on port 443.
iitywygms
Posts: 123
Joined: Thu Nov 08, 2012 5:19 am

Re: Camers not viewable on lan when no internet connection.

Post by iitywygms »

Thank you for the suggestions.
I tried adding a server using my local ip address. Then I set the cameras to use that server. But when trying to view the camera it shows being offline. Again no error messages in the logs. I think I have something configured wonky but I am not sure what it is. Its not a big deal as it works great when using my dns address in the server settings. Just putting it out here to see if someone has a silver bullet.
mikb
Posts: 586
Joined: Mon Mar 25, 2013 12:34 pm

Re: Camers not viewable on lan when no internet connection.

Post by mikb »

alabamatoy wrote: Thu Mar 05, 2020 6:50 pm I use local IP address for this situation, usually https://192.168.1.X/zm instead of the DNS name. Your browser may cry and whine about cert mismatch...but this approach always works for me.

Also, the monitor source should be local IP, not any alpha name.
Using local IP addresses should work for local access to local ZM/cameras. But it's unfriendly, so ...

I do use an "alpha name" as you put it, but it's a local one (e.g. http://mymachine/zonemind/index.php) -- this works whether internet is up or not.

Note: It fails if my local firewall machine is down/sulking because that's where my DNS comes from:- A central table of 192.168.x.x addresses for local machines and acts as a cache-proxy for "everything else" sourced from my ISP's DNS and another DNS elsewhere out there as backup. :)

So yes: you have a DNS issue, something has to answer "myservername.thisisp.com" and cough up an IP address. If you are using your ISP's DNS, or Google, then you need an internet connection to see them.

If you don't want your own DNS server within your network, the only other way is to provide a line in your equivalent of local hosts file (/etc/hosts on *nix) that will be searched BEFORE a DNS lookup is done ...

Code: Select all

192.168.x.y   yourmachine.thisisp.com yourmachine
CountyLine
Posts: 63
Joined: Thu Aug 29, 2019 5:22 pm
Location: USA

Re: Camers not viewable on lan when no internet connection.

Post by CountyLine »

Give all cameras and your server fixed LAN IP addresses. In fact, convert all of your LAN connected devices to fixed IPs where feasible. It's so much easier that way once you get used to it.

Reserve a small range of IPs for dynamic allocation for when you have visitors or devices that won't play well with fixed IPs.
dougmccrary
Posts: 1172
Joined: Sat Aug 31, 2019 7:35 am
Location: San Diego

Re: Camers not viewable on lan when no internet connection.

Post by dougmccrary »

There should not be a problem just because internet is down.
Use the actual ip of your zoneminder system like so in browser on your lan:
Xx:xx:xx:xx/zm
If that doesn’t get the console for you, then perhaps you have a gateway modem/router that drops completely when there’s no internet connection. If so, I expect it’s some silly default that can be changed.
Another possibility is your browser is forcing https. If so try prefixing http:// to the ip.
Post Reply