Page 1 of 1

zms threads killed over slow link

Posted: Thu Dec 21, 2017 4:48 pm
by Bonzo
Hi

Running ZM 1.29 under Debian 8 with 6 cameras (640x480 and 1280x720). When viewing several live images remotely over a slowish ADSL link (e.g. with montage), zms fps get thottled (which is fine) but then if a send time ever exceeds 10 s that thread is killed:

2017-12-21 16:10:00.136517 zms 5468 ERR Terminating, last frame sent time 12.818699 secs more than maximum of 10.000000 zm_monitor.cpp 4392
2017-12-21 16:09:59.870574 zms 5468 ERR Frame send time 11670 msec too slow, throttling maxfps to 1.48 zm_monitor.cpp 4140
2017-12-21 16:09:57.900547 zms 5475 ERR Frame send time 2414 msec too slow, throttling maxfps to 0.29 zm_monitor.cpp 4140
2017-12-21 16:09:54.250448 zms 5475 ERR Frame send time 2606 msec too slow, throttling maxfps to 0.44 zm_monitor.cpp 4140
2017-12-21 16:09:53.906449 zms 5480 ERR Frame send time 4529 msec too slow, throttling maxfps to 1.48 zm_monitor.cpp 4140
2017-12-21 16:09:53.766016 zms 5474 ERR Frame send time 5198 msec too slow, throttling maxfps to 0.99 zm_monitor.cpp 4140
2017-12-21 16:09:53.244190 zms 5470 ERR Frame send time 3742 msec too slow, throttling maxfps to 0.44 zm_monitor.cpp 4140

Client is Firefox 52.4.0. I've been going through the ZM options (particularly in the Low B/W tab as am configured for Low Bandwidth) looking for a parameter to change to increase the 10 s timeout, but have not seen anything which looks relevant. Can anyone help, please?

Thanks

Re: zms threads killed over slow link

Posted: Thu Dec 21, 2017 8:01 pm
by bbunge
Try making all cameras the same resolution. Set the frame rate at the cameras to 5 fps. Check free space in tmpfs.

Re: zms threads killed over slow link

Posted: Fri Dec 22, 2017 8:17 am
by Bonzo
Capturing is all fine - frame rates are all between 2 and 5 fps, and /dev/shm is at 36%. It's not practical to make all the resolutions the same, but I appreciate that reducing resolutions will reduce the data that zms needs to stream over the wire and so make it less likely to hit the 10 s limit. The real question though is: is there any way of changing the 10 s limit or is it hard coded?

Re: zms threads killed over slow link

Posted: Fri Dec 22, 2017 9:42 am
by Bonzo
OK, this is hardcoded in zm_monitor.cpp, line 3735:

float max_secs_since_last_sent_frame = 10.0; //should be > keep alive amount (5 secs)

Could do with being a user-tunable options parameter.