Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zmNinja mobile stuck at "Loading Monitors" #1038

Closed
amasidlover opened this issue Feb 14, 2021 · 3 comments
Closed

zmNinja mobile stuck at "Loading Monitors" #1038

amasidlover opened this issue Feb 14, 2021 · 3 comments

Comments

@amasidlover
Copy link

1.6.004 zmNinja version


Gentoo Linux; zoneMinder 1.34.5


Android 9 - (47.2.A.11.228 build for Sony XPeria XZ1)


**Did you build the package from source code yourself?** No



zmNinja 'stops' at Loading Monitors - the debug logs show a '500' error but no details of what the error was; likewise the server shows:

192.168.0.61 - - [14/Feb/2021:15:32:54 +0000] "GET /zoneminder/api/configs/viewByName/ZM_MIN_STREAMING_PORT.json?&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJab25lTWluZGVyIiwiaWF0IjoxNjEzMzE2MjA4LCJleHAiOjE2MTMzMjM0MDgsInVzZXIiOiJhZG1pbiIsInR5cGUiOiJhY2Nlc3MifQ.tufefcu5IjVQdQEn_Nf1Lt-DK44jG-vM7oELtjaacqg HTTP/1.1" 500 529

but there appears to be no error associated with it in ssl_error_log.


Feb 14, 2021 03:55:00:000 PM INFO ******* app .run device ready
Feb 14, 2021 03:55:00:004 PM INFO Device is ready
Feb 14, 2021 03:55:00:004 PM INFO setting size
Feb 14, 2021 03:55:00:005 PM DEBUG UA is mozilla/5.0 (linux; android 9; g8341 build/47.2.a.11.228; wv) applewebkit/537.36 (khtml, like gecko) version/4.0 chrome/88.0.4324.152 mobile safari/537.36
Feb 14, 2021 03:55:00:006 PM INFO You are running on android
Feb 14, 2021 03:55:00:007 PM DEBUG Inside configureStorageDB
Feb 14, 2021 03:55:00:008 PM DEBUG configureStorageDB: trying order:["asyncStorage","localStorageWrapper"]
Feb 14, 2021 03:55:00:047 PM INFO configureStorageDB:localforage driver for storage:asyncStorage
Feb 14, 2021 03:55:00:048 PM DEBUG configureStorageDB:Making sure this storage driver works...
Feb 14, 2021 03:55:00:056 PM DEBUG resize/orient: 360(w) * 568(h)
Feb 14, 2021 03:55:00:075 PM DEBUG configureStorageDB:test get/set worked, this driver is ok...
Feb 14, 2021 03:55:00:077 PM INFO localforage driver:asyncStorage
Feb 14, 2021 03:55:00:078 PM INFO CloudSync: Syncing with cloud if enabled...
Feb 14, 2021 03:55:00:082 PM INFO user profile encrypted, decoding...
Feb 14, 2021 03:55:00:096 PM DEBUG deobfuscate: before:1662 after:5799 scheme:lzs
Feb 14, 2021 03:55:00:097 PM INFO Found valid local configuration, overwriting cloud settings...
Feb 14, 2021 03:55:00:112 PM INFO local data synced with cloud...
Feb 14, 2021 03:55:00:115 PM INFO Cloudsync operation complete, continuing...
Feb 14, 2021 03:55:00:117 PM INFO >>>>No data to import....
Feb 14, 2021 03:55:00:118 PM INFO Updating statusbar
Feb 14, 2021 03:55:00:124 PM INFO Retrieving language before init is called...
Feb 14, 2021 03:55:00:127 PM INFO App Version: 1.6.004
Feb 14, 2021 03:55:00:129 PM INFO No language set, switching to en
Feb 14, 2021 03:55:00:132 PM INFO Device Language is:en
Feb 14, 2021 03:55:00:133 PM INFO >>>>Language to be used:en
Feb 14, 2021 03:55:00:135 PM DEBUG isFirstUse returned: false
Feb 14, 2021 03:55:00:136 PM DEBUG last state=app.log param=[object Object]
Feb 14, 2021 03:55:00:136 PM INFO Language file loaded, continuing with rest
Feb 14, 2021 03:55:00:137 PM INFO ZMData init: checking for stored variables & setting up log file
Feb 14, 2021 03:55:00:141 PM INFO Checking for new version updates...
Feb 14, 2021 03:55:00:232 PM INFO Setting up pause and resume handler AFTER language is loaded...
Feb 14, 2021 03:55:00:232 PM DEBUG Android detected, using cordova-multiwindow plugin for onStop/onStart instead
Feb 14, 2021 03:55:00:239 PM INFO user profile encrypted, decoding...
Feb 14, 2021 03:55:00:253 PM DEBUG deobfuscate: before:1662 after:5799 scheme:lzs
Feb 14, 2021 03:55:00:267 PM INFO Setting NVR init bandwidth to: highbw
Feb 14, 2021 03:55:00:267 PM INFO NVR init retrieved store loginData, marking init as complete
Feb 14, 2021 03:55:00:268 PM DEBUG Setting cordova header X-ZmNinja to zmNinja_1.6.004
Feb 14, 2021 03:55:00:268 PM INFO >>>> Disabling strict SSL checking (turn off in Dev Options if you can't connect)
Feb 14, 2021 03:55:00:271 PM INFO >>> Android: enabling inline image view for self signed certs
Feb 14, 2021 03:55:00:272 PM INFO Inside init-complete in app.js: All init over, going to portal login
Feb 14, 2021 03:55:00:281 PM DEBUG --> SSL is permissive, will allow any certs. Use at your own risk.
Feb 14, 2021 03:55:00:324 PM INFO Entering Portal Main
Feb 14, 2021 03:55:00:436 PM DEBUG Inside Portal login Enter handler
Feb 14, 2021 03:55:00:436 PM INFO User credentials are provided
Feb 14, 2021 03:55:00:437 PM INFO not checking for touchID
Feb 14, 2021 03:55:00:438 PM DEBUG unlock called with check PIN=true
Feb 14, 2021 03:55:00:438 PM DEBUG PIN code entered is correct, or there is no PIN set
Feb 14, 2021 03:55:00:439 PM INFO Cancelling zmAutologin timer
Feb 14, 2021 03:55:00:440 PM DEBUG ------> Not starting login timer for token. We will start a one time timer when we know how soon the access token will live
Feb 14, 2021 03:55:00:441 PM DEBUG Inside _doLogin()
Feb 14, 2021 03:55:00:442 PM DEBUG No need for re-captcha checks with tokens
Feb 14, 2021 03:55:00:442 PM DEBUG Resetting zmCookie...
Feb 14, 2021 03:55:00:443 PM INFO Detected token login supported
Feb 14, 2021 03:55:00:451 PM INFO Access token still has 90 minutes left, using it
Feb 14, 2021 03:55:00:451 PM INFO ----> Setting token re-login after 5400 seconds
Feb 14, 2021 03:55:00:459 PM DEBUG auth-success broadcast:Successful
Feb 14, 2021 03:55:00:470 PM DEBUG _doLogoutAndLogin: Clearing cookies
Feb 14, 2021 03:55:00:472 PM INFO Adding to chain stack: www.masidlover.name>https://www.masidlover.name/zoneminder
Feb 14, 2021 03:55:00:473 PM INFO Fallback of www.masidlover.name is
Feb 14, 2021 03:55:00:474 PM INFO reached end of chain loop
Feb 14, 2021 03:55:00:475 PM INFO No need to do a reachability test, as there are no fallbacks
Feb 14, 2021 03:55:00:485 PM INFO No need for logout!
Feb 14, 2021 03:55:00:486 PM DEBUG Inside _doLogin()
Feb 14, 2021 03:55:00:486 PM DEBUG No need for re-captcha checks with tokens
Feb 14, 2021 03:55:00:487 PM DEBUG Resetting zmCookie...
Feb 14, 2021 03:55:00:487 PM INFO Detected token login supported
Feb 14, 2021 03:55:00:489 PM INFO Access token still has 90 minutes left, using it
Feb 14, 2021 03:55:00:489 PM INFO ----> Setting token re-login after 5400 seconds
Feb 14, 2021 03:55:00:493 PM DEBUG auth-success broadcast:Successful
Feb 14, 2021 03:55:00:497 PM DEBUG PortalLogin: auth success
Feb 14, 2021 03:55:00:498 PM DEBUG getAPIversion called with https://www.masidlover.name/zoneminder/api/host/getVersion.json?&token=
Feb 14, 2021 03:55:00:527 PM DEBUG CACHE: found for key: cached_api_version with expiry of:86400s
Feb 14, 2021 03:55:00:531 PM DEBUG CACHE: cached value for key:cached_api_version is good as 410 <86400
Feb 14, 2021 03:55:00:532 PM DEBUG snapshot supported in image.php
Feb 14, 2021 03:55:00:551 PM DEBUG obfuscate: original:5799 obfuscated:1662 scheme:lzs
Feb 14, 2021 03:55:00:552 PM DEBUG Setting server version to:1.34.5
Feb 14, 2021 03:55:00:552 PM DEBUG getAPI version succeeded with 1.34.5
Feb 14, 2021 03:55:00:554 PM INFO Got API version: 1.34.5
Feb 14, 2021 03:55:00:555 PM INFO First invocation of TimeZone, asking server
Feb 14, 2021 03:55:00:555 PM INFO EventSever: No Event Server present. Not initializing
Feb 14, 2021 03:55:00:559 PM DEBUG Transitioning state to: app.log with param {}
Feb 14, 2021 03:55:00:618 PM DEBUG *** Inside native HTTP error for url:{"status":500,"url":"https://www.masidlover.name/zoneminder/api/configs/viewByName/ZM_AUTH_HASH_LOGINS.json?&token=
Feb 14, 2021 03:55:00:620 PM DEBUG Auth Hash error: {"status":500,"url":"https://www.masidlover.name/zoneminder/api/configs/viewByName/ZM_AUTH_HASH_LOGINS.json?&token=
Feb 14, 2021 03:55:00:656 PM DEBUG *** Inside native HTTP error for url:{"status":500,"url":"https://www.masidlover.name/zoneminder/api/configs/viewByName/ZM_AUTH_HASH_LOGINS.json?&token=
Feb 14, 2021 03:55:00:658 PM DEBUG Auth Hash error: {"status":500,"url":"https://www.masidlover.name/zoneminder/api/configs/viewByName/ZM_AUTH_HASH_LOGINS.json?&token=
Feb 14, 2021 03:55:00:688 PM DEBUG *** Inside native HTTP error for url:{"status":500,"url":"https://www.masidlover.name/zoneminder/api/configs/viewByName/ZM_SHOW_PRIVACY.json?&token=
Feb 14, 2021 03:55:00:689 PM DEBUG CACHE: found for key: cached_timezone with expiry of:86400s
Feb 14, 2021 03:55:00:690 PM DEBUG CACHE: cached value for key:cached_timezone is good as 410 <86400
Feb 14, 2021 03:55:00:690 PM DEBUG Timezone API response is:Europe/London
Feb 14, 2021 03:55:00:691 PM DEBUG ZM_SHOW_PRIVACY returned an error, it likely doesn't exist
Feb 14, 2021 03:55:00:712 PM DEBUG current version: 1.6.004 & available version 1.6.004
Feb 14, 2021 03:55:03:020 PM INFO --------->Setting up network state handlers....
Feb 14, 2021 03:55:03:021 PM INFO --------->Setting up global key handler...
Feb 14, 2021 03:55:07:270 PM DEBUG Monitor Control afterEnter
Feb 14, 2021 03:55:07:274 PM INFO getMonitors:Force reloading all monitors
Feb 14, 2021 03:55:07:274 PM INFO Checking value of ZM_MIN_STREAMING_PORT for the first time
Feb 14, 2021 03:55:07:296 PM DEBUG CACHE: NOT found for:cached_multi_port reverting to HTTP
Feb 14, 2021 03:55:07:512 PM DEBUG *** Inside native HTTP error for url:{"status":500,"url":"https://www.masidlover.name/zoneminder/api/configs/viewByName/ZM_MIN_STREAMING_PORT.json?&token=
Feb 14, 2021 03:55:07:515 PM INFO CACHE: error with http get {"status":500,"url":"https://www.masidlover.name/zoneminder/api/configs/viewByName/ZM_MIN_STREAMING_PORT.json?&token=
Feb 14, 2021 03:56:37:154 PM INFO file location:file:///data/user/0/com.pliablepixels.zmninja_pro/files/zmNinjaLog.txt


**Additional context**

Zoneminder web and zmNinja desktop are both working correctly.

zmNinja on mobile was working previously (a few months ago - haven't checked CCTV away from home for a while as we haven't been out much...) 

Zoneminder has been upgraded server side since I first used zmNinja web; so its very possible that the server side update has caused the issue.
@pliablepixels
Copy link
Member

Your APIs don't seem to be working (returning 500s)
Have you checked ZM APIs?
After you make sure the APIs work:

In zmNinja, Menu->clear API cache
Then run wizard again

@amasidlover
Copy link
Author

Sorry, I checked when it was all first set-up; it appears that they are now returning "An Internal Error occurred" - sadly, it doesn't tell me what the error is or why there is nothing appearing in /var/log/apache/ssl_error_log for the 'internal error'.

@amasidlover
Copy link
Author

Nevermind - turned out that it logs the errors into /var/log/zm/error.log instead of the apache logs - thanks for pointing me in the right direction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants