Creating cron jobs for updates

You can create cron jobs to run your Refresh and Incremental updates.

You can use the Linux crontab command to create cron jobs for your Refresh and Incremental updates. A cron job will run the DP CLI (with one of the update flags) at a specific date and time.

The crontab file will have one or more cron jobs. Each job should take up a single line. The job command syntax is:
schedule path/to/command
The command begins with a five-field schedule of when the command will run. A simple version of the time fields in is:
minute hour dayOfMonth month dayOfWeek
where:
  • minute is 0-59.
  • hour is 0-23 (0 = midnight).
  • dayOfMonth is 1-31 or * for every day of the month.
  • month is 1-12 or * for every month.
  • dayOfWeek is 0-6 (0 - Sunday) or * for every day of the week.

path/to/command is the path (including the command name) of the DP CLI update to run, including the appropriate flag and argument.

An example would be:
0 0 2 * * /localdisk/Oracle/Middleware/BDD/dataprocessing/edp_cli/data_processing_CLI --refresh 10133:WarrantyClaims
The job would run every day at 2am.

To set up a cron job for updates:

  1. From the Linux command line, use the crontab command with the e flag to open the crontab file for editing:
    crontab -e
  2. Enter the job command line, as in the above example.
  3. Save the file.

You can also use the Hive Table Detector cron job as a template, as it uses the Linux flock command and generates a log file. For details, see DP CLI cron job.