Linux Kodi 15.1 Starts but screen freezes.
#1
Hello

Pre-story:
This has some prestory. I have already started posting about my problem here and also in the arch linux forum here.

As it turns out, my problem is not the same as the threads authors. The Arch Linux People have already created a newly packed version of Kodi fixing the problems occurring due to the use of gcc5.2. However I currently try to run this fixed version (packed with gcc5.1) of the kodi binary and it does not work for me.

My problem:
Kodi does start up. I can hear the bing in the beginning and using upnp I can even send audio to it and it gets played back. However when Kodi starts, the screen freezes and I can not see anything. In fact the screen freezes completely. E.g. i can not change to another tty any more. To me it looks like the GPU is crashing. Deleting the userdata folder does not help.

A debug log can be found here

System:
Raspberry pi 2 with arch linux.
Kernel: 4.1.6-2
Kodi build for Arch Linux compiled with gcc5.1. Can be found here

Cheers
Reply
#2
tty switching is not expected to work while kodi is running (the EGL framebuffer runs on top of console framebuffers).

Seems to be an alsa/pulseaudio issue:
Code:
14:21:19 T:1936249648   DEBUG: CActiveAESink::OpenSink - ALSA Initialized:
14:21:19 T:1936249648   DEBUG:   Output Device : Device not found
14:21:19 T:1936249648   DEBUG:   Sample Rate   : 44100
14:21:19 T:1936249648   DEBUG:   Sample Format : AE_FMT_FLOAT
14:21:19 T:1936249648   DEBUG:   Channel Count : 2
14:21:19 T:1936249648   DEBUG:   Channel Layout: FL,FR
14:21:19 T:1936249648   DEBUG:   Frames        : 2205
14:21:19 T:1936249648   DEBUG:   Frame Samples : 4410
14:21:19 T:1936249648   DEBUG:   Frame Size    : 8
14:21:19 T:1936249648   ERROR: CAESinkALSA - snd_pcm_writei(-32) Broken pipe - trying to recover


Are you intending to use ALSA for audio (rather than inbuilt hdmi or analogue)?
Reply
#3
Yes I use a Hifiberry DAC+ for audio playback and I also like to configure some tunnels with Pulse Ausio for simultaneous playback.
Reply
#4
(2015-08-30, 23:25)Hohlefrucht Wrote: Yes I use a Hifiberry DAC+ for audio playback and I also like to configure some tunnels with Pulse Ausio for simultaneous playback.

Okay, that's not something I know about or can help with. Feel free to try, but you are in untested territory.
If you want to check if the main kodi install is working, then switch to the main hdmi (or analogue) sink and see if that works.
Reply
#5
(2015-08-31, 12:21)popcornmix Wrote: Okay, that's not something I know about or can help with. Feel free to try, but you are in untested territory.
If you want to check if the main kodi install is working, then switch to the main hdmi (or analogue) sink and see if that works.

Okay, I see but if Kodi uses ALSA, this setup should be no different from almost any other setup, except I use another sound card and the communication with the sound card should not be handled by Kodi since it is handled by ALSA and thus it should work. Am I right here?

Cheers
Reply
#6
(2015-08-30, 17:14)popcornmix Wrote: tty switching is not expected to work while kodi is running (the EGL framebuffer runs on top of console framebuffers).

Seems to be an alsa/pulseaudio issue:
Code:
14:21:19 T:1936249648   DEBUG: CActiveAESink::OpenSink - ALSA Initialized:
14:21:19 T:1936249648   DEBUG:   Output Device : Device not found
14:21:19 T:1936249648   DEBUG:   Sample Rate   : 44100
14:21:19 T:1936249648   DEBUG:   Sample Format : AE_FMT_FLOAT
14:21:19 T:1936249648   DEBUG:   Channel Count : 2
14:21:19 T:1936249648   DEBUG:   Channel Layout: FL,FR
14:21:19 T:1936249648   DEBUG:   Frames        : 2205
14:21:19 T:1936249648   DEBUG:   Frame Samples : 4410
14:21:19 T:1936249648   DEBUG:   Frame Size    : 8
14:21:19 T:1936249648   ERROR: CAESinkALSA - snd_pcm_writei(-32) Broken pipe - trying to recover

Are you intending to use ALSA for audio (rather than inbuilt hdmi or analogue)?

I managed to get rid of this error message, by disabling the hardware detection of pulse audio. However kodi still doesn't start. Here is a fresh debug log of such a start. Still think this has something to do with the audio?

Or is this still the same message, except the ERROR is missing?
Code:
07:04:37 T:1936810800   DEBUG: CAESinkALSA::GetChannelLayout - Got Layout: FL,FR (ALSA: none)
07:04:37 T:1936810800   DEBUG: CActiveAESink::OpenSink - ALSA Initialized:
07:04:37 T:1936810800   DEBUG:   Output Device : Device not found
07:04:37 T:1936810800   DEBUG:   Sample Rate   : 44100
07:04:37 T:1936810800   DEBUG:   Sample Format : AE_FMT_FLOAT
07:04:37 T:1936810800   DEBUG:   Channel Count : 2
07:04:37 T:1936810800   DEBUG:   Channel Layout: FL,FR
07:04:37 T:1936810800   DEBUG:   Frames        : 2205
07:04:37 T:1936810800   DEBUG:   Frame Samples : 4410
07:04:37 T:1936810800   DEBUG:   Frame Size    : 8
07:04:37 T:1950249536  NOTICE: Running database version Addons19
07:04:37 T:1950249536   DEBUG: SECTION:LoadDLL(special://xbmcbin/system/libcpluff-arm.so)
07:04:37 T:1950249536   DEBUG: Loading: /usr/lib/kodi/system/libcpluff-arm.so
07:04:37 T:1950249536   DEBUG: ADDON: cpluff: 'Plug-in xbmc.json has been installed.'


And here is a debug log, where Kodi actually started exactly the way I want it. This is mysterious. Why does it start sometimes and why not. What is the difference. However the above shown section appears in both logs. Thus I think, this is not and audio issue.


Using the kodi-rbp-git (v16) kodi does always start, however the bug due to the use of gcc v5.1 is currently valid for the build of kodi 16. Thus my confidence rises that this is not a bug problem with my audio setup.
Cheers
Reply
#7
This looks suspicious:
Code:
07:04:37 T:1936810800   DEBUG:   Output Device : Device not found
but I'm not sure if it's the cause of your problem.

If you switch to HDMI audio does kodi start every time?

Can you spot the first difference in log between the good boot and the bad boot?
Reply
#8
Deleting the .kodi folder allowed me to start kodi one time. The next time it didint work and I can not reproduce this behavior. So changing to hdmi sound output does not help no.

I created a version of the failed log and the successful log that can be compared with a diff tool ( I use meld). I have compared both log files, but I'm not able to spot many differences. The first difference is the order of a few lines.

Failed:
Code:
DEBUG: Loading: libopenmaxil.so
OTICE: Raspberry PI firmware version: Aug 20 2015 17:44:52
                    Copyright (c) 2012 Broadcom
                    version 3f87086448257aa66881de858a0b4b0e6daa8719 (clean) (release)
OTICE: ARM mem: 752MB GPU mem: 256MB MPG2:1 WVC1:0
OTICE: Thread CRBPWorker start, auto delete: false

Success:
Code:
OTICE: Thread CRBPWorker start, auto delete: false
OTICE: Raspberry PI firmware version: Aug 20 2015 17:44:52
                    Copyright (c) 2012 Broadcom
                    version 3f87086448257aa66881de858a0b4b0e6daa8719 (clean) (release)
OTICE: ARM mem: 752MB GPU mem: 256MB MPG2:1 WVC1:0

I doubt this has any impact.

Next are a bunch of memory addresses.
Failed:
Code:
DEBUG: GUI Shader [guishader_frag_default.glsl]- Initialise successful : 0x36ee3f8
DEBUG: GUI Shader [guishader_frag_texture.glsl]- Initialise successful : 0x361fa20
DEBUG: GUI Shader [guishader_frag_multi.glsl]- Initialise successful : 0x36599e8
DEBUG: GUI Shader [guishader_frag_fonts.glsl]- Initialise successful : 0x365d2f0
DEBUG: GUI Shader [guishader_frag_texture_noblend.glsl]- Initialise successful : 0x3640900
DEBUG: GUI Shader [guishader_frag_multi_blendcolor.glsl]- Initialise successful : 0x3718d50
DEBUG: GUI Shader [guishader_frag_rgba.glsl]- Initialise successful : 0x3710e30
DEBUG: GUI Shader [guishader_frag_rgba_oes.glsl]- Initialise successful : 0x37281e0
DEBUG: GUI Shader [guishader_frag_rgba_blendcolor.glsl]- Initialise successful : 0x36fa8c8
DEBUG: GUI Shader [guishader_frag_rgba_bob.glsl]- Initialise successful : 0x3719310
DEBUG: GUI Shader [guishader_frag_rgba_bob_oes.glsl]- Initialise successful : 0x371c100

Success:
Code:
DEBUG: GUI Shader [guishader_frag_default.glsl]- Initialise successful : 0x41d07a8
DEBUG: GUI Shader [guishader_frag_texture.glsl]- Initialise successful : 0x42b1508
DEBUG: GUI Shader [guishader_frag_multi.glsl]- Initialise successful : 0x42249e8
DEBUG: GUI Shader [guishader_frag_fonts.glsl]- Initialise successful : 0x4289a78
DEBUG: GUI Shader [guishader_frag_texture_noblend.glsl]- Initialise successful : 0x42ba280
DEBUG: GUI Shader [guishader_frag_multi_blendcolor.glsl]- Initialise successful : 0x425f9b0
DEBUG: GUI Shader [guishader_frag_rgba.glsl]- Initialise successful : 0x41d0088
DEBUG: GUI Shader [guishader_frag_rgba_oes.glsl]- Initialise successful : 0x427f140
DEBUG: GUI Shader [guishader_frag_rgba_blendcolor.glsl]- Initialise successful : 0x41b7db0
DEBUG: GUI Shader [guishader_frag_rgba_bob.glsl]- Initialise successful : 0x42b7778
DEBUG: GUI Shader [guishader_frag_rgba_bob_oes.glsl]- Initialise successful : 0x42366f8

Then its another block showing up more early in the successful version then in the failed version:
Failed:
Code:
DEBUG: Loading: libcurl.so.4
OTICE: Running database version Addons19

Success:
Code:
DEBUG: Loading: libcurl.so.4
DEBUG: OpenConnection - connection to the CEC adapter opened
DEBUG: SetConfigurationFromLibCEC - settings updated by libCEC
OTICE: Thread CECAdapterUpdate start, auto delete: false
OTICE: Running database version Addons19

Another difference is an address of something:
Failed:
Code:
DEBUG: Thread DetectDVDMedia 1898652464 terminating

Success:
Code:
DEBUG: Thread DetectDVDMedia 1898017584 terminating

And now the above mentioned delayed block shows up in the failed version. Thus
Failed:
Code:
INFO: Loading fonts from /usr/share/kodi/addons/skin.confluence/720p/Font.xml
DEBUG: OpenConnection - connection to the CEC adapter opened
DEBUG: SetConfigurationFromLibCEC - settings updated by libCEC
OTICE: Thread CECAdapterUpdate start, auto delete: false
DEBUG: POParser: loaded 149 strings from file /usr/share/kodi/addons/skin.confluence/language/resource.language.en_gb/strings.po
INFO: Loading skin includes from /usr/share/kodi/addons/skin.confluence/720p/includes.xml

Success:
Code:
INFO: Loading fonts from /usr/share/kodi/addons/skin.confluence/720p/Font.xml
DEBUG: POParser: loaded 149 strings from file /usr/share/kodi/addons/skin.confluence/language/resource.language.en_gb/strings.po
INFO: Loading skin includes from /usr/share/kodi/addons/skin.confluence/720p/includes.xml


more adresses:
Failed:
Code:
DEBUG: Activating window ID: 10000
DEBUG: COMXCoreComponent::Initialize OMX.broadcom.image_decode input port 320 output port 321 m_handle 0x3630e10
DEBUG: COMXCoreComponent::AllocInputBuffers component(OMX.broadcom.image_decode) - port(320), nBufferCountMin(2), nBufferCountActual(2), nBufferSize(125120), nBufferAlignmen(16)
DEBUG: COMXCoreComponent::Initialize OMX.broadcom.egl_render input port 220 output port 221 m_handle 0x3e42cf0
DEBUG: COMXCoreComponent::UseEGLImage component(OMX.broadcom.egl_render) - port(221), nBufferCountMin(1), nBufferCountActual(1), nBufferSize(15360) nBufferAlignmen(16)
DEBUG: COMXCoreComponent::Deinitialize : OMX.broadcom.image_decode handle 0x3630e10
DEBUG: COMXCoreComponent::Deinitialize : OMX.broadcom.egl_render handle 0x3e42cf0
DEBUG: ------ Window Init (Pointer.xml) ------

Success:
Code:
DEBUG: COMXCoreComponent::Initialize OMX.broadcom.image_decode input port 320 output port 321 m_handle 0x49e7d20
DEBUG: COMXCoreComponent::AllocInputBuffers component(OMX.broadcom.image_decode) - port(320), nBufferCountMin(2), nBufferCountActual(2), nBufferSize(125120), nBufferAlignmen(16)
DEBUG: COMXCoreComponent::Initialize OMX.broadcom.egl_render input port 220 output port 221 m_handle 0x41e1088
DEBUG: COMXCoreComponent::UseEGLImage component(OMX.broadcom.egl_render) - port(221), nBufferCountMin(1), nBufferCountActual(1), nBufferSize(15360) nBufferAlignmen(16)
DEBUG: COMXCoreComponent::Deinitialize : OMX.broadcom.image_decode handle 0x49e7d20
DEBUG: COMXCoreComponent::Deinitialize : OMX.broadcom.egl_render handle 0x41e1088
DEBUG: ------ Window Init (Pointer.xml) ------

And then many things are scrambled but the content is in general the same only in different order and some ms difference in starting time.

Failed:
Code:
OTICE: Thread JobWorker start, auto delete: true
DEBUG: RunQuery took 2 ms for 0 items query: select * from movie_view  ORDER BY dateAdded desc, idMovie desc LIMIT 10
DEBUG: RunQuery took 10 ms for 0 items query: select * from episode_view  ORDER BY dateAdded desc, idEpisode desc LIMIT 10
OTICE: ES: Starting event server
INFO: JSONRPC Server: Successfully initialized
DEBUG: CZeroconfAvahi::doPublishService identifier: servers.jsonrpc-tpc type: _xbmc-jsonrpc._tcp name:Kodi (rapi3) port:9090
DEBUG: CZeroconfAvahi::addService() named: Kodi (rapi3) type: _xbmc-jsonrpc._tcp port:9090
OTICE: Thread TCPServer start, auto delete: false
DEBUG: LogindUPowerSyscall - Received unknown signal NameAcquired
DEBUG: RunQuery took 15 ms for 0 items query: select * from musicvideo_view  ORDER BY dateAdded desc, idMVideo desc LIMIT 10
OTICE: Thread EventServer start, auto delete: false
OTICE: ES: Starting UDP Event server on 0.0.0.0:9777
OTICE: UDP: Listening on port 9777
OTICE: Thread JobWorker start, auto delete: true
DEBUG: CZeroconfAvahi::doPublishService identifier: servers.eventserver type: _xbmc-events._udp name:Kodi (rapi3) port:9777
DEBUG: ------ Window Init (DialogKaiToast.xml) ------
DEBUG: CRecentlyAddedJob::UpdateTotal() - Running RecentlyAdded home screen update
DEBUG: CZeroconfAvahi::addService() named: Kodi (rapi3) type: _xbmc-events._udp port:9777
INFO: Found input device /dev/input/event0
INFO: opened device 'Logitech K400' (file name /dev/input/event0), m_bSkipNonKeyEvents 0
OTICE: Thread RSSReader start, auto delete: false
DEBUG: CurlFile::Open(0x712b1be8) http://feeds.xbmc.org/xbmc
INFO: easy_aquire - Created session to http://feeds.xbmc.org

Success:
Code:
OTICE: Thread JobWorker start, auto delete: true
DEBUG: RunQuery took 3 ms for 0 items query: select * from movie_view  ORDER BY dateAdded desc, idMovie desc LIMIT 10
DEBUG: RunQuery took 4 ms for 0 items query: select * from episode_view  ORDER BY dateAdded desc, idEpisode desc LIMIT 10
DEBUG: RunQuery took 7 ms for 0 items query: select * from musicvideo_view  ORDER BY dateAdded desc, idMVideo desc LIMIT 10
DEBUG: CRecentlyAddedJob::UpdateTotal() - Running RecentlyAdded home screen update
OTICE: ES: Starting event server
INFO: JSONRPC Server: Successfully initialized
OTICE: Thread EventServer start, auto delete: false
OTICE: ES: Starting UDP Event server on 0.0.0.0:9777
DEBUG: CZeroconfAvahi::doPublishService identifier: servers.jsonrpc-tpc type: _xbmc-jsonrpc._tcp name:Kodi (rapi3) port:9090
DEBUG: CZeroconfAvahi::addService() named: Kodi (rapi3) type: _xbmc-jsonrpc._tcp port:9090
DEBUG: LogindUPowerSyscall - Received unknown signal NameAcquired
OTICE: UDP: Listening on port 9777
OTICE: Thread JobWorker start, auto delete: true
DEBUG: CZeroconfAvahi::doPublishService identifier: servers.eventserver type: _xbmc-events._udp name:Kodi (rapi3) port:9777
OTICE: Thread TCPServer start, auto delete: false
DEBUG: ------ Window Init (DialogKaiToast.xml) ------
DEBUG: CZeroconfAvahi::addService() named: Kodi (rapi3) type: _xbmc-events._udp port:9777
INFO: Found input device /dev/input/event0
INFO: opened device 'Logitech K400' (file name /dev/input/event0), m_bSkipNonKeyEvents 0
OTICE: Thread RSSReader start, auto delete: false
DEBUG: CurlFile::Open(0x71216be8) http://feeds.xbmc.org/xbmc
INFO: easy_aquire - Created session to http://feeds.xbmc.org

And in the end a some more memory addresses I skip now.

Concluction:
I don't see any difference between the logs except excectuion oder and some timings. In general they are the same.
Reply
#9
I now removed pulseaudio from the system, and also disabled the kernel modules of the the hifiberry DAC+ soundcard and kodi still doesn't start.
Reply
#10
Addresses, timestamps and ordering shouldn't be critical. It's really looking for a message that occurs in one and not the other
(e.g. a complaint in the failing build, or something only being done in the success build).
Reply
#11
Then I'm afraid the logs are not usefull. There is no such line in the two logs.
Reply

Logout Mark Read Team Forum Stats Members Help
Kodi 15.1 Starts but screen freezes.1