Jump to content

Display/list cron jobs in debian/linux


daredevil

Recommended Posts

  • Administrators

The cron service searches its spool area (usually /var/spool/cron/crontabs) for crontab files (which are named after user accounts); crontabs found are loaded into memory. cron also reads /etc/crontab, which is in a slightly different format. Additionally, cron reads the files in /etc/cron.d: it treats the files in /etc/cron.d as in the same way as the /etc/crontab file. The intended purpose of /etc/cron.d/ directory feature is to allow packages that require finer control of their scheduling than the /etc/cron.{daily,weekly,monthly} directories to add a crontab file to /etc/cron.d.

 

 

View Users Cronjob

 

crontab -u userName -l
Use the following syntax to view faetpub user cronjob:

 

crontab -u faetpub -l
View Root User Cronjob

 

Just type the following command:

 

crontab -l
View Daily Cronjob

 

Type the following commands:

 

cd /etc/cron.daily/
ls -l
cat filename
View Hourly Cronjobs

 

Type the following commands:

 

cd /etc/cron.hourly/
ls -l
cat filename
View Weekly Cronjobs

 

Type the following commands:

 

cd /etc/cron.weekly/
ls -l
cat filename
View Monthly Cronjobs

 

Type the following commands:

 

cd /etc/cron.monthly/
ls -l
cat filename
View Software (Package) Specific Cronjobs

 

Type the following commands

 

cd /etc/cron.d/
ls -l
cat filename
To delete user cron

 

Type the following command:

crontab -r -u username
Example: To delete all crons for user faetpub:

crontab -r -u faetpub
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.