Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
openstack cron trigger create <trigger_name> cinder_volume_backup_rotation \

  '{"volume_id":"<volume_id>","backup_name":"<backup_name>","max_full_backups":2,"max_incremental_backups":5}' \

  --pattern "0 * * * *"

Explanation:

ParameterDescription
<trigger_name>
Name of the cron trigger.
cinder_volume_backup_rotationWorkflow name to execute.
{"volume_id": ..., "backup_name": ..., ...}JSON data containing workflow input parameters.
--pattern "0 * * * *"Cron pattern defining the schedule.

Cron Pattern Format:

The cron pattern follows the format:

Code Block
* * * * * 
| | | | |
| | | | +---- Day of the week (0-7, Sunday=0 or 7)
| | | +------ Month (1-12)
| | +-------- Day of the month (1-31)
| +---------- Hour (0-23)
+------------ Minute (0-59)

Examples:

Cron PatternSchedule
0 * * * *Every hour
0 2 * * *Every day at 2:00 AM
0 2 * * 1Every Monday at 2:00 AM
*/15 * * * *Every 15 minutes
0 0 1 * *First day of every month at midnight

Key Notes

  • Mistral cron triggers are ideal for automating backups at regular intervals.
  • The cron pattern follows standard Linux cron format.
  • Ensure that the python-mistralclient package is installed before creating a cron trigger.
  • You can manage cron triggers using the openstack cron trigger commands.

...