Project

General

Profile

LibreElec (with Kodi) + Tvheadend and no EPG

Added by Niklas Nyberg about 6 years ago

Hi
Running LibreELEC 8.2.5 with Tvheadend pvr official version 4.2.6-7 on a Gixabyte brix celeron x86. Using Tvheadend HTSP client version 3.4.27.1.

Got everything worked a couple of days ago but now my epg is empty and I can’t get the data into it again.
All IPTV channels works and they are all mapped in TVH config.
Running internal Xmltv in the TVH server.

If I add the Xmltv link in a browser I get all channel info.
But no epg data in tvheadend.

It’s driving me crazy!! What do I miss????

When I run the Re-Run internal EPG grabbers I get the following in the debugwindow:

2018-10-16 17:51:24.320 xmltv: /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file: grab /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file

2018-10-16 17:51:24.328 spawn: Executing "/storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file"
2018-10-16 17:52:02.501 xmltv: /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file: grab took 38 seconds
2018-10-16 17:52:02.590 xmltv: /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file: parse took 0 seconds
2018-10-16 17:52:02.590 xmltv: /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file: channels tot= 109 new= 0 mod= 0
2018-10-16 17:52:02.590 xmltv: /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file: brands tot= 0 new= 0 mod= 0
2018-10-16 17:52:02.590 xmltv: /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file: seasons tot= 0 new= 0 mod= 0
2018-10-16 17:52:02.590 xmltv: /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file: episodes tot= 0 new= 0 mod= 0
2018-10-16 17:52:02.590 xmltv: /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file: broadcasts tot= 0 new= 0 mod= 0

Regards
Niklas


Replies (11)

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by K Shea about 6 years ago

Niklas Nyberg wrote:

Running LibreELEC 8.2.5

That is your first problem. LibreELEC tries so hard to keep users away from the Linux command line that it makes it very difficult to fix issues like this, because the standard approaches for dealing with this issue don't work if you can't get to a Linux command prompt, or you can't install standard tools such as a text editor. If I were you I'd consider running Ubuntu desktop (tip: Ubuntu 16.04 LTS is easier to work with than the latest LTS version 18.04 due to changes in the way graphics are handled in 18.04) and then installing Tvheadend and Kodi on that. If you really want to stay with LibreELEC, then I believe there is an addon that is written in Python that is supposed to handle guide data, but I have never used it and don't know how it works. You can find it at https://github.com/edit4ever/script.module.zap2epg

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by Niklas Nyberg about 6 years ago

Wow! Wasn’t expecting this kind of answer but ok.

I can get to the command prompt via Putty, no problem at all but I guess you know that already.
But since I have no knowledge of Linux file system, structure and rights it’s hard.
I have been working with other PC OS for 30 years so...

Why should it work better with Ubuntu?

BTW, Now I got epg data on 2 of my channels. Don’t know why it’s only two. Guess I try to reconnect all channels manually again.

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by Em Smith about 6 years ago

From where do you retrieve your epg? I see you have "tv_grab_file", but how have you configured it? You mentioned a URL? Where did you configure that?

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by M. Bergmann about 6 years ago

What is the content of /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file ?

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by Niklas Nyberg about 6 years ago

Em Smith wrote:

From where do you retrieve your epg? I see you have "tv_grab_file", but how have you configured it? You mentioned a URL? Where did you configure that?

This: http://estiptv.site/epg/SE_guide.xml config in TVHEADEND server as an XML URL.

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by Niklas Nyberg about 6 years ago

Tim Bremer wrote:

What is the content of /storage/.kodi/addons/service.tvheadend42/bin/tv_grab_file ?

This is the content of tv_grab_file:

if [ $# -lt 1 ]
then
. /etc/profile

ADDON_HOME="$HOME/.kodi/userdata/addon_data/service.tvheadend42" 
ADDON_SETTINGS="$ADDON_HOME/settings.xml"
XMLTV_TYPE=`grep XMLTV_TYPE $ADDON_SETTINGS | awk '{print $3 }' | sed -e "s,value=,," -e "s,\",,g"`
XMLTV_LOCATION_FILE=`grep XMLTV_LOCATION_FILE $ADDON_SETTINGS | awk '{print $3 }' | sed -e "s,value=,," -e "s,\",,g"`
XMLTV_LOCATION_WEB=`grep XMLTV_LOCATION_WEB $ADDON_SETTINGS | awk '{print $3 }' | sed -e "s,value=,," -e "s,\",,g"`
XMLTV_LOCATION_SCRIPT=`grep XMLTV_LOCATION_SCRIPT $ADDON_SETTINGS | awk '{print $3 }' | sed -e "s,value=,," -e "s,\",,g"`
if [ "$XMLTV_TYPE" = "FILE" ]; then
case "$XMLTV_LOCATION_FILE" in
*.gz | *.bz2 | *.xz)
zcat "$XMLTV_LOCATION_FILE"
;;
*)
cat "$XMLTV_LOCATION_FILE"
;;
esac
exit 0
elif [ "$XMLTV_TYPE" = "SCRIPT" ]; then
if [ -e "$XMLTV_LOCATION_SCRIPT" ] ; then
exec "$XMLTV_LOCATION_SCRIPT"
fi
elif [ "$XMLTV_TYPE" = "WEB" ]; then
wget -qO - "$XMLTV_LOCATION_WEB"
exit 0
fi
fi

dflag=
vflag=
cflag=

for a in "$@"
do
[ "$a" = "-d" -o "$a" = "--description" ] && dflag=1
[ "$a" = "-v" -o "$a" = "--version" ] && vflag=1
[ "$a" = "-c" -o "$a" = "--capabilities" ] && cflag=1
done

if [ -n "$dflag" ]

then
echo "tv_grab_file is a simple grabber that can be configured through the addon settings from Kodi"
fi

if [ -n "$vflag" ]
then
echo "1.0"
fi

if [ -n "$cflag" ]
then
echo "baseline"
fi

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by Em Smith about 6 years ago

OK, the xmltv file looks good.

If you do:

. /etc/profile
env | grep XML

What do you get?
You expect something like:

XMLTV_TYPE=WEB
XMLTV_LOCATION_WEB=http://estiptv.site/epg/SE_guide.xml

The settings look like they should come from the file:

$ADDON_SETTINGS

$HOME/.kodi/userdata/addon_data/service.tvheadend42/settings.xml 

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by Niklas Nyberg about 6 years ago

When I send :
. /etc/profile
env | grep XML
I dont get anything at all. There is nothing about XML in the Environment variables.

I removed all from the "Channel / EPG - EPG Grabber Channels" and remaped them again on tab "Channel / EPG - Channels" and I Think that all EPG data is coming back again.

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by Niklas Nyberg about 6 years ago

It looks like all EPG data is back again. Should I enter the ENV variables somewhere?
XMLTV_TYPE=WEB
XMLTV_LOCATION_WEB=http://estiptv.site/epg/SE_guide.xml

RE: LibreElec (with Kodi) + Tvheadend and no EPG - Added by Niklas Nyberg about 6 years ago

Does anyone know if I should add this to the ENV variables?

XMLTV_TYPE=WEB
XMLTV_LOCATION_WEB=http://estiptv.site/epg/SE_guide.xml

And how do I do it?

    (1-11/11)