Two backup jobs are required: one for all DBC user data and one for DBC only.
Each config or create step uses an XML file. The following examples include a representative XML file.
Before you create a restore job, a backup job must have completed successfully or with a warning.
- Create a backup job for user data that includes all children of DBC but excludes the DBC database.Example: dsc create_job -n DBC-All -f DBCAllJob.xml
This example of DBCAllJob.xml includes all children of DBC by setting the <includeAll> attribute to true.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <dscCreateJob xmlns="http://schemas.teradata.com/v2012/DSC"> <job_instance> <job_name>DBC-All</job_name> <job_description>Backup user data and all objects in DBC</job_description> <job_type>BACKUP</job_type> <job_state>ACTIVE</job_state> <auto_retire>false</auto_retire> <objectlist> <objectinfo> <object_name>DBC</object_name> <object_type>DATABASE</object_type> <parent_name></parent_name> <parent_type>BACKUP_JOB</parent_type> <object_attribute_list> <includeAll>true</includeAll> </object_attribute_list> </objectinfo> </objectlist> </job_instance> <source_tdpid>systemname</source_tdpid> <target_media>1_5_drives</target_media> <job_options> <online>false</online> <data_phase>DATA</data_phase> <query_band></query_band> <dsmain_logging_level>Error</dsmain_logging_level> </job_options> </dscCreateJob>
- If prompted, enter login credentials.
- Run the job.Example: dsc run_job -n DBC-All
- Create a backup job that includes only the DBC database.A DBC only backup job cannot be run as online.Example: dsc create_job -n DBC-Only -f DBCOnlyJob.xml
This example of DBCOnlyJob.xml excludes all children of DBC by setting the <includeAll> attribute to false.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <dscCreateJob xmlns="http://schemas.teradata.com/v2012/DSC"> <job_instance> <job_name>DBC-Only</job_name> <job_description>Backup DBC only and exclude all child objects</job_description> <job_type>BACKUP</job_type> <job_state>ACTIVE</job_state> <auto_retire>false</auto_retire> <objectlist> <objectinfo> <object_name>DBC</object_name> <object_type>DATABASE</object_type> <parent_name></parent_name> <parent_type>BACKUP_JOB</parent_type> <object_attribute_list> <includeAll>false</includeAll> </object_attribute_list> </objectinfo> </objectlist> </job_instance> <source_tdpid>systemname</source_tdpid> <target_media>1_5_drives</target_media> <job_options> <online>false</online> <data_phase>DATA</data_phase> <query_band></query_band> <dsmain_logging_level>Error</dsmain_logging_level> </job_options> </dscCreateJob>
- When prompted, enter login credentials.
- Run the job.Example: dsc run_job -n DBC-Only
- [Optional] Check the status of any running job:dsc job_status -n JobNameJob Status: COMPLETED_SUCCESSFULLY indicates the job is finished. A job might also complete with warning or errors.