VOOZH about

URL: https://www.geeksforgeeks.org/linux-unix/job-scheduling-commands-in-linux/

⇱ Job Scheduling Commands in Linux - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Job Scheduling Commands in Linux

Last Updated : 22 Dec, 2025

Job scheduling commands in Linux are used to schedule tasks for future execution or to run commands automatically at specific times or intervals. These commands help automate repetitive tasks, system maintenance, and background jobs without manual intervention.

  • Used to schedule tasks for later execution
  • Helps automate repetitive system jobs
  • Runs tasks in background without user interaction
  • Essential for system administration and maintenance
👁 job_scheduling_commands

The following commands are used for job scheduling in Linux.

1. atd

The atd command is a daemon that runs scheduled at jobs in the background. It must be running for at commands to work properly.

  • Runs scheduled at jobs
  • Works as a background service
  • Required for one-time tasks

Syntax:

atd 

Example:

atd
service atd status
👁 file
  • This starts the at job scheduler service.

2. atrm

The atrm command is used to remove scheduled at jobs. It deletes jobs using their job ID.

  • Removes scheduled jobs
  • Uses job ID
  • Helps manage queued tasks

Syntax:

atrm job_id

Example:

atrm 3
👁 atrm

This removes the scheduled job with ID 3.

3. atq

The atq command displays the list of pending at jobs scheduled by the user.

  • Lists scheduled jobs
  • Shows job ID and time
  • Helps track tasks

Syntax:

atq

Example:

atq
👁 atq
  • This shows all pending at jobs.

4. batch

The batch command schedules jobs to run when system load is low. It is useful for resource-intensive tasks.

  • Runs jobs when load is low
  • Prevents system overload
  • Used for heavy tasks

Syntax:

batch

Example:

batch
  • This schedules a job to run when system load decreases.

5. cron

The cron command is a background service that runs scheduled jobs at fixed intervals. It is widely used for recurring tasks.

  • Runs scheduled jobs automatically
  • Works in background
  • Used for recurring tasks

Syntax:

cron

Example:

cron
  • This starts the cron service.

6. crontab

The crontab command is used to create, edit, and manage cron jobs. It defines scheduled tasks in a file.

  • Schedules recurring jobs
  • Uses time-based format
  • Easy task automation

Syntax:

crontab [option]

Example:

crontab -e
👁 crontab8

This opens the crontab file for editing scheduled jobs.

Comment
Article Tags:

Explore