can't add new monitor

Forum for questions and support relating to the 1.30.x releases only.
Locked
silentium
Posts: 7
Joined: Wed Aug 31, 2016 7:32 am

can't add new monitor

Post by silentium »

os : ubuntu 16.04
zm : 1.30
mysql :5.7.13

Code: Select all

+------------------------+
| @@GLOBAL.sql_mode      |
+------------------------+
| NO_ENGINE_SUBSTITUTION |
+------------------------+
Hi, i've got some issue with my zm
i added 9 monitors (with modect func) last week and it work fine
now i need to add another one, but when io press "save" nothing happens :new monitor doesn't added to the list (no matter which conf i've setuped)
when i press "save" i receive a warrning message

Code: Select all

zmdc		1889	WAR	Can't find process with command of 'zma -m'	zmdc.pl	
	zmdc		1889	WAR	Can't find process with command of 'zmc -m'	zmdc.pl	
	zmdc		1889	WAR	Can't find process with command of 'zma -m'	zmdc.pl	
i restarted zm and mysql =nothing
when i restarted zma and zmc

Code: Select all

 sudo /usr/bin/zmdc.pl restart zmc -m
'zmc -m' starting at 16/08/31 13:27:16, pid = 22965
sudo /usr/bin/zmdc.pl restart zma -m
'zma -m' starting at 16/08/31 13:27:20, pid = 23011
now im only receive warrning messages abot zma ,not of zmc

i cheked their (zma zmc) statuses

Code: Select all

 sudo /usr/bin/zmdc.pl status  zma -m
'zma -m' pending at 16/08/31 13:37:20
'zma -m' running since 16/08/31 13:27:20, pid =
 sudo /usr/bin/zmdc.pl status  zmc -m
'zmc -m' pending at 16/08/31 13:37:16
'zmc -m' running since 16/08/31 13:27:16, pid =
pid is empty o_O (dunno m.b. its ok)
when i restarted zma -m i receive some messages

Code: Select all

2016-08-31 13:27:20.803780	zmdc		1889	INF	'zma -m' exited normally	zmdc.pl	
2016-08-31 13:27:20.765510	zmdc		23011	INF	'zma -m' started at 16/08/31 13:27:20	zmdc.pl	
2016-08-31 13:27:20.762990	zmdc		1889	INF	'zma -m' starting at 16/08/31 13:27:20, pid = 23011	zmdc.pl	
2016-08-31 13:27:16.494170	zmdc		1889	INF	'zmc -m' exited normally	zmdc.pl	
2016-08-31 13:27:16.442410	zmdc		22965	INF	'zmc -m' started at 16/08/31 13:27:16	zmdc.pl	
2016-08-31 13:27:16.440330	zmdc		1889	INF	'zmc -m' starting at 16/08/31 13:27:16, pid = 22965	zmdc.pl
so i cheked zm status

Code: Select all

service zoneminder status
● zoneminder.service - ZoneMinder CCTV recording and surveillance system
   Loaded: loaded (/lib/systemd/system/zoneminder.service; enabled; vendor preset: enabled)
   Active: active (running) since Ср 2016-08-31 09:59:39 MSK; 3h 31min ago
  Process: 1836 ExecStop=/usr/bin/zmpkg.pl stop (code=exited, status=0/SUCCESS)
  Process: 1858 ExecStart=/usr/bin/zmpkg.pl start (code=exited, status=0/SUCCESS)
 Main PID: 1889 (zmdc.pl)
    Tasks: 69
   Memory: 12.0G
      CPU: 6h 5min 11.609s
   CGroup: /system.slice/zoneminder.service
           ├─ 1889 /usr/bin/perl -wT /usr/bin/zmdc.pl startup
           ├─ 1947 /usr/bin/zma -m 1
           ├─ 1965 /usr/bin/zmc -m 3
           ├─ 1978 /usr/bin/zmc -m 4
           ├─ 1985 /usr/bin/zma -m 4
           ├─ 1992 /usr/bin/zmc -m 5
           ├─ 1998 /usr/bin/zma -m 5
           ├─ 2087 /usr/bin/perl -wT /usr/bin/zmfilter.pl
           ├─ 2097 /usr/bin/perl -wT /usr/bin/zmaudit.pl -c
           ├─ 2103 /usr/bin/perl -wT /usr/bin/zmwatch.pl
           ├─ 2111 /usr/bin/perl -w /usr/bin/zmupdate.pl -c
           ├─ 2121 /usr/bin/perl -w /usr/bin/zmtelemetry.pl
           ├─ 4211 /usr/bin/zma -m 3
           ├─ 4854 /usr/bin/zmc -m 6
           ├─ 4858 /usr/bin/zma -m 6
           ├─ 6096 /usr/bin/zmc -m 9
           ├─ 6108 /usr/bin/zma -m 9
           ├─22807 /usr/bin/zmc -m 8
           ├─25248 /usr/bin/zmc -m 1
           ├─25273 /usr/bin/zmc -m 2
           ├─26879 /usr/bin/zma -m 8
           ├─28121 /usr/bin/zma -m 2
           ├─31421 /usr/bin/zmc -m 7
           └─31425 /usr/bin/zma -m 7
can someone help me? any advice?
bbunge
Posts: 2930
Joined: Mon Mar 26, 2012 11:40 am
Location: Pennsylvania

Re: can't add new monitor

Post by bbunge »

Out of memory (tmpfs)? Run a "df" to see what space is left in /dev/shm and the /run directories. You may need to reduce resolution/frame rate of the working nine or add more RAM. Remember, Ubuntu grabs half of the system RAM for tmpfs so you can "adjust" this up or down to suit your needs. Just do not take too much away from MySQL as it will need more as the events build up.

bb
silentium
Posts: 7
Joined: Wed Aug 31, 2016 7:32 am

Re: can't add new monitor

Post by silentium »

thanks for reply
our server has 16G of RAM

Code: Select all

 df -BG
Filesystem     1G-blocks 	 Used 	Available	 Use% 	Mounted on
udev                  8G   	0G       	8G  		 0% 		/dev
tmpfs                 2G    	1G        	2G  		11% 		/run
/dev/sdb1          436G   	 3G    	 411G   	1% 		/
tmpfs                 8G    	2G        	7G  		16% 		/dev/shm
tmpfs                 1G   	 0G        	1G   		0% 		/run/lock
tmpfs                 8G    	0G       	 8G   	0% 		/sys/fs/cgroup
/dev/md0           3668G 1948G     	1534G  	56% 		/home
/dev/sdb3             1G    1G        	1G  		34% 		/boot
tmpfs                 2G    0G       		2G  		 0% 		/run/user/1000

Code: Select all

free -g
              total        used        free      shared  buff/cache   available
Mem:             14           1           0           1          12          11
Swap:            22           0          22

Code: Select all

 top
KiB Mem : 15341696 total,   151300 free,  1713036 used, 13477360 buff/cache
KiB Swap: 23437308 total, 23210692 free,   226616 used. 11980148 avail Mem

all 9 cameras has 1280*720 res and 10fps

as i can see it has enought disk space and RAM, or i'm wrong?
silentium
Posts: 7
Joined: Wed Aug 31, 2016 7:32 am

Re: can't add new monitor

Post by silentium »

bbunge wrote: You may need to reduce resolution/frame rate of the working nine or add more RAM

bb
i did(res \fps)
still nothing
SteveGilvarry
Posts: 494
Joined: Sun Jun 29, 2014 1:12 pm
Location: Melbourne, AU

Re: can't add new monitor

Post by SteveGilvarry »

I wonder if something is wrong in your monitor table? Maybe check it to see if you have any entries that are not for camera 1-9.
Also the fact that command zma -m keeps showing up without a monitor number is odd, and that particular error is coming from a stop command in zmdc. You are running sudo /usr/bin/zmdc.pl restart zmc -m and zma -m, normally need a monitor id after -m. Systemd should be handling all the zmdc commands.

Between setting up your first 9 monitors and the new one did you perform some lock down activities or any changes that might be causing this? Review history is not sure.
Production Zoneminder 1.37.x (Living dangerously)
Random Selection of Cameras (Dahua and Hikvision)
silentium
Posts: 7
Joined: Wed Aug 31, 2016 7:32 am

Re: can't add new monitor

Post by silentium »

Between setting up your first 9 monitors and the new one did you perform some lock down activities or any changes that might be causing this? Review history is not sure.
now i don't remember, did it all as usual

SteveGilvarry wrote:I wonder if something is wrong in your monitor table? Maybe check it to see if you have any entries that are not for camera 1-9.
Also the fact that command zma -m keeps showing up without a monitor number is odd, and that particular error is coming from a stop command in zmdc. You are running sudo /usr/bin/zmdc.pl restart zmc -m and zma -m, normally need a monitor id after -m. Systemd should be handling all the zmdc commands.
i ran

Code: Select all

select 8 from Monitors;
and i got 9 entryes, seems nothing wrong(names,confgis,paths and all)... but i tried to add new monitor via sql querry, so i stoped zm , run query ,started zm and
got nothing o_O still 9 cameras and all works
then i deleted that row
SteveGilvarry
Posts: 494
Joined: Sun Jun 29, 2014 1:12 pm
Location: Melbourne, AU

Re: can't add new monitor

Post by SteveGilvarry »

Long shot but maybe post some screenshots of the config you trying to add. Maybe it is a special character or something.
Production Zoneminder 1.37.x (Living dangerously)
Random Selection of Cameras (Dahua and Hikvision)
silentium
Posts: 7
Joined: Wed Aug 31, 2016 7:32 am

Re: can't add new monitor

Post by silentium »

SteveGilvarry wrote:Long shot but maybe post some screenshots of the config you trying to add. Maybe it is a special character or something.
configs are same for all monitors (except ip addresses)
hikvision DS-2CD2432F-I
even then i try to clone monitor =same result



wow wow wow wow
i cant even delete some of them o_O (again nothing happens)
my zm can't read/edit the monitors table(i wrote that i added entry via query)? but why i can't see some log errors about this?

ps at the proccess of adding first 9 cameras i was able to delete them, now i can't ><
Attachments
camera.jpg
camera.jpg (130.64 KiB) Viewed 5981 times
SteveGilvarry
Posts: 494
Joined: Sun Jun 29, 2014 1:12 pm
Location: Melbourne, AU

Re: can't add new monitor

Post by SteveGilvarry »

Are you looking at the logs in the database, using the Log button on the console? Does sound like some sort of DB update permissions issue, which would be reported from web components not zmc or zmdc. Check logging options but I think database is default to Info and so should have data in the web based log view.
Production Zoneminder 1.37.x (Living dangerously)
Random Selection of Cameras (Dahua and Hikvision)
silentium
Posts: 7
Joined: Wed Aug 31, 2016 7:32 am

Re: can't add new monitor

Post by silentium »

SteveGilvarry wrote:Are you looking at the logs in the database, using the Log button on the console? Does sound like some sort of DB update permissions issue, which would be reported from web components not zmc or zmdc. Check logging options but I think database is default to Info and so should have data in the web based log view.
my /var/log/mysql/error.log gives nothing about it... only notes (at the time when i restarted zm and mysql)
log via web = same... nothing about db permissions
i select 'db' table at mysql database? so 'zmuser' has necessary permissions to select\update\alter\delete at "zm" database
silentium
Posts: 7
Joined: Wed Aug 31, 2016 7:32 am

Re: can't add new monitor

Post by silentium »

sh*t....
i found that....
i just creted a new user with admin rights at zm? now i can do that ever i want
i added 10th camera
i cant delete them and etc....



ps I'm very sory for spent your time >< he added the cameras list t oadmin user, thats why admin user wasn't able to modify camera's list(sounds wird o_o)
now we cleaned that list for admin user, now it works fine = he can add\remove cameras
thanks everyone for your help and advieces
problem solved
now i'll try to increase sensivity of modetc some how :( it's to low
Locked