There are many tasks that a server can perform automatically such as running scripts and commands. On a Linux server, the cron utility is used to schedule scripts and commands. 

LIst of Cron jobs are typically located in the spool directories. They are stored in tables called crontabs. You can find them at /var/spool/cron/crontabs. The tables contain the cron jobs for all users, except the root user.

The root user can use the crontab for the whole system.

In the given article, we will discuss several options to view current cron jobs scheduled in the crontab list.

Following are the Prerequisites to view all jobs in Cron/Crontab

  • A root account or user account with sudo privileges
  • Access to a terminal window (Ctrl+Alt+T) or command line (Ctrl+Alt+F2)

Learn how to install Git on Ubuntu 16.04 Server? 

How to List Jobs in Crontab?

To view Root’s Cron Jobs

crontab -l

View a User’s Cron Jobs

crontab -u username -l

image cron job

View Daily Cron Jobs

View all the daily cron jobs:

ls -la /etc/cron.daily/

View a specific daily cron job:

less /etc/cron.daily/filename

View Hourly Cron Jobs

First view all the hourly cron jobs:

ls -la /etc/cron.hourly/

Then view a specific hourly cron job:

less /etc/cron.hourly/filename

View Weekly Cron Jobs

Display All Jobs in Cron

ls -la /etc/cron.weekly/

Then view a specific weekly cron job:

less /etc/cron.weekly/filename

View Monthly Cron Jobs

First view all the monthly cron jobs:

ls -la /etc/cron.monthly/

Then view a specific monthly cron job:

less /etc/cron.monthly/filename

View /etc/crontab

less /etc/crontab

To view software specefic cron tasks, start by viewing a list of cron tasks:

cd /etc/cron/daily ls –l

Use the cat command to display the contents of update-notifier-common:

cat update–notifier–common

Now you must have understood how to navigate through the cron jobs on your server. Have other thoughts or questions? Reach out to us, our expert support is available 24*7 by phone or mail.

You can also open a chat with us and we’ll be happy to answer any questions you may have!

Posted by Editor