I can't get any live video

Forum for questions and support relating to the 1.24.x releases only.
neosmatrix
Posts: 24
Joined: Wed Jan 30, 2008 8:22 pm

I can't get any live video

Post by neosmatrix »

Zoneminder is compiling fine now, but I tried the whole day to get live streaming to work, with no luck. I installed several ffmpeg versions, removed all old libs, double checked apache, checked permissions, changed /etc/sysctl.conf according to same threads to this:
kernel.shmall = 1073741824
kernel.shmmax = 1073741824
but nothing had helped me.

The debug.log shows this

Code: Select all

02/12/09 05:19:41.203771 zmc_dvideo[-1].INF-zmc.cpp/186 [Starting Capture]
02/12/09 05:19:41.203868 zmc_dvideo[-1].DB2-zm_local_camera.cpp/1065 [Priming capture]
02/12/09 05:19:41.203882 zmc_dvideo[-1].DB3-zm_local_camera.cpp/1071 [Queuing buffers]
02/12/09 05:19:41.203900 zmc_dvideo[-1].DB3-zm_local_camera.cpp/1088 [Starting video stream]
02/12/09 05:19:43.091191 zmc_dvideo[-1].DB2-zm_local_camera.cpp/1117 [Pre-capturing]
02/12/09 05:19:43.091223 zmc_dvideo[-1].DB3-zm_local_camera.cpp/1185 [Capturing]
02/12/09 05:19:43.091235 zmc_dvideo[-1].DB3-zm_local_camera.cpp/1208 [Capturing 1 frames]
02/12/09 05:19:43.229171 zmc_dvideo[-1].DB3-zm_local_camera.cpp/1235 [Captured frame 0/1 from channel 0]
02/12/09 05:19:43.229197 zmc_dvideo[-1].DB3-zm_local_camera.cpp/1270 [Doing format conversion]
02/12/09 05:19:43.229466 zmc_dvideo[-1].INF-zm_signal.cpp/60 [Got signal 11 (Segmentation fault), crashing]
02/12/09 05:19:43.229502 zmc_dvideo[-1].ERR-zm_signal.cpp/77 [Signal address is 0x10212, no eip]
02/12/09 05:19:43.229749 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /lib/libpthread.so.0 [0x7f0a242cf7b0]]
02/12/09 05:19:43.229771 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /lib/libc.so.6(memcpy+0x283) [0x7f0a23208413]]
02/12/09 05:19:43.229789 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/lib/libswscale.so.0 [0x7f0a25b24754]]
02/12/09 05:19:43.229806 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/lib/libswscale.so.0(sws_scale+0x590) [0x7f0a25b21de0]]
02/12/09 05:19:43.229824 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x41c24b]]
02/12/09 05:19:43.229841 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x424426]]
02/12/09 05:19:43.229858 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x4069aa]]
02/12/09 05:19:43.229875 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /lib/libc.so.6(__libc_start_main+0xe6) [0x7f0a231a95a6]]
02/12/09 05:19:43.229892 zmc_dvideo[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x406309]]
02/12/09 05:19:43.229909 zmc_dvideo[-1].INF-zm_signal.cpp/99 [Backtrace complete]

Code: Select all

zmu -v -q -d /dev/video0
Video Capabilities
  Name: USB Camera (046d:08d7)
  Type: 1
    Can capture
  Video Channels: 1
  Audio Channels: 0
  Maximum Width: 640
  Maximum Height: 480
  Minimum Width: 48
  Minimum Height: 32
Window Attributes
  X Offset: 0
  Y Offset: 0
  Width: 640
  Height: 480
Picture Attributes
  Palette: 0 - Unknown
  Colour Depth: 8
  Brightness: 32382
  Hue: 0
  Colour :0
  Contrast: 32512
  Whiteness: 39321
Channel 0 Attributes
  Name: zc3xx
  Channel: 0
  Flags: 0
  Type: 2 - Camera
  Format: 0 - PAL

Code: Select all

v4l-info

### v4l2 device info [/dev/video0] ###
general info
    VIDIOC_QUERYCAP
 driver                  : "zc3xx"
 card                    : "USB Camera (046d:08d7)"
 bus_info                : "0000:00:1a.1"
 version                 : 2.3.0
 capabilities            : 0x5000001 [VIDEO_CAPTURE,READWRITE,STREAMING]

standards

inputs
    VIDIOC_ENUMINPUT(0)
 index                   : 0
 name                    : "zc3xx"
 type                    : CAMERA
 audioset                : 0
 tuner                   : 0
 std                     : 0x0 []
 status                  : 0x0 []

video capture
    VIDIOC_ENUM_FMT(0,VIDEO_CAPTURE)
 index                   : 0
 type                    : VIDEO_CAPTURE
 flags                   : 1
 description             : "JPEG"
 pixelformat             : 0x4745504a [JPEG]
    VIDIOC_G_FMT(VIDEO_CAPTURE)
 type                    : VIDEO_CAPTURE
 fmt.pix.width           : 640
 fmt.pix.height          : 480
 fmt.pix.pixelformat     : 0x4745504a [JPEG]
 fmt.pix.field           : NONE
 fmt.pix.bytesperline    : 640
 fmt.pix.sizeimage       : 115790
 fmt.pix.colorspace      : JPEG
 fmt.pix.priv            : 0

controls
    VIDIOC_QUERYCTRL(BASE+0)
 id                      : 9963776
 type                    : INTEGER
 name                    : "Brightness"
 minimum                 : 0
 maximum                 : 255
 step                    : 1
 default_value           : 128
 flags                   : 0
    VIDIOC_QUERYCTRL(BASE+1)
 id                      : 9963777
 type                    : INTEGER
 name                    : "Contrast"
 minimum                 : 0
 maximum                 : 256
 step                    : 1
 default_value           : 128
 flags                   : 0

### video4linux device info [/dev/video0] ###
general info
    VIDIOCGCAP
 name                    : "USB Camera (046d:08d7)"
 type                    : 0x1 [CAPTURE]
 channels                : 1
 audios                  : 0
 maxwidth                : 640
 maxheight               : 480
 minwidth                : 48
 minheight               : 32

channels
    VIDIOCGCHAN(0)
 channel                 : 0
 name                    : "zc3xx"
 tuners                  : 0
 flags                   : 0x0 []
 type                    : CAMERA
 norm                    : 0

tuner
ioctl VIDIOCGTUNER: Invalid argument

audio
ioctl VIDIOCGAUDIO: Invalid argument

picture
    VIDIOCGPICT
 brightness              : 32382
 hue                     : 0
 colour                  : 0
 contrast                : 32512
 whiteness               : 39321
 depth                   : 8
 palette                 : unknown

buffer
ioctl VIDIOCGFBUF: Invalid argument

window
    VIDIOCGWIN
 x                       : 0
 y                       : 0
 width                   : 640
 height                  : 480
 chromakey               : 0
 flags                   : 0
I tried also every format and color palette.
I am getting a video with vlc.
Here's the output:

Code: Select all

main debug: removing module "v4l2"
main debug: thread 139772397771088 joined (input/decoder.c:248)
main debug: killing decoder fourcc `I420', 1 PES in FIFO
main debug: thread ended
main debug: thread 139772326914384 joined (video_output/video_output.c:536)
main debug: removing module "xvideo"
main debug: removing module "blend"
main debug: thread 139772312566096 joined (freetype.c:511)
main debug: removing module "freetype"
main debug: removing module "araw"
main debug: thread ended
main debug: thread 139772389378384 joined (input/decoder.c:248)
main debug: killing decoder fourcc `araw', 0 PES in FIFO
main debug: removing module "converter_float"
main debug: removing module "bandlimited_resampler"
main debug: thread ended
main debug: thread 139772380985680 joined (oss.c:548)
main debug: removing module "oss"
main debug: removing module "converter_float"
main debug: removing module "float32_mixer"
main debug: thread ended
main debug: dead input
main debug: thread 139772597107024 joined (playlist/engine.c:244)
main debug: TIMER input launching for 'v4l2://' : 2084.673 ms - Total 2084.673 ms / 1 intvls (Avg 2084.673 ms)
qt4 debug: New item: v4l2://
qt4 debug: New Option: :v4l2-dev=/dev/video0
qt4 debug: New Option: :v4l2-adev=
qt4 debug: New Option: :v4l2-standard=0
main debug: adding item `v4l2://' ( v4l2:// )
main debug: rebuilding array of current - root Wiedergabeliste
main debug: rebuild done - 2 items, index 0
main debug: starting new item
main debug: processing request item v4l2:// node null skip 0
main debug: resyncing on v4l2://
main debug: v4l2:// is at 1
main debug: creating new input thread
main debug: Creating an input for 'v4l2://'
main debug: waiting for thread initialization
main debug: thread started
main debug: thread 139772597107024 (input) created at priority 10 (input/input.c:370)
qt4 debug: Updating the stream status: 3
main debug: `v4l2://' gives access `v4l2' demux `' path `'
main debug: creating demux: access='v4l2' demux='' path=''
main debug: looking for access_demux module: 1 candidate
v4l2 debug: ALSA input support available
v4l2 debug: opening '/dev/video0' as video
v4l2 debug: V4L2 device: USB Camera (046d:08d7) using driver: zc3xx (version: 2.3.0) on 0000:00:1a.1
v4l2 debug: the device has the capabilities: (X) Video Capure, ( ) Audio, ( ) Tuner
v4l2 debug: supported I/O methods are: (X) Read/Write, (X) Streaming, ( ) Asynchronous
v4l2 debug: video input 0 (zc3xx) has type: External analog input *
v4l2 debug: device codec JPEG (JPEG) not supported as access_demux
v4l2 debug: device supports chroma RV24 [RGB3, RGB3]
v4l2 warning: Unable to query for frame sizes
v4l2 debug: device supports chroma RV24 [BGR3, BGR3]
v4l2 warning: Unable to query for frame sizes
v4l2 debug: device supports chroma I420 [YU12, YU12]
v4l2 warning: Unable to query for frame sizes
v4l2 debug: device supports chroma YV12 [YV12, YV12]
v4l2 warning: Unable to query for frame sizes
v4l2 debug: Extended control API supported by v4l2 driver
v4l2 debug: Available control: Brightness (980900)
v4l2 debug:     integer control
v4l2 debug:     valid values: 0 to 255 by steps of 1
v4l2 debug:     default value: 128
v4l2 debug:     current value: 126
v4l2 debug: Available control: Contrast (980901)
v4l2 debug:     integer control
v4l2 debug:     valid values: 0 to 256 by steps of 1
v4l2 debug:     default value: 128
v4l2 debug:     current value: 127
v4l2 debug: Available control: Gamma (980910)
v4l2 debug:     integer control
v4l2 debug:     valid values: 1 to 6 by steps of 1
v4l2 debug:     default value: 4
v4l2 debug:     current value: 4
v4l2 debug: Available control: Auto Gain (980912)
v4l2 debug:     boolean control
v4l2 debug:     default value: 1
v4l2 debug:     current value: 1
v4l2 debug: Available control: Light frequency filter (980918)
v4l2 debug:     menu control
v4l2 debug:         0: NoFliker
v4l2 debug:         1: 50 Hz
v4l2 debug:         2: 60 Hz
v4l2 debug:     default value: 1
v4l2 debug: Available control: Sharpness (98091b)
v4l2 debug:     integer control
v4l2 debug:     valid values: 0 to 3 by steps of 1
v4l2 debug:     default value: 2
v4l2 debug:     current value: 2
v4l2 debug: added new video es I420 640x480
main debug: selecting program id=0
qt4 debug: New Event: type 1108
v4l2 debug: opening '(null)' as audio
v4l2 debug: opened adev=`hw' stereo 48000Hz
v4l2 debug: new audio es 2 channels 48000Hz
main debug: using access_demux module "v4l2"
main debug: TIMER module_Need() : 1904.689 ms - Total 1904.689 ms / 1 intvls (Avg 1904.689 ms)
main debug: looking for decoder module: 30 candidates
main debug: using decoder module "rawvideo"
main debug: TIMER module_Need() : 0.167 ms - Total 0.167 ms / 1 intvls (Avg 0.167 ms)
main debug: thread started
main debug: thread 139772380985680 (decoder) created at priority 0 (input/decoder.c:217)
main debug: looking for decoder module: 30 candidates
araw debug: samplerate:48000Hz channels:2 bits/sample:16
main debug: using decoder module "araw"
main debug: TIMER module_Need() : 0.138 ms - Total 0.138 ms / 1 intvls (Avg 0.138 ms)
main debug: thread started
main debug: thread 139772389378384 (decoder) created at priority 5 (input/decoder.c:217)
main debug: `v4l2://' successfully opened
qt4 debug: New Event: type 1103
qt4 debug: Updating the stream status: 3
main debug: control type=1
main debug: no usable vout present, spawning one
main debug: window size: 640x480
main debug: looking for video output module: 6 candidates
main debug: no aout present, spawning one
main debug: looking for audio output module: 5 candidates
main debug: thread 139772312566096 (aout) created at priority 15 (oss.c:520)
main debug: using audio output module "oss"
main debug: thread started
main debug: TIMER module_Need() : 1.856 ms - Total 1.856 ms / 1 intvls (Avg 1.856 ms)
main debug: output 's16l' 48000 Hz Stereo frame=1 samples/4 bytes
main debug: mixer 'fl32' 48000 Hz Stereo frame=1 samples/8 bytes
main debug: filter(s) 'fl32'->'s16l' 48000 Hz->48000 Hz Stereo->Stereo
main debug: looking for audio filter module: 24 candidates
main debug: using audio filter module "converter_float"
main debug: TIMER module_Need() : 0.086 ms - Total 0.086 ms / 1 intvls (Avg 0.086 ms)
main debug: found a filter for the whole conversion
main debug: looking for audio mixer module: 3 candidates
main debug: using audio mixer module "float32_mixer"
main debug: TIMER module_Need() : 0.070 ms - Total 0.070 ms / 1 intvls (Avg 0.070 ms)
main debug: input 's16l' 48000 Hz Stereo frame=1 samples/4 bytes
main debug: filter(s) 's16l'->'fl32' 48000 Hz->48000 Hz Stereo->Stereo
main debug: looking for audio filter module: 24 candidates
main debug: using audio filter module "converter_float"
main debug: TIMER module_Need() : 0.074 ms - Total 0.074 ms / 1 intvls (Avg 0.074 ms)
main debug: found a filter for the whole conversion
main debug: filter(s) 'fl32'->'fl32' 52800 Hz->48000 Hz Stereo->Stereo
main debug: looking for audio filter module: 24 candidates
main debug: using audio filter module "bandlimited_resampler"
main debug: TIMER module_Need() : 0.126 ms - Total 0.126 ms / 1 intvls (Avg 0.126 ms)
main debug: found a filter for the whole conversion
xvideo debug: adaptor 0, port 224, format 0x32315659 (YV12) planar
main debug: looking for vout window module: 1 candidate
main debug: TIMER module_Need() : 0.078 ms - Total 0.078 ms / 1 intvls (Avg 0.078 ms)
main debug: no window provider available
xvideo debug: XShm video extension v1.1 (without pixmaps, opcode: 142)
xvideo debug: Window manager supports NetWM
xvideo debug: Window manager supports _NET_WM_STATE_FULLSCREEN
xvideo debug: Window manager supports _NET_WM_STATE_ABOVE
xvideo debug: Window manager supports _NET_WM_STATE_BELOW
xvideo debug: Window manager supports _NET_WM_STATE_STAYS_ON_TOP
main debug: using video output module "xvideo"
main debug: TIMER module_Need() : 123.261 ms - Total 123.261 ms / 1 intvls (Avg 123.261 ms)
main debug: waiting for thread initialization
main debug: thread started
main debug: got 8 direct buffer(s)
main debug: picture in 640x480 (0,0,640x480), chroma I420, ar 4:3, sar 1:1
main debug: picture user 640x480 (0,0,640x480), chroma I420, ar 4:3, sar 1:1
main debug: picture out 640x480 (0,0,640x480), chroma I420, ar 4:3, sar 1:1
main debug: direct render, mapping render pictures 0-6 to system pictures 1-7
main debug: thread 139772397771088 (video output) created at priority 15 (video_output/video_output.c:502)
qt4 debug: New Event: type 1109
main debug: looking for text renderer module: 2 candidates
main debug: thread started
main debug: thread 139772299401552 (fontlist builder) created at priority 0 (freetype.c:477)
freetype debug: using fontsize: 30
main debug: using text renderer module "freetype"
main debug: TIMER module_Need() : 8.530 ms - Total 8.530 ms / 1 intvls (Avg 8.530 ms)
freetype debug: using fontsize: 30
main debug: looking for video blending module: 1 candidate
blend debug: chroma: YUVA -> I420main warning: late picture skipped (177164)

main debug: using video blending module "blend"
main debug: TIMER module_Need() : 0.087 ms - Total 0.087 ms / 1 intvls (Avg 0.087 ms)
I hope someone can point me in the right direction to solve my problem.

Sascha Zielinski
Last edited by neosmatrix on Fri Feb 13, 2009 12:49 am, edited 1 time in total.
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

Post by nuck »

What you say is debug.log, is that generated by ZM or the system? It looks a lot to me like a system generated log, in which case I feel pretty safe in saying that you don't have your monitor configured properly.

Code: Select all

02/12/09 05:19:41.203771 zmc_dvideo[-1].INF-zmc.cpp/186 [Starting Capture] 
02/12/09 05:19:41.203868 zmc_dvideo[-1].DB2-zm_local_camera.cpp/1065 [Priming capture]


should read - zmc_dvideo0

Is your moniitor set up as /dev/video0 ? It should be.
Last edited by nuck on Thu Feb 12, 2009 6:31 am, edited 1 time in total.
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Looks like is falling out at the conversion. Do you have the latest ffmpeg from SVN installed or what do you get from ffmpeg --version
What do you get when you run:

Code: Select all

addr2line -e /usr/local/bin/zmc 0x41c24b 0x424426 0x4069aa 0x406309
neosmatrix
Posts: 24
Joined: Wed Jan 30, 2008 8:22 pm

Post by neosmatrix »

What you say is debug.log, is that generated by ZM or the system?
I enabled debug in the web console, or do you mean something else?
Is your moniitor set up as /dev/video0 ? It should be.
Yes the webcam is /dev/video0
Do you have the latest ffmpeg from SVN installed or what do you get from ffmpeg --version

Code: Select all

/usr/local/bin/ffmpeg -version
FFmpeg version SVN-r17115, Copyright (c) 2000-2009 Fabrice Bellard, et al.
  configuration: --enable-shared --enable-gpl --enable-zlib --enable-libfaadbin --enable-libfaad --enable-libfaac --enable-libxvid --prefix=/usr/local --enable-postproc --enable-pthreads --enable-libmp3lame --enable-libamr-nb --enable-libamr-wb --enable-x11grab --enable-libgsm --enable-libx264 --enable-libtheora --enable-swscale --enable-nonfree --disable-stripping --enable-avfilter --enable-libspeex --enable-avfilter-lavf --enable-xvmc --disable-altivec --disable-armv5te --disable-armv6 --disable-vis --enable-vdpau
  libavutil     49.14. 0 / 49.14. 0
  libavcodec    52.14. 0 / 52.14. 0
  libavformat   52.26. 0 / 52.26. 0
  libavdevice   52. 1. 0 / 52. 1. 0
  libavfilter    0. 3. 0 /  0. 3. 0
  libswscale     0. 6. 1 /  0. 6. 1
  libpostproc   51. 2. 0 / 51. 2. 0
  built on Feb 12 2009 07:40:44, gcc: 4.3.3
FFmpeg SVN-r17115
libavutil     49.14. 0 / 49.14. 0
libavcodec    52.14. 0 / 52.14. 0
libavformat   52.26. 0 / 52.26. 0
libavdevice   52. 1. 0 / 52. 1. 0
libavfilter    0. 3. 0 /  0. 3. 0
libswscale     0. 6. 1 /  0. 6. 1
libpostproc   51. 2. 0 / 51. 2. 0
What do you get when you run:

Code: Select all

Code:
addr2line -e /usr/local/bin/zmc 0x41c24b 0x424426 0x4069aa 0x406309

Code: Select all

addr2line -e /usr/local/bin/zmc 0x41c24b 0x424426 0x4069aa 0x406309
/home/Linux_Packages/zoneminder/ZoneMinder-1.24.0/src/zm_local_camera.cpp:1204
/home/Linux_Packages/zoneminder/ZoneMinder-1.24.0/src/zm_monitor.cpp:2522
/home/Linux_Packages/zoneminder/ZoneMinder-1.24.0/src/zmc.cpp:265
crtstuff.c:0
And still getting this error in the debug.log

Code: Select all

02/12/09 08:18:47.654817 zmc_dvideo0[-1].INF-zmc.cpp/186 [Starting Capture]
02/12/09 08:18:47.654921 zmc_dvideo0[-1].DB2-zm_local_camera.cpp/1065 [Priming capture]
02/12/09 08:18:47.654935 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1071 [Queuing buffers]
02/12/09 08:18:47.654954 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1088 [Starting video stream]
02/12/09 08:18:49.527570 zmc_dvideo0[-1].DB2-zm_local_camera.cpp/1117 [Pre-capturing]
02/12/09 08:18:49.527601 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1185 [Capturing]
02/12/09 08:18:49.527613 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1208 [Capturing 1 frames]
02/12/09 08:18:49.697553 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1235 [Captured frame 0/1 from channel 0]
02/12/09 08:18:49.697576 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1270 [Doing format conversion]
02/12/09 08:18:49.697775 zmc_dvideo0[-1].INF-zm_signal.cpp/60 [Got signal 11 (Segmentation fault), crashing]
02/12/09 08:18:49.697811 zmc_dvideo0[-1].ERR-zm_signal.cpp/77 [Signal address is 0x10212, no eip]
02/12/09 08:18:49.698041 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /lib/libpthread.so.0 [0x7fb7df0677b0]]
02/12/09 08:18:49.698065 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/lib/libswscale.so.0 [0x7fb7e09a8e00]]
02/12/09 08:18:49.698084 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/lib/libswscale.so.0(sws_scale+0x590) [0x7fb7e0999240]]
02/12/09 08:18:49.698104 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x41c17b]]
02/12/09 08:18:49.698123 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x424356]]
02/12/09 08:18:49.698139 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x4068ea]]
02/12/09 08:18:49.698156 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /lib/libc.so.6(__libc_start_main+0xe6) [0x7fb7ddf415a6]]
02/12/09 08:18:49.698174 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x406249]]
02/12/09 08:18:49.698192 zmc_dvideo0[-1].INF-zm_signal.cpp/99 [Backtrace complete]
I additionally tested zoneminder with this ffmpeg version from http://www.debian-multimedia.org unstable:

Code: Select all

# ffmpeg
FFmpeg version SVN-r16844, Copyright (c) 2000-2009 Fabrice Bellard, et al.
  configuration: --prefix=/usr --extra-cflags=-Wall -g -fPIC -DPIC --cc=ccache cc --libdir=${prefix}/lib --shlibdir=${prefix}/lib --bindir=${prefix}/bin --incdir=${prefix}/include/ffmpeg --enable-shared --enable-libmp3lame --enable-gpl --enable-libfaad --mandir=${prefix}/share/man --enable-libvorbis --enable-pthreads --enable-libfaac --enable-libxvid --enable-postproc --enable-libamr-nb --enable-libamr-wb --enable-x11grab --enable-libgsm --enable-libx264 --enable-libtheora --enable-swscale --enable-libdc1394 --enable-nonfree --disable-mmx --disable-stripping --enable-avfilter --enable-libdirac --disable-decoder=libdirac --enable-libschroedinger --disable-encoder=libschroedinger --enable-libspeex --enable-avfilter-lavf --enable-xvmc --enable-vdpau --disable-altivec --disable-armv5te --disable-armv6 --disable-vis
  libavutil     49.14. 0 / 49.14. 0
  libavcodec    52.11. 0 / 52.11. 0
  libavformat   52.25. 0 / 52.25. 0
  libavdevice   52. 1. 0 / 52. 1. 0
  libavfilter    0. 3. 0 /  0. 3. 0
  libswscale     0. 6. 1 /  0. 6. 1
  libpostproc   51. 2. 0 / 51. 2. 0
  built on Jan 28 2009 14:40:14, gcc: 4.3.3

Code: Select all

addr2line -e /usr/local/bin/zmc 0x41c24b 0x424426 0x4069aa 0x406309       /home/Linux_Packages/zoneminder/ZoneMinder-1.24.0/src/zm_local_camera.cpp:1293
/home/Linux_Packages/zoneminder/ZoneMinder-1.24.0/src/zm_monitor.cpp:2472
/home/Linux_Packages/zoneminder/ZoneMinder-1.24.0/src/zmc.cpp:256
/home/aurel32/glibc/glibc-2.9/csu/../sysdeps/x86_64/elf/start.S:116
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

Post by nuck »

neosmatrix wrote:
What you say is debug.log, is that generated by ZM or the system?
I enabled debug in the web console, or do you mean something else?

No, I meant just what I asked. ZM puts it's logs (by default) in /tmp and the system puts it's logs in /var/log. The debug.log you are posting looks to be a system log. Just curious. You'll probably want to crank the debug level up a couple of notches also to get much meaningful info from the system. Generally speaking a debug level of 0 is just that, no debugging, although I'm not certain about ZM.
Cordel wrote:Do you have the latest ffmpeg from SVN installed or what do you get from ffmpeg --version
neomatrix wrote:

Code: Select all

/usr/local/bin/ffmpeg -version
FFmpeg version SVN-r17115, 
I'm pretty sure that Phil built the release on version 17098 of ffmpeg, so you "should" be ok with the version you are using. Don't waste your time playing with anything older though since it likely won't work anyway. You may want to try pulling down and installing that specific version of ffmpeg and see if it helps. But before you go to all of that time and effort....

can you post /tmp/zmdc.log? Just from the last ZM startup is fine.
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

You may have been bitten by the issue in this post. If so try going into your monitor config and toggling the Video for Linux version, then select the palette etc again.
Phil
neosmatrix
Posts: 24
Joined: Wed Jan 30, 2008 8:22 pm

Post by neosmatrix »

No, I meant just what I asked. ZM puts it's logs (by default) in /tmp and the system puts it's logs in /var/log. The debug.log you are posting looks to be a system log. Just curious. You'll probably want to crank the debug level up a couple of notches also to get much meaningful info from the system. Generally speaking a debug level of 0 is just that, no debugging, although I'm not certain about ZM.
Ah, I see. I configured all logs to /var/log/zm and debug level is already 9.

I'm pretty sure that Phil built the release on version 17098 of ffmpeg, so you "should" be ok with the version you are using. Don't waste your time playing with anything older though since it likely won't work anyway. You may want to try pulling down and installing that specific version of ffmpeg and see if it helps. But before you go to all of that time and effort....
To make sure that this issue doesn't come from a change in ffmpeg I compiled the version you mentioned. Then I recompiled zoneminder agaist this version.

Code: Select all

ffmpeg -version
FFmpeg version SVN-r17098, Copyright (c) 2000-2009 Fabrice Bellard, et al.
  configuration: --enable-shared --enable-gpl --enable-zlib --enable-libfaadbin --enable-libfaad --enable-libfaac --enable-libxvid --prefix=/usr/local --enable-postproc --enable-pthreads --enable-libmp3lame --enable-libamr-nb --enable-libamr-wb --enable-x11grab --enable-libgsm --enable-libx264 --enable-libtheora --enable-swscale --enable-nonfree --disable-stripping --enable-avfilter --enable-libspeex --enable-avfilter-lavf --enable-xvmc --disable-altivec --disable-armv5te --disable-armv6 --disable-vis --enable-vdpau
  libavutil     49.14. 0 / 49.14. 0
  libavcodec    52.14. 0 / 52.14. 0
  libavformat   52.26. 0 / 52.26. 0
  libavdevice   52. 1. 0 / 52. 1. 0
  libavfilter    0. 3. 0 /  0. 3. 0
  libswscale     0. 6. 2 /  0. 6. 2
  libpostproc   51. 2. 0 / 51. 2. 0
  built on Feb 13 2009 01:11:19, gcc: 4.3.3
can you post /tmp/zmdc.log? Just from the last ZM startup is fine.

Code: Select all

cat zmdc.log
02/13/09 01:28:50.260578 zmdc[20075].INF [Server starting at 09/02/13 01:28:50]
02/13/09 01:28:53.409839 zmdc[20075].INF ['zmc -d /dev/video0' starting at 09/02/13 01:28:53, pid = 20115]
02/13/09 01:28:53.561350 zmdc[20075].INF ['zmfilter.pl' starting at 09/02/13 01:28:53, pid = 20121]
02/13/09 01:28:53.712566 zmdc[20075].INF ['zmaudit.pl -c' starting at 09/02/13 01:28:53, pid = 20124]
02/13/09 01:28:53.835595 zmdc[20075].INF ['zmwatch.pl' starting at 09/02/13 01:28:53, pid = 20127]
02/13/09 01:28:53.938543 zmdc[20075].INF ['zmupdate.pl -c' starting at 09/02/13 01:28:53, pid = 20129]
02/13/09 01:28:55.613781 zmdc[20075].ERR ['zmc -d /dev/video0' exited abnormally, exit status 11]
02/13/09 01:28:55.614069 zmdc[20075].INF [Starting pending process, zmc -d /dev/video0]
02/13/09 01:28:55.615049 zmdc[20075].INF ['zmc -d /dev/video0' starting at 09/02/13 01:28:55, pid = 20138]
02/13/09 01:28:57.795839 zmdc[20075].ERR ['zmc -d /dev/video0' exited abnormally, exit status 11]
02/13/09 01:29:02.001305 zmdc[20075].INF [Starting pending process, zmc -d /dev/video0]
02/13/09 01:29:02.002307 zmdc[20075].INF ['zmc -d /dev/video0' starting at 09/02/13 01:29:02, pid = 20191]
02/13/09 01:29:04.206855 zmdc[20075].ERR ['zmc -d /dev/video0' exited abnormally, exit status 11]
The debug log:

Code: Select all

02/13/09 01:21:24.160649 zmc_dvideo0[-1].DB1-zm_monitor.cpp/1810 [Loaded monitor 3(Neu), 1 zones]
02/13/09 01:21:24.160666 zmc_dvideo0[-1].INF-zmc.cpp/186 [Starting Capture]
02/13/09 01:21:24.160763 zmc_dvideo0[-1].DB2-zm_local_camera.cpp/1065 [Priming capture]
02/13/09 01:21:24.160777 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1071 [Queuing buffers]
02/13/09 01:21:24.160795 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1088 [Starting video stream]
02/13/09 01:21:26.027389 zmc_dvideo0[-1].DB2-zm_local_camera.cpp/1117 [Pre-capturing]
02/13/09 01:21:26.027424 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1185 [Capturing]
02/13/09 01:21:26.027437 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1208 [Capturing 1 frames]
02/13/09 01:21:26.197368 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1235 [Captured frame 0/1 from channel 0]
02/13/09 01:21:26.197393 zmc_dvideo0[-1].DB3-zm_local_camera.cpp/1270 [Doing format conversion]
02/13/09 01:21:26.197581 zmc_dvideo0[-1].INF-zm_signal.cpp/60 [Got signal 11 (Segmentation fault), crashing]
02/13/09 01:21:26.197674 zmc_dvideo0[-1].ERR-zm_signal.cpp/77 [Signal address is 0x10212, no eip]
02/13/09 01:21:26.197921 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /lib/libpthread.so.0 [0x7fa4e3e1a7b0]]
02/13/09 01:21:26.197970 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/lib/libswscale.so.0 [0x7fa4e575be00]]
02/13/09 01:21:26.198013 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/lib/libswscale.so.0(sws_scale+0x590) [0x7fa4e574c240]]
02/13/09 01:21:26.198057 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x41c17b]]
02/13/09 01:21:26.198099 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x424356]]
02/13/09 01:21:26.198142 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x4068ea]]
02/13/09 01:21:26.198183 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /lib/libc.so.6(__libc_start_main+0xe6) [0x7fa4e2cf45a6]]
02/13/09 01:21:26.198225 zmc_dvideo0[-1].ERR-zm_signal.cpp/98 [Backtrace: /usr/local/bin/zmc [0x406249]]
02/13/09 01:21:26.198267 zmc_dvideo0[-1].INF-zm_signal.cpp/99 [Backtrace complete]
You may have been bitten by the issue in this post. If so try going into your monitor config and toggling the Video for Linux version, then select the palette etc again.
I switched several times between v4l and v4l2. I recreated the monitor and switched between the Video for Linux version. I see the error mentioned in this thread, but this doesn't solve my problem.

I saw this error in my error.log from my apache web server:

Code: Select all

[Fri Feb 13 01:25:09 2009] [warn] [client 192.168.228.3] Timeout waiting for output from CGI script /usr/lib/cgi-bin/nph-zms, referer: https://192.168.228.7:48080/admin/zoneminder/index.php?view=watch&mid=3
Someone in this forum had an issue like this with 4GB ram. He pulled out 2GB and the error was gone.
I have 8GB of ram, but I did a memtest and no errors after 8 Hours.
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

Post by nuck »

neosmatrix wrote: Ah, I see. I configured all logs to /var/log/zm and debug level is already 9.
You may want to change the debug logging back to

Code: Select all

/tmp/zm_debug.log+ 
By using the default you should see log files created with filenames like

Code: Select all

zm_debug.log.03125
zm_debug.log.03149
zm_debug.log.03151
zm_debug.log.03153
zm_debug.log.03155
zm_debug.log.03158
zm_debug.log.03160
zm_debug.log.03162
zm_debug.log.03165
zm_debug.log.03168
I'm not so sure that ZM would even be able to write to /var/log/debug.log.

Here's a sample of what one of my ZM debug log files contains.

Code: Select all

02/12/09 04:37:14.535678 zmfix[3125].INF-zm_debug.c/292 [New Debug Level = 1, New Debug Log = /tmp/zm_debug.log.03125]
02/12/09 04:37:14.536430 zmfix[3125].DB1-zmfix.cpp/67 [Permissions on /dev/video3 are ok at 20666]
02/12/09 04:37:14.536465 zmfix[3125].DB1-zmfix.cpp/67 [Permissions on /dev/video0 are ok at 20666]
02/12/09 04:37:14.536492 zmfix[3125].DB1-zmfix.cpp/67 [Permissions on /dev/video1 are ok at 20666]
02/12/09 04:37:14.536518 zmfix[3125].DB1-zmfix.cpp/67 [Permissions on /dev/video2 are ok at 20666] 
neosmatrix
Posts: 24
Joined: Wed Jan 30, 2008 8:22 pm

Post by neosmatrix »

I'm not so sure that ZM would even be able to write to /var/log/debug.log.
neosmatrix wrote:

Ah, I see. I configured all logs to /var/log/zm and debug level is already 9.
I created the directory zm in /var/log, changed ownership to www-data and all output is created there without problems.
By using the default you should see log files created with filenames like
Code:
zm_debug.log.03125
zm_debug.log.03149
....
My directory looks this too. but all debug.log's does contain the same and I don't want to post all of it.

Here's some gdb output:

Code: Select all

gdb /usr/local/bin/zmc
GNU gdb (GDB) 6.8.50.20090106-cvs-debian
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http>...
(gdb) run -d /dev/video0
Starting program: /usr/local/bin/zmc -d /dev/video0
[Thread debugging using libthread_db enabled]

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff4fc0413 in memcpy () from /lib/libc.so.6
(gdb) bt
#0  0x00007ffff4fc0413 in memcpy () from /lib/libc.so.6
#1  0x00007ffff79ba774 in packedCopy (c=<value>, src=<value>, srcStride=
    0x7fffffffe470, srcSliceY=11967, srcSliceH=480, dst=0x878, dstStride=0x7fffffffe480)
    at libswscale/swscale.c:1902
#2  0x00007ffff79b9240 in sws_scale (c=0x60f7d30, src=<value>, srcStride=0x60e6510, srcSliceY=
    0, srcSliceH=480, dst=0x60fd630, dstStride=0x60fd650) at libswscale/swscale.c:2805
#3  0x000000000041c17b in LocalCamera::Capture (this=0x60e63b0, image=@0x60e06a0) at zm_local_camera.cpp:1292
#4  0x0000000000424356 in Monitor::Capture (this=0x60e0570) at zm_monitor.cpp:2472
#5  0x00000000004068ea in main (argc=<value>, argv=<value>) at zmc.cpp:256
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

Post by nuck »

neosmatrix wrote:I created the directory zm in /var/log, changed ownership to www-data and all output is created there without problems.
I see what you're up to now. Makes sense.
My directory looks this too. but all debug.log's does contain the same and I don't want to post all of it.
Makes sense too since you're only using one monitor.
Here's some gdb output:
Good idea.
nuck
Posts: 148
Joined: Tue Nov 11, 2008 1:43 am
Location: Canada

Post by nuck »

Comparing the gdb output you posted to what I'd posted a couple of days ago it looks as though you're crashing for the same reason I was when I was using V4L1 and trying to multiplex 2 cameras.

May well not be significant, but is your monitor configured for V4L1 or 2? Sorry if the question is redundant. I just don't feel like re-reading the whole thread now since it's late.
neosmatrix
Posts: 24
Joined: Wed Jan 30, 2008 8:22 pm

Post by neosmatrix »

I tried both methods, with every combinations of color palette and the resolutions 640x480, 320x240.
vlc works fine with V4L2 and 640x480
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

Have you tried with the SVN version?
Phil
neosmatrix
Posts: 24
Joined: Wed Jan 30, 2008 8:22 pm

Post by neosmatrix »

Have you tried with the SVN version?
Hmm no not yet. I searched the forum, website and wiki. Is there an anonymous svn access availablem or do I have to register at http://www.ctu-web.com ?
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

Details as http://svn.zoneminder.com or you can download a diff patch from the Patches section of the Wiki.
Phil
Locked