Skip to main content

Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient thread locking around avcodec_open/close()

27 posts / 0 new
Last post
mrcrowley
Offline
Joined: 09/20/2010
Posts:
Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient thread locking around avcodec_open/close()

The project is an HD 1080p 25 fps of 18 minutes. Kdenlive 0.8.3, KDE 4.7.3.

I try with File Rendering MP4 (various bitrate) and I get the message in the subject.

I also try with H.264 (various bitrate) and the job stop at 20%.

I also try with Lossless / HQ (h.264 and mp4) with same result.

Anyone can help me ??

bye bye

0
Your rating: None
mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Nobody can help me ???

Is this a problem with memory ?? I have 4Gb and I see they are all used the same way as the cpu.

Bye

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Any idea ?? Installed all the libraries required but nothing change.

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Is there anybody from devolpment team that can help with this problem ????

I see many people hanging with this error messages. Is there a solution or not ???

Bye bye

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

More error message:

Rendering file /media/Video/compleanno.mp4 crash
[NULL @ 0x58d3220] insufficient thread locking around avcodec_open/close()
[NULL @ 0x58d9500] insufficient thread locking around avcodec_open/close()
consumer_avformat.c: Unable to encode audio - disabling audio output.
[mp4 @ 0x14c9a40] track 1: codec frame size is not set

j-b-m
Offline
Joined: 05/19/2009
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Hi.

First, please check the settings of MLT processing threads, it is in Kdenlive Settings dialog > Environment > Processing threads (the setting at the bottom). Make sure it is set to 1, and try rendering again if its value was > 1.

Otherwise, one good way to debug rendering issues is to render to script instead of rendering to file.
This creates a bash script in $HOME/kdenlive/scripts that can be run from a terminal.

Then, run the script with:

sh -x ./script001.sh

That might give us some more infos. Also, are you using FFmpeg and libx264 from your distro's official packages?

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

First of all I thank you for your help.

MLT processing threads is set = 1.

When I run the script with sh -x ./script001.sh, I get "sh: Can't open ./script001.sh"

FFmpeg is origin from Ubuntu version 4:0.7.2-1 ubuntu1

libx264 is from Ubuntu too and version is 2:0.116.2042+git178455c-1ubuntu1

Thank you a lot !!!
Max

j-b-m
Offline
Joined: 05/19/2009
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Well, if you did use the "Generate script" option in render dialog, it should have told you that a file called script00x.sh was created (where x can be any number). Keep that name and then in a terminal, go to the script directory:

cd $HOME/kdenlive/scripts

And then you can run the script:

sh -x ./script001.sh (replace script001.sh with the name that was given when you did generate the script)

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

it was written Script001.sh :-/

this is the result:

+ SOURCE=/media/Video/kdenlive/scripts/Script002.sh.mlt
+ TARGET=file:///media/Video/compleanno.mp4
+ RENDERER=/usr/bin/kdenlive_render
+ MELT=/usr/bin/melt
+ PARAMETERS=-pid:4289 /usr/bin/melt atsc_1080p_25 avformat - /media/Video/kdenlive/scripts/Script002.sh.mlt file:///media/Video/compleanno.mp4 f=mp4 acodec=libmp3lame ab=384k ar=44100 vcodec=mpeg4 minrate=0 vb=18000k aspect=@16/9 mbd=2 trellis=1 mv4=1 pass=2 threads=1 real_time=-1
+ /usr/bin/kdenlive_render -pid:4289 /usr/bin/melt atsc_1080p_25 avformat - /media/Video/kdenlive/scripts/Script002.sh.mlt file:///media/Video/compleanno.mp4 f=mp4 acodec=libmp3lame ab=384k ar=44100 vcodec=mpeg4 minrate=0 vb=18000k aspect=@16/9 mbd=2 trellis=1 mv4=1 pass=2 threads=1 real_time=-1
//STARTING RENDERING: false , false , "/usr/bin/melt" , "atsc_1080p_25" , "avformat" , "-" , "/media/Video/kdenlive/scripts/Script002.sh.mlt" , "/media/Video/compleanno.mp4" , () , ("f=mp4", "acodec=libmp3lame", "ab=384k", "ar=44100", "vcodec=mpeg4", "minrate=0", "vb=18000k", "aspect=@16/9", "mbd=2", "trellis=1", "mv4=1", "pass=1", "threads=1", "real_time=-1") , -1 , -1
Started render process: "/usr/bin/melt" "/media/Video/kdenlive/scripts/Script002.sh.mlt -profile atsc_1080p_25 -consumer avformat:/media/Video/compleanno.mp4 progress=1 f=mp4 acodec=libmp3lame ab=384k ar=44100 vcodec=mpeg4 minrate=0 vb=18000k aspect=@16/9 mbd=2 trellis=1 mv4=1 pass=1 threads=1 real_time=-1"
Rendering of "/media/Video/compleanno.mp4" finished
Started render process: "/usr/bin/melt" "/media/Video/kdenlive/scripts/Script002.sh.mlt -profile atsc_1080p_25 -consumer avformat:/media/Video/compleanno.mp4 progress=1 f=mp4 acodec=libmp3lame ab=384k ar=44100 vcodec=mpeg4 minrate=0 vb=18000k aspect=@16/9 mbd=2 trellis=1 mv4=1 pass=2 threads=1 real_time=-1"
"Rendering of /media/Video/compleanno.mp4 aborted, resulting video will probably be corrupted."

Thank you.

j-b-m
Offline
Joined: 05/19/2009
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Ok, so now can you try this command:

melt -debug /media/Video/kdenlive/scripts/Script002.sh.mlt -profile atsc_1080p_25 -consumer avformat:/media/Video/compleanno.mp4 progress=1 f=mp4 acodec=libmp3lame ab=384k ar=44100 vcodec=mpeg4 minrate=0 vb=18000k aspect=@16/9 mbd=2 trellis=1 mv4=1 pass=2 threads=1 real_time=-1

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

I see a lot of lines. What do I have to search for ????
What I have to let you know ???

j-b-m
Offline
Joined: 05/19/2009
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Well, it should crash at 20% like when you start it from Kdenlive. You could post the last lines before the crash...

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

[consumer avformat] stopping put waiting
[consumer avformat] stopping consumer
[producer avformat] /media/Video/2011/Compleanno Matteo/00026.MTS
mlt_service_cache_get: name producer_avformat object 0x30fe670
mlt_cache_get: get 9 = 0x30fe670, 0x7f37484cd240
[filter deinterlace] previous -1 current 27025 next -1
[consumer avformat] stopping read_ahead
[filter deinterlace] error 0 deint 1 prog 1 fmt yuv422 method yadif
[filter resample] channels 2 samples 1920 frequency 48000 -> 44100
[filter audioconvert] s16 -> float 2 channels 1920 samples
[filter audioconvert] float -> s16 2 channels 1764 samples
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 29
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 28
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 27
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 26
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 25
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 24
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 23
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 22
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 21
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 20
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 19
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 18
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 17
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 16
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 15
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 14
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 13
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 12
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 11
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 10
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 9
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 8
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 7
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 6
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 5
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 4
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 3
cache_object_close: item 0x2ed7c70 object 0x30fe670 data 0x7f37484cd240 refcount 2
[consumer avformat] stopped
cache_object_close: item 0x25f9fd0 object 0x282b890 data 0x6498e10 refcount 1
producer_avformat_close
mlt_cache_close: 9 = 0x1718
cache_object_close: item 0x7f37483bf880 object 0x900 data 0x7f3746bfb020 refcount 1
mlt_cache_close: 0 = 0x8ff
cache_object_close: item 0x7f37480b79c0 object 0x8ff data 0x7f373ffe0020 refcount 1
[consumer avformat] stopping put waiting
[consumer avformat] stopping consumer
[consumer avformat] stopping read_ahead
[consumer avformat] stopped

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

[filter deinterlace] error 0 deint 1 prog 1 fmt yuv422 method yadif

Is this the cause of the crash ???

bye

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Hello ???

No reply ???

Did you forget it ???

j-b-m
Offline
Joined: 05/19/2009
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

It's not easy to follow all issues, sometimes people solve their problem without further notice, so on the forums, it is sometimes needed to ask for updates or I might not follow.

From your FFmpeg version, I guess you are on Ubuntu 11.10, right? I tried to render a simple video file in mpeg4 and h264, it worked fine.

Can you try this:

Start a new project, put just one file in it (for example the file /media/Video/2011/Compleanno Matteo/00026.MTS mentionned in the previous log) and try to render just that file or a part of it in mpeg4 and h264.

Does it work? Then maybe there is one file in your project that triggers the bug.. If the rendering crashes around 20%, might be worth looking at what is in timeline around that time.

You could also try to render the last 50% of your project (using the timeline zone) to see if the problem is related to a part of your project.

Anyways, if a simple rendering works, try to remove clips one by one from your project until you find what is the problem...

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

No problem. I understand you and I thank u however for helping me.

I had already tried with one file and it works without problem.

That's very strange because all the files are from the same cam at the same setting.

Bytheway I notice that one videoclip in the project (the last one added, not at 20% of progress) wasn't played. Video stopped while audio play on.

Bye bye.

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

I did some test. It seems that there is a problem with the duration of the project that should be rendered.
Rendering the first half of the project works well. Rendering the second half of the project works well.
So the problem is at 50% of the project, but is not one clip problem, because if I cancel this clip from timeline, the rendering doesn't complete anyway.
So I have to split the main project of about 20 minutes in two project.

Another strange thing is: when I choose to Adjust Profile to Current Clip from menu Project, I got an error message "Your clip does not match current project's profile.
No existing profile found to match the clip's properties.
Clip size: 1920x1088
Fps: 25"

This could be the reason for the rendering problems ???

Bye

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

No tip ????

normcross
Offline
Joined: 04/02/2011
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

I had a slightly similar problem and this may not be related, but, have you any music in your audio timelines? If so, disable all audio and try to render again.

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Only the audio of the clip.

bye

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Sorry j-b-m, I would only like to know if there is something to do so I can rendering just one project and not split two ???

Regards.

normcross
Offline
Joined: 04/02/2011
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

I see that you are using Kdenlive 0.8.3 which I assume you got from here:-

https://launchpad.net/~sunab/+archive/kdenlive-svn

There was a new update yesterday which seems to have stopped my crashing on 2 pass rendering.

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

No. I really use Kdenlive 0.8.2.1 because I have more problem with 0.8.3.

Should I give one more try to kdenlive-svn +MLT-git ???

Do I have to disinstall 0.8.2.1 first ???

Thanks

j-b-m
Offline
Joined: 05/19/2009
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

On Ubuntu, it's really easy to try the current development package. Just add the kdenlive-svn PPA as explained in:
https://launchpad.net/~sunab/+archive/kdenlive-svn (don't remove the kdenlive-release ppa)

Then, your package manager will show you an update for MLT and Kdenlive.

If you later want to revert to the stable 0.8.2.1, just do:

ppa-purge ppa:sunab/kdenlive-svn (you might need to install ppa-purge)

It will remove the kdenlive-svn repository from your sources and downgrade to the kdenlive-release version

mrcrowley
Offline
Joined: 09/20/2010
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

With 0.8.3 it's getting worst ... it doesn't even start the rendering. It crashes immediatly.

I don't know where to crash my head !!! It's incredible !!!! No way out !!!!

normcross
Offline
Joined: 04/02/2011
Posts:
Re: Rendering aborted: [h264 @ 0x7f1ef800d5e0] insufficient ...

Hi mrcrowley,

It really is time for you to take this issue to the Bugtracker:- http://kdenlive.org/mantis (if you haven't already)

It seems to be filling with similar problems and at this rate, you'll have no hair left :)