Multiple redundant zmc processes.
Posted: Tue Dec 14, 2004 9:29 pm
I have been running ZM with a single camera for the better part of a week without any problems. However, when I start up a 2nd monitor/modetect monitor, it seems to spawn more and more zmc processes over time.
Somehow, it's detecting that zmc -d 1 crashed with exit status 255 and spawning a new one, but in reality, the old zmc is still running. So after some period of time, I have multiple zmc -d 1 processes running.
root@cam:/etc# ps -aef | grep zmc
apache 3834 1972 1 Dec13 ? 00:19:42 /usr/local/bin/zmc -d 0
apache 15118 1972 1 09:21 ? 00:03:02 /usr/local/bin/zmc -d 1
apache 15546 1972 1 10:23 ? 00:02:15 /usr/local/bin/zmc -d 1
apache 16678 1972 1 12:47 ? 00:00:13 /usr/local/bin/zmc -d 1
root 16810 5531 0 13:02 pts/2 00:00:00 grep zmc
root@cam:/etc#
After STOPPING the modetect, pid#16678 goes away so I'm left with pids#15118, and 15546.
====
zmdc.log
====
'zmc -d 1' starting at 04/12/14 09:21:16, pid = 15118
'zmc -d 1' started at 04/12/14 09:48:17
'zmc -d 1' starting at 04/12/14 09:48:17, pid = 15312
'zmc -d 1' stopping at 04/12/14 10:06:28
'zmc -d 1' died at 04/12/14 10:06:28
'zmc -d 1' started at 04/12/14 10:06:28
'zmc -d 1' starting at 04/12/14 10:06:28, pid = 15444
'zmc -d 1' stopping at 04/12/14 10:23:39
'zmc -d 1' died at 04/12/14 10:23:39
'zmc -d 1' starting at 04/12/14 10:23:39, pid = 15546
'zmc -d 1' started at 04/12/14 10:23:39
'zmc -d 1' started at 04/12/14 10:43:00
'zmc -d 1' starting at 04/12/14 10:43:00, pid = 15746
'zmc -d 1' stopping at 04/12/14 10:58:51
'zmc -d 1' died at 04/12/14 10:58:51
'zmc -d 1' started at 04/12/14 10:58:51
'zmc -d 1' starting at 04/12/14 10:58:51, pid = 15916
'zmc -d 1' stopping at 04/12/14 11:12:12
'zmc -d 1' died at 04/12/14 11:12:12
'zmc -d 1' started at 04/12/14 11:12:12
'zmc -d 1' starting at 04/12/14 11:12:12, pid = 16018
'zmc -d 1' stopping at 04/12/14 11:48:04
'zmc -d 1' died at 04/12/14 11:48:04
'zmc -d 1' started at 04/12/14 11:48:04
'zmc -d 1' starting at 04/12/14 11:48:04, pid = 16270
'zmc -d 1' stopping at 04/12/14 11:59:35
'zmc -d 1' died at 04/12/14 11:59:35
'zmc -d 1' started at 04/12/14 11:59:35
'zmc -d 1' starting at 04/12/14 11:59:35, pid = 16340
'zmc -d 1' stopping at 04/12/14 12:12:56
'zmc -d 1' died at 04/12/14 12:12:56
'zmc -d 1' started at 04/12/14 12:12:56
'zmc -d 1' starting at 04/12/14 12:12:56, pid = 16440
'zmc -d 1' stopping at 04/12/14 12:47:08
'zmc -d 1' died at 04/12/14 12:47:08
'zmc -d 1' started at 04/12/14 12:47:08
'zmc -d 1' starting at 04/12/14 12:47:08, pid = 16678
'zmc -d 1' stopping at 04/12/14 13:02:40
'zmc -d 1' died at 04/12/14 13:02:41
'zma -m 4' stopping at 04/12/14 13:02:41
'zma -m 4' died at 04/12/14 13:02:41
'zmc -d 1' died at 04/12/14 13:02:58, signal 8
'zmc -d 1' started at 04/12/14 13:02:58
'zmc -d 1' starting at 04/12/14 13:02:58, pid = 16835
'zmc -d 1' crashed at 04/12/14 13:02:58, exit status 255
'zmc -d 1' started at 04/12/14 13:02:58
'zmc -d 1' starting at 04/12/14 13:02:58, pid = 16837
'zmc -d 1' crashed at 04/12/14 13:02:58, exit status 255
'zmc -d 1' died at 04/12/14 13:02:58, signal 8
'zmc -d 1' starting at 04/12/14 13:02:58, pid = 16839
'zmc -d 1' started at 04/12/14 13:02:58
'zmc -d 1' crashed at 04/12/14 13:02:58, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:03:08
'zmc -d 1' starting at 04/12/14 13:03:08, pid = 16843
'zmc -d 1' crashed at 04/12/14 13:03:08, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:03:28
'zmc -d 1' starting at 04/12/14 13:03:28, pid = 16848
'zmc -d 1' crashed at 04/12/14 13:03:28, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:04:08
'zmc -d 1' starting at 04/12/14 13:04:08, pid = 16853
'zmc -d 1' crashed at 04/12/14 13:04:08, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:05:28
'zmc -d 1' starting at 04/12/14 13:05:28, pid = 16855
'zmc -d 1' crashed at 04/12/14 13:05:28, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:08:08
'zmc -d 1' starting at 04/12/14 13:08:08, pid = 16908
'zmc -d 1' crashed at 04/12/14 13:08:08, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' starting at 04/12/14 13:13:28, pid = 16956
'zmc -d 1' started at 04/12/14 13:13:28
'zmc -d 1' crashed at 04/12/14 13:13:28, exit status 255
====
zmwatch.log
====
'zmc -d 1' starting at 04/12/14 09:21:16, pid = 15118
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103046497-1103046496)
'zmc -d 1' started at 04/12/14 09:48:17
'zmc -d 1' starting at 04/12/14 09:48:17, pid = 15312
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103047588-1103047587)
'zmc -d 1' started at 04/12/14 10:06:28
'zmc -d 1' starting at 04/12/14 10:06:28, pid = 15444
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103048619-1103048618)
'zmc -d 1' starting at 04/12/14 10:23:39, pid = 15546
'zmc -d 1' started at 04/12/14 10:23:39
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103049780-1103049779)
'zmc -d 1' started at 04/12/14 10:43:00
'zmc -d 1' starting at 04/12/14 10:43:00, pid = 15746
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103050731-1103050730)
'zmc -d 1' started at 04/12/14 10:58:51
'zmc -d 1' starting at 04/12/14 10:58:51, pid = 15916
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103051532-1103051531)
'zmc -d 1' started at 04/12/14 11:12:12
'zmc -d 1' starting at 04/12/14 11:12:12, pid = 16018
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103053684-1103053683)
'zmc -d 1' started at 04/12/14 11:48:04
'zmc -d 1' starting at 04/12/14 11:48:04, pid = 16270
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103054375-1103054374)
'zmc -d 1' started at 04/12/14 11:59:35
'zmc -d 1' starting at 04/12/14 11:59:35, pid = 16340
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103055176-1103055175)
'zmc -d 1' started at 04/12/14 12:12:56
'zmc -d 1' starting at 04/12/14 12:12:56, pid = 16440
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103057228-1103057227)
'zmc -d 1' started at 04/12/14 12:47:08
'zmc -d 1' starting at 04/12/14 12:47:08, pid = 16678
This seems to be completely random and I don't know why. I was originally using Redhat 9 when this occurred. After a 1 week vacation, I came back and found my system full of orphan zma processes so I created a new system using Slackware 10 in hopes that it was due to the OS installation. However, now I am mystified.
====
Sysinfo:
====
P4/1.8GHz with 512M
Linux cam 2.6.9 #13 Sat Dec 11 21:43:23 PST 2004 i686 unknown unknown GNU/Linux
Zoneminder 1.19.5
2 monitors each capturing at 10fps
kernel.shmmni = 4096
kernel.shmall = 2097152
kernel.shmmax = 50331648
02:0a.0 Multimedia video controller: Brooktree Corporation Bt878 Video Capture (rev 02)
02:0b.0 Multimedia video controller: Brooktree Corporation Bt878 Video Capture (rev 11)
root@cam:~# ipcs
------ Shared Memory Segments --------
key shmid owner perms bytes nattch status
0x00000000 0 root 600 33554432 5 dest
0x00000000 32769 root 600 33554432 5 dest
0x00000000 65538 root 600 46084 5 dest
0x7a6d2001 98307 apache 700 46080648 2
0x7a6d2004 163844 apache 700 30720448 0
------ Semaphore Arrays --------
key semid owner perms nsems
------ Message Queues --------
key msqid owner perms used-bytes messages
Somehow, it's detecting that zmc -d 1 crashed with exit status 255 and spawning a new one, but in reality, the old zmc is still running. So after some period of time, I have multiple zmc -d 1 processes running.
root@cam:/etc# ps -aef | grep zmc
apache 3834 1972 1 Dec13 ? 00:19:42 /usr/local/bin/zmc -d 0
apache 15118 1972 1 09:21 ? 00:03:02 /usr/local/bin/zmc -d 1
apache 15546 1972 1 10:23 ? 00:02:15 /usr/local/bin/zmc -d 1
apache 16678 1972 1 12:47 ? 00:00:13 /usr/local/bin/zmc -d 1
root 16810 5531 0 13:02 pts/2 00:00:00 grep zmc
root@cam:/etc#
After STOPPING the modetect, pid#16678 goes away so I'm left with pids#15118, and 15546.
====
zmdc.log
====
'zmc -d 1' starting at 04/12/14 09:21:16, pid = 15118
'zmc -d 1' started at 04/12/14 09:48:17
'zmc -d 1' starting at 04/12/14 09:48:17, pid = 15312
'zmc -d 1' stopping at 04/12/14 10:06:28
'zmc -d 1' died at 04/12/14 10:06:28
'zmc -d 1' started at 04/12/14 10:06:28
'zmc -d 1' starting at 04/12/14 10:06:28, pid = 15444
'zmc -d 1' stopping at 04/12/14 10:23:39
'zmc -d 1' died at 04/12/14 10:23:39
'zmc -d 1' starting at 04/12/14 10:23:39, pid = 15546
'zmc -d 1' started at 04/12/14 10:23:39
'zmc -d 1' started at 04/12/14 10:43:00
'zmc -d 1' starting at 04/12/14 10:43:00, pid = 15746
'zmc -d 1' stopping at 04/12/14 10:58:51
'zmc -d 1' died at 04/12/14 10:58:51
'zmc -d 1' started at 04/12/14 10:58:51
'zmc -d 1' starting at 04/12/14 10:58:51, pid = 15916
'zmc -d 1' stopping at 04/12/14 11:12:12
'zmc -d 1' died at 04/12/14 11:12:12
'zmc -d 1' started at 04/12/14 11:12:12
'zmc -d 1' starting at 04/12/14 11:12:12, pid = 16018
'zmc -d 1' stopping at 04/12/14 11:48:04
'zmc -d 1' died at 04/12/14 11:48:04
'zmc -d 1' started at 04/12/14 11:48:04
'zmc -d 1' starting at 04/12/14 11:48:04, pid = 16270
'zmc -d 1' stopping at 04/12/14 11:59:35
'zmc -d 1' died at 04/12/14 11:59:35
'zmc -d 1' started at 04/12/14 11:59:35
'zmc -d 1' starting at 04/12/14 11:59:35, pid = 16340
'zmc -d 1' stopping at 04/12/14 12:12:56
'zmc -d 1' died at 04/12/14 12:12:56
'zmc -d 1' started at 04/12/14 12:12:56
'zmc -d 1' starting at 04/12/14 12:12:56, pid = 16440
'zmc -d 1' stopping at 04/12/14 12:47:08
'zmc -d 1' died at 04/12/14 12:47:08
'zmc -d 1' started at 04/12/14 12:47:08
'zmc -d 1' starting at 04/12/14 12:47:08, pid = 16678
'zmc -d 1' stopping at 04/12/14 13:02:40
'zmc -d 1' died at 04/12/14 13:02:41
'zma -m 4' stopping at 04/12/14 13:02:41
'zma -m 4' died at 04/12/14 13:02:41
'zmc -d 1' died at 04/12/14 13:02:58, signal 8
'zmc -d 1' started at 04/12/14 13:02:58
'zmc -d 1' starting at 04/12/14 13:02:58, pid = 16835
'zmc -d 1' crashed at 04/12/14 13:02:58, exit status 255
'zmc -d 1' started at 04/12/14 13:02:58
'zmc -d 1' starting at 04/12/14 13:02:58, pid = 16837
'zmc -d 1' crashed at 04/12/14 13:02:58, exit status 255
'zmc -d 1' died at 04/12/14 13:02:58, signal 8
'zmc -d 1' starting at 04/12/14 13:02:58, pid = 16839
'zmc -d 1' started at 04/12/14 13:02:58
'zmc -d 1' crashed at 04/12/14 13:02:58, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:03:08
'zmc -d 1' starting at 04/12/14 13:03:08, pid = 16843
'zmc -d 1' crashed at 04/12/14 13:03:08, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:03:28
'zmc -d 1' starting at 04/12/14 13:03:28, pid = 16848
'zmc -d 1' crashed at 04/12/14 13:03:28, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:04:08
'zmc -d 1' starting at 04/12/14 13:04:08, pid = 16853
'zmc -d 1' crashed at 04/12/14 13:04:08, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:05:28
'zmc -d 1' starting at 04/12/14 13:05:28, pid = 16855
'zmc -d 1' crashed at 04/12/14 13:05:28, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' started at 04/12/14 13:08:08
'zmc -d 1' starting at 04/12/14 13:08:08, pid = 16908
'zmc -d 1' crashed at 04/12/14 13:08:08, exit status 255
Starting pending process, zmc -d 1
'zmc -d 1' starting at 04/12/14 13:13:28, pid = 16956
'zmc -d 1' started at 04/12/14 13:13:28
'zmc -d 1' crashed at 04/12/14 13:13:28, exit status 255
====
zmwatch.log
====
'zmc -d 1' starting at 04/12/14 09:21:16, pid = 15118
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103046497-1103046496)
'zmc -d 1' started at 04/12/14 09:48:17
'zmc -d 1' starting at 04/12/14 09:48:17, pid = 15312
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103047588-1103047587)
'zmc -d 1' started at 04/12/14 10:06:28
'zmc -d 1' starting at 04/12/14 10:06:28, pid = 15444
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103048619-1103048618)
'zmc -d 1' starting at 04/12/14 10:23:39, pid = 15546
'zmc -d 1' started at 04/12/14 10:23:39
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103049780-1103049779)
'zmc -d 1' started at 04/12/14 10:43:00
'zmc -d 1' starting at 04/12/14 10:43:00, pid = 15746
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103050731-1103050730)
'zmc -d 1' started at 04/12/14 10:58:51
'zmc -d 1' starting at 04/12/14 10:58:51, pid = 15916
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103051532-1103051531)
'zmc -d 1' started at 04/12/14 11:12:12
'zmc -d 1' starting at 04/12/14 11:12:12, pid = 16018
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103053684-1103053683)
'zmc -d 1' started at 04/12/14 11:48:04
'zmc -d 1' starting at 04/12/14 11:48:04, pid = 16270
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103054375-1103054374)
'zmc -d 1' started at 04/12/14 11:59:35
'zmc -d 1' starting at 04/12/14 11:59:35, pid = 16340
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103055176-1103055175)
'zmc -d 1' started at 04/12/14 12:12:56
'zmc -d 1' starting at 04/12/14 12:12:56, pid = 16440
Restarting capture daemon ('/usr/local/bin/zmdc.pl restart zmc -d 1'), time since last capture 1 seconds (1103057228-1103057227)
'zmc -d 1' started at 04/12/14 12:47:08
'zmc -d 1' starting at 04/12/14 12:47:08, pid = 16678
This seems to be completely random and I don't know why. I was originally using Redhat 9 when this occurred. After a 1 week vacation, I came back and found my system full of orphan zma processes so I created a new system using Slackware 10 in hopes that it was due to the OS installation. However, now I am mystified.
====
Sysinfo:
====
P4/1.8GHz with 512M
Linux cam 2.6.9 #13 Sat Dec 11 21:43:23 PST 2004 i686 unknown unknown GNU/Linux
Zoneminder 1.19.5
2 monitors each capturing at 10fps
kernel.shmmni = 4096
kernel.shmall = 2097152
kernel.shmmax = 50331648
02:0a.0 Multimedia video controller: Brooktree Corporation Bt878 Video Capture (rev 02)
02:0b.0 Multimedia video controller: Brooktree Corporation Bt878 Video Capture (rev 11)
root@cam:~# ipcs
------ Shared Memory Segments --------
key shmid owner perms bytes nattch status
0x00000000 0 root 600 33554432 5 dest
0x00000000 32769 root 600 33554432 5 dest
0x00000000 65538 root 600 46084 5 dest
0x7a6d2001 98307 apache 700 46080648 2
0x7a6d2004 163844 apache 700 30720448 0
------ Semaphore Arrays --------
key semid owner perms nsems
------ Message Queues --------
key msqid owner perms used-bytes messages