Monday, July 23, 2012

Schedule your programs with CRON Command in Linux


Cron is a time-based job scheduler in Unix-like computer operating systems. Cron enables users to schedule jobs (commands or shell scripts) to run periodically at certain times or dates. It is commonly used to automate system maintenance or administration, though its general-purpose nature means that it can be used for other purposes, such as connecting to the Internet and downloading email.


Here we will see how to schedule some Downloader softwares
 with the help of “cron”. Open a terminal and run.



:~$ export EDITOR=gedit 


:~$ crontab -e


Now paste the following files into the pop up file and save it. 


# m h dom mon dow command
# Start Torrent client, please replace with correct path of your torrent program at your required time
15 2 * * * DISPLAY=:0.0 /usr/bin/deluge
# Replace with correct path of download.txt and fill it with your links. Install wget before using the command
17 2 * * * wget -ci /home/username/downloads.txt
16 2 * * * DISPLAY=:0.0 /usr/bin/jdownloader