25 C
Jaipur
Friday, November 27, 2020

Zeit – A GUI Front-end To Crontab To Schedule Jobs In Linux

Must read

India Wearables Shipments Hit Record High in Q3 Amidst Falling Prices, Increased Options

Shipments of smart wearables in India reportedly jumped 165% in the July-September quarter thanks to an increased emphasis on remote work and rising health...

Sony is Permanently Banning PS5 Owners For Selling Their PlayStation Plus Collection

Sony offers access to 20 PlayStation 4 games through PlayStation Plus Collection, a new benefit to PlayStation Plus subscribers with PlayStation 5. The company...

This brief tutorial explains about Zeit, a graphical front-end to Crontab and at command, and how to easily schedule jobs in Linux with Zeit.

Introduction to Zeit

The system admins will usually schedule repetitive tasks to make their’s and everyone’s work easier! Scheduling repetitive tasks or jobs is crucial in many occasions, for example automating backups, cleaning disk space and other system maintenance tasks. Even if the admin is not around all the time, a scheduled job will keep running at a specific interval. The most widely used tool to schedule jobs in Linux is Cron. We already have published a beginners guide to Cron jobs. Cron is a command line utility, so the newbies may not fully understand the command line arguments. To mitigate this issue, a few standalone and web-based front-ends to Crontab have been developed. One such tool is Zeit.

Zeit is a Qt front-end to crontab and at command. Using Zeit, we can;

  • Add, edit, and delete crontab tasks,
  • Add, edit, and delete environment variables for crontab,
  • Add and delete at commands,
  • Set alarms and timers.

All of the aforementioned tasks can be easily done via a simple graphical interface. No need to deal with commands! No need to refer the crontab man page to get it right!!

Another notable feature of Zeit is we can set audio reminders. Choose an audio file and they will start playing at a specific time.

Zeit is an opensource program written in C++ programming language. The source code is freely available under GPLv3 license in GitHub.

Install Zeit in Ubuntu Linux

The developer of Zeit has created a PPA to easily install Zeit in DEB-based systems such as Ubuntu, Pop!_OS and Linux Mint.

To install Zeit in Ubuntu and its derivatives, run the following commands one by one in your Terminal:

$ sudo add-apt-repository ppa:blaze/main
$ sudo apt update
$ sudo apt install zeit

If you want to try the development version, do:

$ sudo add-apt-repository ppa:blaze/dev
$ sudo apt update
$ sudo apt install zeit

On other Linux distributions, you may need to manually compile and install Zeit from source.

Schedule jobs in Linux with Zeit

Launch Zeit from terminal by running this command:

$ zeit

The default interface of Zeit should look like below:

Zeit – A Qt front-end to crontab and at command

As you can, Zeit interface is very simple! There are only 5 options and all are self-explanatory.

To create a new scheduled job in your Linux system, click the Add Task button. Enter a meaningful description for the job, enter the command you want to run, choose the appropriate time interval from the “Basic” drop down box.

The Basic drop-down box offers the following time interval options:

  • Every minute,
  • Every hour,
  • Every day,
  • Every week,
  • And Every month.

If you want to specific a custom date and time, choose the “Advanced” option and set the desired values for minute, hour, day, week and month. Finally, click OK to create the cron job.

Create a cron job in Linux with Zeit
Create a cron job in Linux with Zeit

You will now see the newly created job in Zeit interface:

Schedule jobs in Linux with Zeit
Schedule jobs in Linux with Zeit

You can also verify it by manually listing the contents of crontab file using the following command:

$ crontab -l

This command will display all cron jobs of the currently logged in user.

Sample output:

#Backup system
0 0 * * *	sudo rsync -aAXv / --exclude={"/dev/*","/proc/*","/sys/*","/tmp/*","/run/*","/mnt/*","/media/*","/lost+found"} /mnt


# File generated by Crontablib the Monday, 26 October, 2020 7:59:34 PM IST.
Display all cron jobs of current user

The job will run exactly at 00:00 every day.

If you want to edit the cron job, just choose it in the Zeit interface and click “Modify” button. Make the changes as you wish and click OK to update it. If you don’t want a Cron job, select it and hit the “Delete” button in the tool bar. It is that simple!

There are also two more options namely “Alarm” and “Timer” which will help you to set audio reminders at specific time interval.

Set alarms using zeit
Set alarms using zeit

The alarms/timers can be useful to remind you to do something by playing a sound file.

Zeit is a handy GUI tool for newbies who wants to automate repetitive tasks using Cron and/or at command in Linux. Zeit makes the Cron job management task much easier! Define the cronjobs as per your requirement and let them run automatically at specific intervals. One caveat is Zeit requires graphical desktop environment. If you are managing a CLI based server, Zeit may not help much.

Resource:

Featured image by Devanath from Pixabay.

Source link

- Advertisement -

More articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest article

India Wearables Shipments Hit Record High in Q3 Amidst Falling Prices, Increased Options

Shipments of smart wearables in India reportedly jumped 165% in the July-September quarter thanks to an increased emphasis on remote work and rising health...

Sony is Permanently Banning PS5 Owners For Selling Their PlayStation Plus Collection

Sony offers access to 20 PlayStation 4 games through PlayStation Plus Collection, a new benefit to PlayStation Plus subscribers with PlayStation 5. The company...

cPanel 2FA Bypass Exposes Tens of Millions of Websites to Hack

Digital Defense, Inc., a leader in vulnerability and threat management solutions, announced that its Vulnerability Research Team (VRT) exposed a previously undisclosed vulnerability affecting the cPanel &...