I'm new to Zoneminder. For installation I followed the instructions at https://wiki.archlinux.org/index.php/ZoneMinder.
The web interface works perfectly and I got some monitors running nicely, but I'm having issues with the API:
When I try to access the API using curl method here: http://zoneminder.readthedocs.org/en/st ... l#overview
I get "object not found".
When I try ZmNinja app is says: "Login validated but API failed"
When I type the url in webbrowserI (http://localhost/zm/api) I get:
Warning: mkdir(): Permission denied in /srv/http/zoneminder/api/lib/Cake/Cache/Engine/FileEngine.php on line 380
Warning: _cake_core_ cache was unable to write 'cake_dev_sv' to File cache in /srv/http/zoneminder/api/lib/Cake/Cache/Cache.php on line 327
Warning: /srv/http/zoneminder/api/app/tmp/cache/persistent/ is not writable in /srv/http/zoneminder/api/lib/Cake/Cache/Engine/FileEngine.php on line 385
Fatal error: Uncaught CacheException: Cache engine "_cake_core_" is not properly configured. Ensure required extensions are installed, and credentials/permissions are correct in /srv/http/zoneminder/api/lib/Cake/Cache/Cache.php:186 Stack trace: #0 /srv/http/zoneminder/api/lib/Cake/Cache/Cache.php(151): Cache::_buildEngine('_cake_core_') #1 /srv/http/zoneminder/api/app/Config/core.php(375): Cache::config('_cake_core_', Array) #2 /srv/http/zoneminder/api/lib/Cake/Core/Configure.php(72): include('/srv/http/zonem...') #3 /srv/http/zoneminder/api/lib/Cake/bootstrap.php(431): Configure::bootstrap(true) #4 /srv/http/zoneminder/api/app/webroot/index.php(94): include('/srv/http/zonem...') #5 /srv/http/zoneminder/api/index.php(41): require('/srv/http/zonem...') #6 {main} thrown in /srv/http/zoneminder/api/lib/Cake/Cache/Cache.php on line 186
Any help would be appreciated!
API problem fresh Arch
Re: API problem fresh Arch
try
Code: Select all
chown -R www-data:www-data /srv/http/zoneminder/api
I no longer work on zmNinja, zmeventnotification, pyzm or mlapi. I may respond on occasion based on my available time/interest.
Please read before posting:
How to set up logging properly
How to troubleshoot and report - ES
How to troubleshoot and report - zmNinja
ES docs
zmNinja docs
Please read before posting:
How to set up logging properly
How to troubleshoot and report - ES
How to troubleshoot and report - zmNinja
ES docs
zmNinja docs
Re: API problem fresh Arch
Thanks it helped a little I think. Now I get (through access via web browser http://locahost/zm/api):
===
CakePHP: the rapid development php framework
Missing Database Connection
Error: A Database connection using "Mysql" was missing or unable to connect.
The database server returned this error: SQLSTATE[HY000] [1045] Access denied for user 'zmuser'@'localhost' (using password: YES)
Notice: If you want to customize this error message, create app/View/Errors/missing_connection.ctp
====
I can login to MySql via terminal with "zmuser" using the same password as set in /etc/zm.conf
===
CakePHP: the rapid development php framework
Missing Database Connection
Error: A Database connection using "Mysql" was missing or unable to connect.
The database server returned this error: SQLSTATE[HY000] [1045] Access denied for user 'zmuser'@'localhost' (using password: YES)
Notice: If you want to customize this error message, create app/View/Errors/missing_connection.ctp
====
I can login to MySql via terminal with "zmuser" using the same password as set in /etc/zm.conf
-
- Posts: 6
- Joined: Tue Jul 19, 2016 2:22 am
Re: API problem fresh Arch
Hi, I am starting now and I got exactly the same situation. Were you able to find out what was the issue?
Thank you
Thank you
-
- Posts: 6
- Joined: Tue Jul 19, 2016 2:22 am
Re: API problem fresh Arch
I fixed it. Found int another thread that if you change the zmuser password after installation you have to updated Database.php inside the api/app/Config folder (installing from AUR repository version 1.29 )