How to set a cronjob in linux?

 

    crontab - it is used for scheduling jobs, commands etc.The entry consist of 5 space Delimated fields followed by a command line.

    crontab -e – it is used for scheduling crontab file

    crontab -l - it is used for listing crontab jobs.

    Eg: crontab -e

    30 01 10 04 06 /usr/bin/find

    Then start the daemon.

         service crond start

         chkconfig crond on

    Here it executes the command find at 1:30 a.m on 10th april of every year when a Saturday falls off.

 

 

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

what is the command 'ls' used for?

       ls – list directory contents.    ...

for what the command 'tail' is used for?

  tail – print the last 10 lines of the named file.If more than one file is specified...

for what purpose the commad 'du' is used for?

      du- estimates the file space usage.   Format: du [options] [file]...

what is the use of command 'grep'?

    grep- search one or more files that matches a regular pattern  Format:...

'cp' command in linux

    cp - copy files and directories.  Format: cp [options] source...

Powered by WHMCompleteSolution