Scheduling OCI Database with PostgreSQL Backups

Schedule automatic backups of an OCI Database with PostgreSQL.

Use the database's management policy to enable automatic, scheduled backups of a database. The management policy lets you specify the backup frequency, run time, and the retention period of the backups.

    1. Open the navigation menu and select Databases. Under PostgreSQL, select DB Systems.
    2. (Optional) In the List scope section, under Compartment, select a compartment.
    3. Select the database system that you want to enable automatic backups for.
    4. On the database system details page, select More actions and then select Edit management policy.
    5. In the Edit management policy panel, select Enable automatic backups.
    6. After enabling automatic backups, you can set the following scheduling options:
      • Backup frequency: How often a backup is created.
      • Day of the week: The day of the week that the backup is created.
      • Backup start time: The time that the backup is created.
      • Backup retention period (days): Enter a value, in days, that the backup will be retained before it's deleted by the system. The default value is 35 days.
    7. Select Save changes.
  • Use the oci psql db-system update command and the --management-policy parameter to update the management policy of a database:

    oci psql db-system update --db-system-id <database_OCID> --management-policy <file://management-policy-details.json>[OPTIONS]

    For a complete list of parameters and values for CLI commands, see the CLI Command Reference.

  • Run the UpdateDbSystem operation with the managementPolicy attribute to update the management policy of the database.

    For information about using the API and signing requests, see REST API documentation and Security Credentials. For information about SDKs, see SDKs and the CLI.