Re-Streaming Difficulties

*nix specific usage questions
VDIEng
New Cone
New Cone
Posts: 8
Joined: 02 Mar 2011 11:58

Re-Streaming Difficulties

Postby VDIEng » 24 Mar 2011 22:04

I have a Panasonic WV-SC385 camera that is broadcasting RTSP H264 @ 4096K with G711 audio. I need VLC to restream the live stream in near real time. Here is the command line I am using.

Code: Select all

cvlc -vv rtsp://10.0.2.5/MediaInput/h264 --sout "#transcode{acodec=mpga, ab=128, channels=2,samplerate=44100} :udp{dst=239.0.0.6:5004,mux=ts}" --rtsp-caching=1600 :no-sout-rtp-sap :no-sout-standard-sap --sout-keep
I am only transcoding the audio portion from G711 to MPGA, I am remuxing the package to TS for playback on Aminos.

I am running VLC 1.1.7 on Fedora 14, 4GB of Ram, Xeon 4C 2.4ghz. Hoping 1.1.18 will be uploaded to the RPM Fusion in the next day or two.

I get occasional picture freezes (up to 2 seconds) and audio distortions (grich sounds). I need to have these removed from the stream. I am looking for recommendations on how to modify my command line to increase the quality of the stream. As you can see by the log below I am having constant problems with packets being late or late buffers on the input mux. Is there a way to allocate more memory for buffering?

I have set the nice of the VLC process to -17. There are no other services running on this machine.

Code: Select all

[0xb72022a4] access_output_udp access out debug: packet has been sent too late (1212854) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1205447) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1198039) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1190631) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1183232) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1175831) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1168433) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1161054) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1153654) [0xb72035c4] main mux warning: late buffer for mux input (1212867) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1146252) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1138853) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1131453) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (863599) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1124053) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (857415) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (977458) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (973082) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (968699) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (964314) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (959930) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1241127) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (955546) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (951170) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (946787) [0xb72022a4] access_output_udp access out debug: late packet for UDP input (942403) [0xb72022a4] access_output_udp access out debug: packet has been sent too late (1233745)
If you need more log file please let me know.

Thanks,

Tim

VDIEng
New Cone
New Cone
Posts: 8
Joined: 02 Mar 2011 11:58

Re: Re-Streaming Difficulties

Postby VDIEng » 04 Apr 2011 14:52

Well after quite some time I have gotten the performance to a near acceptable level. I still get video and audio hits on the output side of the stream as it is passed to the amino.

Here is the complete command line I am using:

Code: Select all

cvlc -vvv rtsp://10.0.2.5/MediaInput/h264 --sout '#transcode{acodec=a52,ab=128,channels=1,samplerate=44100}:udp{mux=ts,dst=239.0.0.6:5004}' :no-sout-rtp-sap :no-sout-standard-sap :ttl=1 :sout-keep
I have my input buffer at 5000ms and it seems to be working really well

I am still receiving errors on the output side

Code: Select all

[0xb7102204] access_output_udp access out debug: packet has been sent too late (260396) [0xb7102204] access_output_udp access out debug: packet has been sent too late (242191) [0xb7102204] access_output_udp access out debug: packet has been sent too late (224002) [0xb7102204] access_output_udp access out debug: packet has been sent too late (205802) [0xb7102204] access_output_udp access out debug: packet has been sent too late (187614) [0xb7102204] access_output_udp access out debug: packet has been sent too late (169412) [0xb7102204] access_output_udp access out debug: packet has been sent too late (151207) [0xb7102204] access_output_udp access out debug: packet has been sent too late (133003) [0xb7102204] access_output_udp access out debug: packet has been sent too late (114796) [0xb7102204] access_output_udp access out debug: packet has been sent too late (96588) [0xb7102204] access_output_udp access out debug: packet has been sent too late (78379) [0xb7102204] access_output_udp access out debug: packet has been sent too late (60173) [0xb7102204] access_output_udp access out debug: packet has been sent too late (41964) [0xb7102204] access_output_udp access out debug: packet has been sent too late (23757) [0xb7102204] access_output_udp access out debug: mmh, packets in the past (44975) [0xb7102204] access_output_udp access out debug: packet has been sent too late (45342) [0xb7102204] access_output_udp access out debug: packet has been sent too late (39063) [0xb7102204] access_output_udp access out debug: packet has been sent too late (32780) [0xb7102204] access_output_udp access out debug: packet has been sent too late (26412) [0xb7102204] access_output_udp access out debug: packet has been sent too late (20032) [0xb710359c] mux_ts mux debug: adjusting rate at -149724/205276 (186/11) [0xb710359c] mux_ts mux debug: adjusting rate at -576454/227995 (29/173) [0xb710359c] mux_ts mux debug: adjusting rate at -804449/231087 (200/16) [0xb710359c] mux_ts mux debug: adjusting rate at -27128/314521 (32/8) [0xb710359c] mux_ts mux debug: adjusting rate at 112487/460582 (46/1) [0xb710359c] mux_ts mux debug: adjusting rate at -127372/750738 (4/12) [0xb710359c] mux_ts mux debug: adjusting rate at 127372/878110 (7/5) [0xb7102204] access_output_udp access out warning: putting two PCRs at once [0xb7102204] access_output_udp access out warning: putting two PCRs at once [0xb710359c] mux_ts mux debug: adjusting rate at 0/750738 (3/2) [0xb710359c] mux_ts mux debug: adjusting rate at 0/332000 (34/1) [0xb7102204] access_output_udp access out warning: putting two PCRs at once [0xb7102204] access_output_udp access out warning: putting two PCRs at once [0xb710359c] mux_ts mux warning: packet with too strange dts (dts=337006063908,old=337006160086,pcr=337006160086) [0xb710359c] mux_ts mux warning: packet with too strange dts (dts=337005953376,old=337006920363,pcr=337006920363)
What CLI parms can I test to reduce the packet sent late issue?

Thanks Tim

mmorier
New Cone
New Cone
Posts: 3
Joined: 28 Feb 2012 19:58

Re: Re-Streaming Difficulties

Postby mmorier » 28 Feb 2012 20:45

Hi,

I also go a setup like you ...

We start VLC as a deamond and use this conf ;

Code: Select all

new camera1 broadcast enabled setup camera1 input rtsp://10.240.243.6:554/live/ch01_0 setup camera1 output #standard{access=udp{ttl=16,caching=3000},mux=ts,dst=239.195.18.251:5251} control camera1 play
We take video from a UBIQUITI AirCam and stream it to the local iptv network where we have Amino STB.

Currently as a one liner it will be this

Code: Select all

cvlc -d -vvv rtsp://10.240.243.6:554/live/ch00_0 --sout '#std{access=udp{ttl=16,caching=3000},mux=ts,dst=239.195.18.251:5251}' -I telnet --telnet-password videolan --sout-mux-caching=5000
All work fine ( except some error VLC report ) and image seem ok on the Amino STB, but after 20 minutes, VLC seem to have problem ...

Here is the error VLC got;

Code: Select all

access_output_udp debug: packet has been sent too late (771129) access_output_udp debug: late packet for UDP input (357255) access_output_udp debug: late packet for UDP input (305353) access_output_udp debug: late packet for UDP input (281197) access_output_udp debug: late packet for UDP input (257038) access_output_udp debug: late packet for UDP input (232879) access_output_udp debug: late packet for UDP input (208724) access_output_udp debug: late packet for UDP input (184565) access_output_udp debug: late packet for UDP input (160404) access_output_udp debug: late packet for UDP input (136245) access_output_udp debug: late packet for UDP input (112086) main warning: late buffer for mux input (3345137) main warning: late buffer for mux input (3312560) main warning: late buffer for mux input (3280083) main warning: late buffer for mux input (3247514) main warning: late buffer for mux input (3215011) main warning: late buffer for mux input (3182387) main warning: late buffer for mux input (3149818) access_output_udp debug: late packet for UDP input (88305) access_output_udp debug: late packet for UDP input (63492) access_output_udp debug: late packet for UDP input (38185) access_output_udp debug: late packet for UDP input (12878) main warning: late buffer for mux input (3117645) main warning: late buffer for mux input (3085077) access_output_udp debug: packet has been sent too late (750200) main warning: late buffer for mux input (3052607) main warning: late buffer for mux input (3020101) main warning: late buffer for mux input (2987455) main warning: late buffer for mux input (2955019) main warning: late buffer for mux input (2922362) main warning: late buffer for mux input (2890138) main warning: late buffer for mux input (2857540) main warning: late buffer for mux input (2825070) main warning: late buffer for mux input (2792535) main warning: late buffer for mux input (2759867) main warning: late buffer for mux input (2727468) main warning: late buffer for mux input (2694813) main warning: late buffer for mux input (2662570) main warning: late buffer for mux input (2629979) main warning: late buffer for mux input (2597509)
If I check the TX and RX of the network port of the switch where my vlc server are ... the TX stay the same ( camera to Cent-Os machine running VLC )
But the RX ( VLC multicast to STB ) get down to near nothing every 10 seconds.

So I am starting to have image trouble after this 20 min

Any clue ?

mmorier
New Cone
New Cone
Posts: 3
Joined: 28 Feb 2012 19:58

Re: Re-Streaming Difficulties

Postby mmorier » 28 Feb 2012 21:41

Here is an example of VLC after 20 minutes ...

Image

The blue line is the data from the camera to the cent-os server

The Green line the the multicast output by the VLC on this server.

If I kill the VLC process and start it the two line will be side by side for 20 minutes ...

Or if I telnet to the process and do a " control camera1 stop / control camera1 play " I am OK for at least 20 minutes

Image

and after I will still got the problem ...

djsashaz
Blank Cone
Blank Cone
Posts: 16
Joined: 14 Feb 2008 23:27

Re: Re-Streaming Difficulties

Postby djsashaz » 20 Jun 2012 21:20

Did you ever solve this? I have a simlar yet differnet issue, maybe your solution will solve it.


Return to “VLC media player for Linux and friends Troubleshooting”

Who is online

Users browsing this forum: Google [Bot] and 21 guests