API Not Working

Forum for questions and support relating to the 1.32.x releases only.
Post Reply
bignellrp
Posts: 19
Joined: Sun Dec 22, 2019 12:37 pm

API Not Working

Post by bignellrp »

Ive moved to a new NAS. I used to have Ubuntu with ZM 1.34 and the API worked fine. Now in ZMNinja the API fails.

It says ZMController.php not found but ZmController.php doesnt exist and didnt exist in the working config either.

I found a similar post here: https://github.com/pliablepixels/zmNinja/issues/300

Here is the output from the page

CakePHP: the rapid development php framework
Missing Controller
Error: ZmController could not be found.

Error: Create the class ZmController below in file: app/Controller/ZmController.php

<?php
class ZmController extends AppController {

}
Notice: If you want to customize this error message, create app/View/Errors/missing_controller.ctp

Stack Trace
APP/webroot/index.php line 107 → Dispatcher->dispatch(CakeRequest, CakeResponse)
CakePHP: the rapid development php framework
CakePHP 2.10.8



root@zoneminder:/usr/local/www/zoneminder/api/app/Controller # ls -la
total 129
drwxr-xr-x 3 www www 19 Mar 11 13:26 .
drwxr-xr-x 11 www www 12 Mar 13 11:44 ..
-rw-r--r-- 1 www www 3694 Dec 8 2018 AppController.php
drwxr-xr-x 2 www www 6 Mar 11 13:26 Component
-rw-r--r-- 1 www www 3270 Dec 8 2018 ConfigsController.php
-rw-r--r-- 1 www www 1353 Dec 8 2018 ControlsController.php
-rw-r--r-- 1 www www 12162 Dec 8 2018 EventsController.php
-rw-r--r-- 1 www www 2516 Dec 8 2018 FramesController.php
-rw-r--r-- 1 www www 3472 Dec 8 2018 GroupsController.php
-rw-r--r-- 1 www www 5584 Dec 8 2018 HostController.php
-rw-r--r-- 1 www www 2383 Dec 8 2018 LogsController.php
-rw-r--r-- 1 www www 11289 Dec 8 2018 MonitorsController.php
-rw-r--r-- 1 www www 2123 Dec 8 2018 PagesController.php
-rw-r--r-- 1 www www 3697 Dec 8 2018 ServersController.php
-rw-r--r-- 1 www www 3646 Dec 8 2018 StatesController.php
-rw-r--r-- 1 www www 3776 Dec 8 2018 StorageController.php
-rw-r--r-- 1 www www 3777 Dec 8 2018 UsersController.php
-rw-r--r-- 1 www www 2654 Dec 8 2018 ZonePresetsController.php
-rw-r--r-- 1 www www 4608 Dec 8 2018 ZonesController.php


Im running 1.32.3 in a Freenas 11.3 jail built as a plugin.

Everything else works just no API.

I followed the guide here and fixed the errors regarding the logs and disabled the rewrites

viewtopic.php?t=28189
bignellrp
Posts: 19
Joined: Sun Dec 22, 2019 12:37 pm

Re: API Not Working

Post by bignellrp »

Can anyone help here please?

Zmninja closed my issue saying this was a zoneminder/freenas issue not a zmninja issue which i agree as the API wont load in a browser either.

https://github.com/pliablepixels/zmNinja/issues/907

I've googled for answers but just finding the same pages ive already read.
User avatar
asker
Posts: 1553
Joined: Sun Mar 01, 2015 12:12 pm

Re: API Not Working

Post by asker »

FYI there seems to be another thread right above yours viewtopic.php?f=38&t=28189
May want to consolidate there?
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
bignellrp
Posts: 19
Joined: Sun Dec 22, 2019 12:37 pm

Re: API Not Working

Post by bignellrp »

Thanks.

I've put my message into the main post to see if i get an answer there.

I guess i cant delete this post?
Post Reply