Jump to content

How to set crontab every week?


chintansshah

Recommended Posts

Create a plain text file with your cron job in. For example:

 

0 0 * * 1 command to be executed

 

You'll then need to use the crontab program to install the cronjob:

 

crontab /path/to/cronjob/file

 

You can then check the cronjob was installed successfully with:

 

crontab -l

it gives below output.

 

no crontab for root - using an empty one

 

Select an editor.  To change later, run 'select-editor'.

  1. /usr/bin/vim.tiny

  2. /bin/ed

  3. /bin/nano        <---- easiest

  4. /usr/bin/vim.basic

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.