Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segmentation fault on loading channel list #438

Open
SevereOverfl0w opened this issue Oct 20, 2023 · 27 comments
Open

Segmentation fault on loading channel list #438

SevereOverfl0w opened this issue Oct 20, 2023 · 27 comments

Comments

@SevereOverfl0w
Copy link

Hi, I've just done a fresh install of vuplus to work with OpenATV 7.2. I'm using LibreElec as my Kodi install on a raspberry pi. Unfortunately enabling this plugin triggers reboot loops. Here is a zip of my logs from the crash:

log-2023-10-19-21.32.36-FAILED.zip

In the journal log I noticed there was a segmentation fault which looked pretty damning:

Oct 19 22:31:04 Skarpi kodi.sh[1131]: Segmentation fault (core dumped)
Oct 19 22:31:05 Skarpi pulseaudio[377]: W: [pulseaudio] sap.c: sendmsg() failed: Connection refused
Oct 19 22:31:07 Skarpi kodi.sh[1131]: Crash report available at /storage/.kodi/temp/kodi_crashlog_20231019223104.log
@phunkyfish
Copy link
Member

Can you supply a debug log?

It would be a good idea to have a clean LibreElec install, with only pvr.vuplus installed and debug from that point.

The start of your log makes me wonder:

Starting Kodi (20.2 (20.2.0) Git:20.2-Nexus). Platform: Linux ARM 32-bit
Using Release Kodi x32
Kodi compiled 2023-07-15 by GCC 12.2.0 for Linux ARM 32-bit version 6.1.38 (393510)
Running on BCM2835 with LibreELEC (official): 11.0.3, kernel: Linux ARM 64-bit version 6.1.38

Why the mix of 32bit and 64bit?

@SevereOverfl0w
Copy link
Author

How can I produce a debug log? I assumed the above logs contained all.

I'm not sure why there's a mix, I'm just using the libreelec raspberry pi image.

@phunkyfish
Copy link
Member

@SevereOverfl0w
Copy link
Author

log.gz I had to gzip it as the debug log came to 4M! I hope that's OK.

@SevereOverfl0w
Copy link
Author

Is there anything I can do to help debug this further?

@phunkyfish
Copy link
Member

Just looking at your log now.

@phunkyfish
Copy link
Member

phunkyfish commented Oct 28, 2023

Do you have a PC or Mac by any chance? I'd like to rule in/out if this issue is related to 32/64bits.

If you install Kodi and this add-on and see does it crash or run ok.

Nothing obvious stands out from your log. Did you just setup this device up from scratch? Or was it working previously?

@SevereOverfl0w
Copy link
Author

I only have linux, and it doesn't appear that there's a zip for it?

I've been running libreelec on my raspberry pi for ages now! It works fine otherwise, I have it working with jellyfin, netflix, prime, etc. You can understand why I'm reluctant to do a clean install.

Poking around, I'm wondering if libreelec are doing their own build of this addon to make it work on the RPi? I can't see an official build that would be for the RPi.

@phunkyfish
Copy link
Member

Yes, there are no prebuilt binary addons for linux. Binary add-ons are built differently for LibreElec and Kodi.

Depending on your version of linux your distro might provide kodi packages. Really you just need anyone with a Laptop to connect to your device on your home network to try this out. Or provide remote access but that means opening up your enigma device to the internet.

Ideally we'd have a stacktrace from a debugger to find the root cause.

@chewitt
Copy link

chewitt commented Oct 28, 2023

Why the mix of 32bit and 64bit?

LE currently uses 32-bit userspace on 64-bit ARM SoC deployments due to a historic lack of aarch64 libwidevine libs to support DRM services. That situation has now changed and LE12 has switched to aarch64 userspace on 64-bit capable hardware. TL/DR: It's normal for LE11 and rather unlikely to be a factor in anything.

@SevereOverfl0w
Copy link
Author

I've managed to get this working on Linux using Flatpak, and I am also seeing a segmentation fault. Success!
kodi_crashlog-20231028_163110.log

I'm working on getting a coredump from that now, in the hopes you can extract a stacktrace from it.

@SevereOverfl0w
Copy link
Author

kodi_crashlog-20231028_170414.log This version of the log contains the stack trace!

@phunkyfish
Copy link
Member

kodi_crashlog-20231028_170414.log This version of the log contains the stack trace!

@ksooo, FYI. This is strange as it looks like a fault in PVR::CPVRChannelGroup::HasChannels somehow.

@SevereOverfl0w
Copy link
Author

Are there any clues in that about potential workarounds, can I somehow manually set an option to bypass that HasChannels problem?

I had a look at the source, and it seemed like something wasn't initialised that was being locked.

@phunkyfish
Copy link
Member

I agree with you. But I’m afraid I don’t know the solution yet. @ksooo most recently worked in this area of the code so may have an idea.

@phunkyfish
Copy link
Member

phunkyfish commented Nov 8, 2023

For some reason your all channels groups does not exist which should never be possible. Maybe your TV.db is corrupt can you supply this file?

@SevereOverfl0w
Copy link
Author

I'm not sure how to get the TV.db, can you point me at how to do that? If so, I can!

Looking in OpenWebIf, there's definitely an "All channels" section.

@phunkyfish
Copy link
Member

phunkyfish commented Nov 9, 2023

You’ll find it here ~/.kodi/userdata/databases.

Hopefully with that file we can reproduce. Although as it’s happening on two different platforms maybe not.

@SevereOverfl0w
Copy link
Author

TV.db.zip

I had TV38.db and TV40.db, so I've included both.

@ksooo
Copy link
Member

ksooo commented Nov 9, 2023

I had TV38.db and TV40.db

So far for "fresh install". ;-)

Please delete these two files while kodi is not running as well as Epg*.db in the same folder, then report back whether it is still crashing.

@SevereOverfl0w
Copy link
Author

Exact same result!
TV.db.zip

Here is TV40.db

@ksooo
Copy link
Member

ksooo commented Nov 9, 2023

@SevereOverfl0w do you have the chance to disable the "All channels" group in OpenWebIf? If yes, does it make a difference for the crash?

@SevereOverfl0w
Copy link
Author

@ksooo I went into OpenWebif's Bouqet Editor and deleted "All channels", but that still has crashed. Did you mean something else?

@ksooo
Copy link
Member

ksooo commented Nov 9, 2023

I went into OpenWebif's Bouqet Editor and deleted "All channels", but that still has crashed.

@SevereOverfl0w Please also delete TV40.db and Epg*.db after doing this. The TV40.db file gets corrupted due to the bug we're facing. Does this solve the problem?

@SevereOverfl0w
Copy link
Author

@ksooo That seems to have made it work, thanks!

@ksooo
Copy link
Member

ksooo commented Nov 9, 2023

@SevereOverfl0w And now the good news: This bug should already be fixed for Kodi Omega. If you have the chance to test Beta 1 or latest Omega Nightly, you should be able to re-enable "All channels" in OpenWebif's Bouqet Editor and no crash should happen anymore.

Problem is that Kodi in Nexus (and below) does not handle the name clash of your backend-supplied group named "All channels" and the kodi-generated local group with exactly the same name.

@SevereOverfl0w
Copy link
Author

Ah, that makes sense! I wonder if I can configure Enigma2 to give the "All channels" bouqet a different name. Thanks for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants