FF TechSource: 3 Ways to Automate Tasks on Linux ~ Koleksi Pribadi

Senin, 25 Juni 2012

TechSource: 3 Ways to Automate Tasks on Linux

TechSource: 3 Ways to Automate Tasks on Linux


3 Ways to Automate Tasks on Linux

Posted: 24 Jun 2012 07:40 PM PDT

Linux is, and always was, one of the most powerful operating systems on the planet. From Android to Ubuntu, Linux's versatility has made it quite popular with developers, system admins, hackers, and of course, end users. Though simple to use and learn, Linux's untapped prowess can be used to accomplish many tasks in your daily life. From running a garden sprinkler to rocking a baby's cradle, Linux is just about as awesome as Chuck Norris.

Don't worry if you are not that adventurous, because the penguin can also help you save the time you spend on simple repetitive tasks by automating them. Tasks like backing up your important folders, rebooting your computer, and even downloading torrents. So, whether you're a little lazy (as all geeks are) or just someone who doesn't have much time, this article will guide you in saving a few precious hours in your life by automating boring repetitive tasks for you.


Take Automatic Backups

If you're worried about losing your data, then backing it up safely is the best solution. We've already listed some of the best backup tools for Linux; however, the shining new Deja Dup is our favorite these days. Its simplicity as well as its inclusion as the default backup application in Ubuntu has made it a reliable choice. Deja Dup, once set up, can allow you to take automatic backups of your data without you having to manually do it. To get started, simply open Deja Dup by searching for it using the launcher (Super key).

Now, once the application starts, go to the "schedule" tab and select the frequency that suits you best. Also, don't forget to choose whether to keep backups forever or for a set period of time. You don't want to have your hard disk or online account bloated with just backups.

Then, once you are set, go back to the 'Overview' tab and turn 'Automatic Backups' on. This will ensure that your data is safe even when you're not using the computer. Of course, you'll have to leave your computer on for this.



Reboot or Shutdown your computer

Using the 'at' command you can shutdown or reboot your Linux device even while you're away from it. So, let's say you want to shutdown your computer at 3 PM. To get started, open the terminal first (Ctrl + Alt + T), then punch in the following command:

at 3pm

Now, the command will take you to a prompt mode wherein you'll instruct 'at' to do a particular job. There, simply enter the command 'halt' without quotes. Press Ctrl+D to exit.

Now, you've instructed the computer to halt (that is to shut down) at 3pm. You can, in the same way, add more commands to the list. To check on the current pending jobs, simply enter the 'atq' command without quotes. To remove a particular job, use the 'atrm' command.



Auto-start torrent downloads

If you're sleeping or out of the house and wanted to auto-start a download at a specific time, then Linux can be your best friend. Say, you're leaving your house at 10 AM, you can then schedule Linux to start Transmission (popular torrent client) at 2 PM using the following command.

sleep 4h && transmission-gtk

The above command will start Transmission exactly 4 hours after you've issued it. If you want Transmission to run after 3 and a half hours, simply enter this command:

sleep 3h && sleep 30m && transmission-gtk

This can be very useful for people who use data plans where in the ISPs provide unlimited downloading at night. Also, if you want to stop the download before you wake up, or at a specific time, you can issue the following command:

sleep 8h && pkill transmission-gtk


Written by: Abhishek, a regular TechSource contributor and a long-time FOSS advocate.


0 komentar:

Posting Komentar