Email Us

E2 - Enabling cron daemon how to

Enigma 2

Reply
  #1  
Old 15-07-2009, 12:50  Translate from English to Italian  Translate from English to French  Translate from English to German  Translate from English to Spanish  Translate from English to Dutch  Translate from English to Greek  Translate from English to Portuguese  Translate from English to Russian  Translate from English to Russian
arken's Avatar
arken arken is offline
 
Join Date: Nov 2008
Location: Wild Green Yonder
Posts: 293
Thanks: 414
Thanked 480 Times in 126 Posts
Country: Country Flag
Default E2 - Enabling cron daemon how to

In Linux cron daemon allows you to execute scheduled tasks at specific time/date. Useful for autoupdate keys, epg and many more...
SIFTeam Enigma2 has cron daemon already included in busybox binary. Here is a way to use it.

Telnet to your box and execute the following commands:
Code:
mkdir -p /var/spool/cron/crontabs
touch /var/spool/cron/crontabs/root
Now edit /var/etc/rcS_user.sh and add the following line at the end:
Code:
# cron daemon
/usr/sbin/crond &
(I know that the proper way to autostart is within init.d, but flash users cant edit it)

Now you can add jobs by editing /var/spool/cron/crontabs/root file. (for some reason crontab -e doesnt work).

For example:
Code:
30 01 * * * /var/script/examplescript.sh ## the job will start every day at 01:30 h.
30 01 30 * * /var/script/examplescript.sh ## the job will start at 30th every mnont at 01:30h
30 01 * * 0 /var/script/examplescript.sh ## the job will start every sunday at 01:30h
__________________

Last edited by arken; 15-07-2009 at 12:53..
Reply With Quote
  #2  
Old 26-07-2009, 17:14  Translate from English to Italian  Translate from English to French  Translate from English to German  Translate from English to Spanish  Translate from English to Dutch  Translate from English to Greek  Translate from English to Portuguese  Translate from English to Russian  Translate from English to Russian
Netfreak Netfreak is offline
Member
 
Join Date: Mar 2009
Posts: 10
Thanks: 33
Thanked 0 Times in 0 Posts
Country: Country Flag
Default

Thanks,
13,33 * * * * /var/bin/T.sh
cat /var/bin/T.sh
#!/bin/sh
ntpdate -b -u 192.168.1.12
This solves my timeproblem
Reply With Quote
  #3  
Old 06-03-2013, 10:52  Translate from English to Italian  Translate from English to French  Translate from English to German  Translate from English to Spanish  Translate from English to Dutch  Translate from English to Greek  Translate from English to Portuguese  Translate from English to Russian  Translate from English to Russian
Robinson74 Robinson74 is offline
Senior Member
 
Join Date: Aug 2010
Posts: 470
Thanks: 1,019
Thanked 106 Times in 82 Posts
Country: Country Flag
Default

Can somebody help, please?
How to write a script which pings my router and then put it in cron so that the script is executed every minute?
I don't have experience with scripts.
Reply With Quote
Note: Visitors from certain countries might see in-text advertising(underlind words in posts).
It is only shown to unregistered visitors or members that haven't made any posts. So you can easily get rid of it.
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 10:42.



Powered by vBulletin
Copyright ©2006-2016 - Sat Universe