Jump to content
Cesbo Community
  • Announcements

    • RadioSintetica

      Information   10/21/18

      Registration on the forum temporarily closed! For support requests, please contacat us: https://cesbo.com/help
      Our community in Telegram: @cesbo_en (English language) , @cesbo_ru (Russian language) , @cesbo_es (Spanish Language)
Sign in to follow this  

Need to add EPG script command in Autorun Script!

Recommended Posts


at the moment i run astra with on startup with init.d.


#!/bin/sh ### BEGIN INIT INFO # Provides: astra # Required-Start: $network $syslog $named # Required-Stop: $network $syslog $named # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start/stop astra ### END INIT INFO set -e if [ -z "$1" ] ; then echo "Usage: $0 [start|stop|restart]" exit 0 fi if [ "$1" = "start" ] ; then ulimit -n 65536 /usr/bin/astra --pid /var/run/astra.pid --log /var/log/astra.log -c /etc/astra/astra.conf -p 8000 --daemon elif [ "$1" = "stop" ] ; then kill `cat /var/run/astra.pid` elif [ "$1" = "restart" ] ; then $0 stop sleep 1 $0 start fi


i need to use the EPG aggreagtor.lua script in order to get EPG in stalker.

How do i add the following command in init.de script???


astra /etc/astra/epg-aggregator.lua -o /tmp/epg.xml -p 5000 --daemon





Share this post

Link to post
Share on other sites

did change this line  

/usr/bin/astra --pid /var/run/astra.pid --log /var/log/astra.log -c /etc/astra/astra.conf -p 8000 --daemon

to this

/usr/bin/astra --pid /var/run/astra.pid --log /var/log/astra.log -c /etc/astra/astra.conf -p 8000 /etc/astra/epg-aggregator.lua -o /tmp/epg.xml -p 5000 --deamon

now i can see something in server:5000

however i cannot enter the web interface in Astra, seems my password is wrong!!!

Any idea why?




Share this post

Link to post
Share on other sites

Thanks to Andrey did solve this issue.

i downloaded a script (epg-aggregator) and placed into

then did 

chmod +x /etc/init.d/epg-aggregator

and then

update-rc.d epg-aggregator defaults 

to turn autorun on.

Share this post

Link to post
Share on other sites

Now i can see the epg at server:5000.

When i add this address in stalker epg section and try to update it i get the warning that the server is unavailable !!!

Any idea why?


Share this post

Link to post
Share on other sites

Dear RadioS

after a lot of search i figure it out how it all works!!!

Here is how you can setup astra EPG and Ministra (Stalker ) middleware.

I use ubuntu 16.04 as a platform for Astra.

Lets asume that the ip of astra server is:

1. Dowload the epg-aggregator file that i have attached.

2. Save it into /etc/init.d/epg-aggregator and launch: update-rc.d epg-aggregator defaults to turn autorun on.

3. Set execute permission: chmod +x /etc/init.d/epg-aggregator then: update-rc.d epg-aggregator defaults

4.Run: sudo nano /etc/init.d/epg-aggregator

5. Make sure the following line exists in the file with the --stalker option

astra /etc/astra/epg-aggregator.lua -o /tmp/epg.xml -p 5000 --pid /var/run/epg-aggregator.pid --daemon --stalker

6. Then restart it: /etc/init.d/epg-aggregator restart
7. Go to astra and set each channel epg export settings. Format JSON destination

8. Now the file we need to load into the stalker EPG sections is: /tmp/epg.xml 

 This is not suitable cause stalker cannot access this file. 

9. Install apache2 server:  Run: sudo apt-get update  and then run: sudo apt-get install apache2 then run: sudo ufw allow 'Apache Full'

10. Check with the systemd init system to make sure the service is running by typing: sudo systemctl status apache2

11. Now in any browser in you must see the apache webpage. That means that the server works.

12. Edit the epg-aggrregator lua file in order to set the location of the epg.xml file in the apache folder so that it can be accessed by http.

Run: sudo nano /etc/astra/epg-aggregator.lua change: epg_file = "/tmp/epg.xml" to: epg_file = "/var/www/html/epg.xml"

13. Now login to stalker, under the EPG section add a new epg server:

1. Open tab IPTV channels.
2. Choose EPG.
3. Press button Add EPG.

in the URL field put:

set initial set to: published

add all necessary languages

14. Now you need to edit the EPG section of every stalker channel in the stalker IPTV tab.

1. Open tab IPTV channels.
2. Click into one channel.
3. Press EPG tab.

4. Fill the  XMLTV ID field with the channel id and save.

The channel id you can find it in the xml file.

In my stalker server the channel id is the last 4 characters of the channel streaming link.


Adress Priority Temporary HTTP–link Monitoring Monitoring status Loading balance  
in this streaming link the channel id for the EPG is: a022
After some time most EPG would be in the xml file.
Then hit the  update button in stalker EPG section.
Big thanks to Andrey and Dmitry for their valuable help!!!















Share this post

Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in

Sign In Now
Sign in to follow this