Page 1 of 1

RTSP troubles

Posted: Fri Sep 11, 2009 8:33 am
by asdus
Have a problem with adding RTSP video source.
I have link like: rtsp://admin:admin@x.x.x.x/live/mpeg4 - and it's work in browser, VLC & etc.
Trying to add, use all four methods of RTSP - nothing work.
tail of log:

Code: Select all

09/11/09 12:10:53.038231 zmc_m10[-1].DB1-zm_monitor.cpp/2262 [Got 1 monitors]
09/11/09 12:10:53.038531 zmc_m10[-1].DB1-zm_thread.cpp/241 [Creating thread]
09/11/09 12:10:53.038569 zmc_m10[-1].DB2-zm_rtsp.cpp/187 [RTSP Local SSRC is 354a093e]
09/11/09 12:10:53.038577 zmc_m10[-1].DB1-zm_thread.cpp/280 [Starting thread]
09/11/09 12:10:53.038681 zmc_m10[-1].DB2-zm_thread.cpp/253 [Invoking thread]
09/11/09 12:10:53.069164 zmc_m10[-1].DB2-zm_rtsp.cpp/46 [Sending RTSP message: DESCRIBE rtsp://10.110.6.28:554/live/mpeg4 RTSP/1.0
Authorization: Basic YWRtaW46YWRtaW4=
User-Agent: ZoneMinder/1.24.2
CSeq: 1

]
09/11/09 12:10:53.069438 zmc_m10[-1].DB1-zm_thread.cpp/301 [Started thread -1]
09/11/09 12:10:53.080515 zmc_m10[-1].DB1-zm_monitor.cpp/338 [monitor purpose=1]
09/11/09 12:10:53.080556 zmc_m10[-1].DB1-zm_monitor.cpp/345 [mem.size=48662004]
09/11/09 12:10:53.286649 zmc_m10[-1].DB1-zm_zone.cpp/50 [Initialised zone 0/All - 1 - 704x576 - Rgb:ff0000, CM:3, MnAT:15, MxAT:0, MnAP:50, MxAP:75000, FB:3x3, MnFP:50, MxFP:50000, MnBS:10, MxBS:0, MnB:0, MxB:0, OF: 0]
09/11/09 12:10:53.292910 zmc_m10[-1].DB1-zm_monitor.cpp/458 [Monitor 10 has function 2]
09/11/09 12:10:53.292970 zmc_m10[-1].DB1-zm_monitor.cpp/459 [Monitor 10 LBF = '%N - %y/%m/%d %H:%M:%S', LBX = 0, LBY = 0]
09/11/09 12:10:53.292978 zmc_m10[-1].DB1-zm_monitor.cpp/460 [Monitor 10 IBC = 40, WUC = 25, pEC = 10, PEC = 10, EAF = 1, FRI = 1000, RBP = 7, FM = 0]
09/11/09 12:10:53.293128 zmc_m10[-1].DB1-zm_zone.cpp/889 [Got 1 zones for monitor 10]
09/11/09 12:10:53.293140 zmc_m10[-1].DB3-zm_zone.cpp/758 [Parsing polygon string '0,0 703,0 703,575 0,575']
09/11/09 12:10:53.293146 zmc_m10[-1].DB3-zm_zone.cpp/796 [Got coordinate 0,0 from polygon string]
09/11/09 12:10:53.293152 zmc_m10[-1].DB3-zm_zone.cpp/796 [Got coordinate 703,0 from polygon string]
09/11/09 12:10:53.293157 zmc_m10[-1].DB3-zm_zone.cpp/796 [Got coordinate 703,575 from polygon string]
09/11/09 12:10:53.293161 zmc_m10[-1].DB3-zm_zone.cpp/796 [Got coordinate 0,575 from polygon string]
09/11/09 12:10:53.293169 zmc_m10[-1].DB3-zm_zone.cpp/816 [Successfully parsed polygon string]
09/11/09 12:10:53.293176 zmc_m10[-1].DB1-zm_zone.cpp/50 [Initialised zone 10/All - 1 - 704x576 - Rgb:ff0000, CM:3, MnAT:25, MxAT:0, MnAP:12165, MxAP:304128, FB:3x3, MnFP:12165, MxFP:304128, MnBS:8110, MxBS:0, MnB:1, MxB:0, OF: 0]
09/11/09 12:10:53.385226 zmc_m10[-1].DB1-zm_monitor.cpp/2459 [Loaded monitor 10(10), 1 zones]
09/11/09 12:10:53.385261 zmc_m10[-1].INF-zmc.cpp/188 [Starting Capture]
09/11/09 12:10:53.385420 zmc_m10[-1].DB2-zm_remote_camera_rtsp.cpp/112 [Waiting for sources]
09/11/09 12:10:54.069375 zmc_m10[-1].DB2-zm_rtsp.cpp/72 [Received RTSP response: RTSP/1.0 200 OK
CSeq: 1
Content-Base: rtsp://10.110.6.28:554/live/mpeg4/
Content-Type: application/sdp
Content-Length: 225

v=0
o=- 1 1 IN IP4 127.0.0.1
s=Test
a=type:broadcast
t=0 0
c=IN IP4 0.0.0.0
m=video 0 RTP/AVP 96
a=rtpmap:96 MP4V-ES/90000
a=fmtp:96 profile-level-id=3;config=00000100000001200086C4007B0C581120518F
a=control:track0
 (355 bytes)]
09/11/09 12:10:54.069485 zmc_m10[-1].DB1-zm_rtsp.cpp/304 [Processing SDP 'v=0
o=- 1 1 IN IP4 127.0.0.1
s=Test
a=type:broadcast
t=0 0
c=IN IP4 0.0.0.0
m=video 0 RTP/AVP 96
a=rtpmap:96 MP4V-ES/90000
a=fmtp:96 profile-level-id=3;config=00000100000001200086C4007B0C581120518F
a=control:track0
']
09/11/09 12:10:54.069533 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 'v=0']
09/11/09 12:10:54.069556 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 'o=- 1 1 IN IP4 127.0.0.1']
09/11/09 12:10:54.069568 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 's=Test']
09/11/09 12:10:54.069574 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 'a=type:broadcast']
09/11/09 12:10:54.069595 zmc_m10[-1].DB3-zm_sdp.cpp/259 [Ignoring general SDP attribute 'type:broadcast']
09/11/09 12:10:54.069602 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 't=0 0']
09/11/09 12:10:54.069608 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 'c=IN IP4 0.0.0.0']
09/11/09 12:10:54.069743 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 'm=video 0 RTP/AVP 96']
09/11/09 12:10:54.069762 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 'a=rtpmap:96 MP4V-ES/90000']
09/11/09 12:10:54.069774 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 'a=fmtp:96 profile-level-id=3;config=00000100000001200086C4007B0C581120518F']
09/11/09 12:10:54.069792 zmc_m10[-1].DB3-zm_sdp.cpp/126 [Processing SDP line 'a=control:track0']
09/11/09 12:10:54.070118 zmc_m10[-1].DB1-zm_sdp.cpp/305 [Looking for codec for video payload type 96 / MP4V-ES]
09/11/09 12:10:54.070131 zmc_m10[-1].DB1-zm_sdp.cpp/334 [Got dynamic payload type 96, MP4V-ES]
09/11/09 12:10:54.070145 zmc_m10[-1].DB2-zm_rtsp.cpp/46 [Sending RTSP message: SETUP rtsp://10.110.6.28:554/live/mpeg4/track0 RTSP/1.0
Transport: RTP/AVP/TCP;unicast
Authorization: Basic YWRtaW46YWRtaW4=
User-Agent: ZoneMinder/1.24.2
CSeq: 2

]
09/11/09 12:10:54.285279 zmc_m10[-1].DB2-zm_rtsp.cpp/72 [Received RTSP response: RTSP/1.0 200 OK
CSeq: 2
Transport: RTP/AVP/TCP;unicast;interleaved=0-1
Session: 471A30A869D18F809F9FF95E4B73E4

 (117 bytes)]
09/11/09 12:10:54.285427 zmc_m10[-1].DB2-zm_rtsp.cpp/396 [Got RTSP session 471A30A869D18F809F9FF95E4B73E4, timeout 0 secs]
09/11/09 12:10:54.285440 zmc_m10[-1].DB2-zm_rtsp.cpp/401 [Got RTSP transport RTP/AVP/TCP;unicast;interleaved=0-1]
09/11/09 12:10:54.285486 zmc_m10[-1].DB2-zm_rtsp.cpp/449 [RTSP Method is RTP/RTSP]
09/11/09 12:10:54.285492 zmc_m10[-1].DB2-zm_rtsp.cpp/450 [RTSP Distribution is unicast]
09/11/09 12:10:54.285496 zmc_m10[-1].DB2-zm_rtsp.cpp/451 [RTSP SSRC is 0]
09/11/09 12:10:54.285501 zmc_m10[-1].DB2-zm_rtsp.cpp/452 [RTSP Local Host is ]
09/11/09 12:10:54.285505 zmc_m10[-1].DB2-zm_rtsp.cpp/453 [RTSP Local Ports are 0/0]
09/11/09 12:10:54.285510 zmc_m10[-1].DB2-zm_rtsp.cpp/454 [RTSP Remote Ports are 0/0]
09/11/09 12:10:54.285514 zmc_m10[-1].DB2-zm_rtsp.cpp/455 [RTSP Remote Channels are 0/1]
09/11/09 12:10:54.285528 zmc_m10[-1].DB2-zm_rtsp.cpp/46 [Sending RTSP message: PLAY rtsp://10.110.6.28:554/live/mpeg4 RTSP/1.0
Session: 471A30A869D18F809F9FF95E4B73E4
Range: npt=0.000-
Authorization: Basic YWRtaW46YWRtaW4=
User-Agent: ZoneMinder/1.24.2
CSeq: 3

]
09/11/09 12:10:54.291837 zmc_m10[-1].DB2-zm_rtsp.cpp/72 [Received RTSP response: RTSP/1.0 200 OK
CSeq: 3
Session: 471A30A869D18F809F9FF95E4B73E4

 (69 bytes)]
09/11/09 12:10:54.292025 zmc_m10[-1].FAT-zm_rtsp.cpp/471 [Unable to get RTP Info identifier from response 'RTSP/1.0 200 OK
CSeq: 3
Session: 471A30A869D18F809F9FF95E4B73E4

']
09/11/09 12:10:54.292347 zmc_m10[-1].INF-zm_signal.cpp/64 [Got signal 6 (Aborted), exiting and forcing backtrace]
09/11/09 12:10:54.292375 zmc_m10[-1].ERR-zm_signal.cpp/90 [Signal address is 0x206, no eip]
09/11/09 12:10:54.292665 zmc_m10[-1].ERR-zm_signal.cpp/122 [Backtrace: /lib/libpthread.so.0 [0x7f7372c8a080]]
09/11/09 12:10:54.292681 zmc_m10[-1].ERR-zm_signal.cpp/122 [Backtrace: /lib/libc.so.6(gsignal+0x35) [0x7f7371b6ffb5]]
09/11/09 12:10:54.292692 zmc_m10[-1].ERR-zm_signal.cpp/122 [Backtrace: /lib/libc.so.6(abort+0x183) [0x7f7371b71bc3]]
09/11/09 12:10:54.292702 zmc_m10[-1].ERR-zm_signal.cpp/122 [Backtrace: /usr/bin/zmc [0x40f3f0]]
09/11/09 12:10:54.292713 zmc_m10[-1].ERR-zm_signal.cpp/122 [Backtrace: /usr/bin/zmc [0x440ff2]]
09/11/09 12:10:54.292724 zmc_m10[-1].ERR-zm_signal.cpp/122 [Backtrace: /usr/bin/zmc [0x44ba15]]
09/11/09 12:10:54.292734 zmc_m10[-1].ERR-zm_signal.cpp/122 [Backtrace: /lib/libpthread.so.0 [0x7f7372c823ba]]
09/11/09 12:10:54.292744 zmc_m10[-1].ERR-zm_signal.cpp/122 [Backtrace: /lib/libc.so.6(clone+0x6d) [0x7f7371c22fcd]]
09/11/09 12:10:54.292755 zmc_m10[-1].INF-zm_signal.cpp/125 [Backtrace complete, please execute the following command for more information]
09/11/09 12:10:54.292975 zmc_m10[-1].INF-zm_signal.cpp/126 [addr2line -e /lib/libc.so.6(clone+0x6d) 0x7f7372c8a080 0x7f7371b6ffb5 0x7f7371b71bc3 0x40f3f0 0x440ff2 0x44ba15 0x7f7372c823ba 0x7f7371c22fcd]
Anyone have ideas howto fix this?

Posted: Thu Oct 15, 2009 6:39 am
by doctorphish
I am also experiencing the same problem with a TP-LINK TL-SC3000 camera; I can get RTSP working in VLC, but not in zoneminder.

Is the form username:password@hostname not valid for rtsp in zoneminder, perhaps?

I'd love to document how to get this camera working in zoneminder, as it is very inexpensive and has suprisingly good build quality.

Posted: Thu Oct 15, 2009 1:46 pm
by ThomasNovin
doctorphish wrote:I am also experiencing the same problem with a TP-LINK TL-SC3000 camera; I can get RTSP working in VLC, but not in zoneminder.

Is the form username:password@hostname not valid for rtsp in zoneminder, perhaps?

I'd love to document how to get this camera working in zoneminder, as it is very inexpensive and has suprisingly good build quality.
Just try without username and password and you will know :)

Posted: Thu Oct 15, 2009 2:15 pm
by doctorphish
ThomasNovin wrote: Just try without username and password and you will know :)
Unfortunately, it doesn't work without them either. It appears to need some kind of authentication to work with rtsp.

Quicktime also prompts for a username and password if used to view the camera.

Posted: Thu Oct 15, 2009 2:25 pm
by ThomasNovin
doctorphish wrote:
ThomasNovin wrote: Just try without username and password and you will know :)
Unfortunately, it doesn't work without them either. It appears to need some kind of authentication to work with rtsp.

Quicktime also prompts for a password if used to view the camera.
Ok maybe I was a bit unclear. First disable password on the camera so it works without and then try without in ZM.

Posted: Thu Oct 15, 2009 4:46 pm
by doctorphish
ThomasNovin wrote: Ok maybe I was a bit unclear. First disable password on the camera so it works without and then try without in ZM.
Alright, now I've got what you are saying.

I reconfigured the camera to allow anonymous viewers, and VLC will now work without the username/password stuff in the URL, but ZM still doesn't give me any images. I've tried all the different RTSP options, but nothing seems to make any difference. I even tried starting with templates for other cameras that looked similar. Any ideas?

My current settings are:

Remote Protocol: RTSP
Remote Method: RTP/Unicast (I've tried all the others)
Remote host name and host port are correct and verified with nmap
Remote Host path: /live/mpeg4
Remote Host SubPath: Blank (what is the difference, anyways?)
Colours/Resolution/etc are verified and correct

Help!

Posted: Fri Nov 13, 2009 6:45 am
by doctorphish
Bumping. I'm going to try and figure this out myself eventually if no one else wants to give me a hand, but any help would certainly make the process easier!

Posted: Sat Nov 14, 2009 12:28 am
by TechGuy
doctorphish wrote:Bumping. I'm going to try and figure this out myself eventually if no one else wants to give me a hand, but any help would certainly make the process easier!
See if you can make it work using ffmpeg (ie ffmpeg -i rtsp://username:pw@192.168.x.x:port /tmp/out.avi

if it works, change the source type to ffmpeg and use the source path you used for ffmpeg.