FS
Documentation

Backup3G/User Guide/Setting Up Backups

This page was last modified 10:57, 6 March 2008.

From Documentation

< Backup3G | User Guide(Difference between revisions)
Jump to: navigation, search
Revision as of 08:59, 20 April 2006
Moff (Talk | contribs)
(To define a backup item)
← Previous diff
Current revision
Moff (Talk | contribs)
(Backup3G 5.1/User Guide/Setting Up Backups moved to Backup3G/User Guide/Setting Up Backups)
Line 54: Line 54:
=== Example: single part backup step === === Example: single part backup step ===
-Define an item to take a full backup of the directory /usr/home on your host machine (use a different directory name if /usr/home doesn’t exist on your host). Exclude core files from the backup.+Define an item to take a full backup of the directory <tt>/usr/home</tt> on your host machine (use a different directory name if <tt>/usr/home</tt> doesn’t exist on your host). Exclude <tt>core</tt> files from the backup.
The backup should use cpio format and an online index should be kept. If this step were to fail, the backup job should continue to the next step. The backup should use cpio format and an online index should be kept. If this step were to fail, the backup job should continue to the next step.
#Select backup3G configuration > Maintain backup jobs > Items > Maintain then select Maintain > Add. #Select backup3G configuration > Maintain backup jobs > Items > Maintain then select Maintain > Add.
#Accept the default item number. #Accept the default item number.
-#Type in the directory name: /usr/home.+#Type in the directory name: <tt>/usr/home</tt>
#Select the name of your host machine. You can press Choose to see the list of all the available hosts at your site. #Select the name of your host machine. You can press Choose to see the list of all the available hosts at your site.
#Press Choose to display the valid backup methods. Move the pointer next to full cpio and scroll right a few times. You will see that the Index column for ‘full cpio’ says ‘yes’. Choose full cpio. #Press Choose to display the valid backup methods. Move the pointer next to full cpio and scroll right a few times. You will see that the Index column for ‘full cpio’ says ‘yes’. Choose full cpio.
#Set Index to ‘yes’. #Set Index to ‘yes’.
-#Enter in the Options field: -x “ */core”+#Enter in the Options field: <tt>-x “ */core”</tt>
#Now enter a comment, such as “Full backup of users home directories” #Now enter a comment, such as “Full backup of users home directories”
#Set On error to ‘continue’. #Set On error to ‘continue’.
Line 74: Line 74:
=== Example: multi-part backup step === === Example: multi-part backup step ===
-Task: /usr/home is growing and may soon exceed the capacity of a single tape. Change the item defined above to allow for /usr/home to be written to multiple volumes if necessary.+Task: <tt>/usr/home</tt> is growing and may soon exceed the capacity of a single tape. Change the item defined above to allow for <tt>/usr/home</tt> to be written to multiple volumes if necessary.
#Select backup3G configuration > Maintain backup jobs, then Items > Maintain. #Select backup3G configuration > Maintain backup jobs, then Items > Maintain.
-#Choose the item you defined in the previous example (/usr/home, ‘full cpio’), then select Maintain > Change.+#Choose the item you defined in the previous example (<tt>/usr/home</tt>, ‘full cpio’), then select Maintain > Change.
#Move the cursor to the Method field and press Choose. Select “full cpio - MP” #Move the cursor to the Method field and press Choose. Select “full cpio - MP”
#Press Accept to save the changed item details. #Press Accept to save the changed item details.
 +
Any backup job that uses this item will now write to more than one volume if necessary. Any backup job that uses this item will now write to more than one volume if necessary.
Line 88: Line 89:
This topic tells you how to define all the information required to run a backup job: This topic tells you how to define all the information required to run a backup job:
;''scheduling'': how and when the job is initiated, when it will run, and whether to auto-acknowledge it. ;''scheduling'': how and when the job is initiated, when it will run, and whether to auto-acknowledge it.
-;''output'': the drive and media type, whether this backup should be appended to an existing tape, how long the backup should be+;''output'': the drive and media type, whether this backup should be appended to an existing tape, how long the backup should be retained, and what location it should be sent to.
-retained, and what location it should be sent to.+
;''backup steps'': which items will be backed up, plus any extra commands that must be run at the start or end of the job. ;''backup steps'': which items will be backed up, plus any extra commands that must be run at the start or end of the job.
 +
Backup3G’s scheduling features will be sufficient for most backups. If complex scheduling and inter-task dependencies are required, we recommend you use backup3G’s companion product duty3G. Backup3G’s scheduling features will be sufficient for most backups. If complex scheduling and inter-task dependencies are required, we recommend you use backup3G’s companion product duty3G.
Line 102: Line 103:
#;Description: Appears in the duty schedule, so make it meaningful to help users to choose the right backup job. #;Description: Appears in the duty schedule, so make it meaningful to help users to choose the right backup job.
#;Mode: Select the default method for running this job: #;Mode: Select the default method for running this job:
-scheduled if the job will run to a regular schedule and requires some operator action (such as loading a tape)+#:''scheduled'' - if the job will run to a regular schedule and requires some operator action (such as loading a tape)
-automatic if it will be run as an automatic duty (that is, at a set time without user intervention)+#:''automatic'' - if it will be run as an automatic duty (that is, at a set time without user intervention)
-request if there is no regular schedule—the job will be run as required.+#:''request'' - if there is no regular schedule—the job will be run as required.
#;Auto-acknowledge: You may wish to avoid operators having to manually acknowledge completion of the job. The options are: #;Auto-acknowledge: You may wish to avoid operators having to manually acknowledge completion of the job. The options are:
-onsuccess automatically acknowledge this job if it finishes successfully (return status 0). This is the default.+#:''onsuccess'' - automatically acknowledge this job if it finishes successfully (return status 0). This is the default.
-never an operator must always manually acknowledge this job whatever its return status.+#:''never'' - an operator must always manually acknowledge this job whatever its return status.
-always always automatically acknowledge this job. If you choose this, you must use some other way to warn if this backup fails, such as an At-end command that sends mail to an administrator when the job returns a non-zero exit status.+#:''always'' - always automatically acknowledge this job. If you choose this, you must use some other way to warn if this backup fails, such as an At-end command that sends mail to an administrator when the job returns a non-zero exit status.
Line 117: Line 118:
Automatic backups start running as soon as they are initiated. Scheduled backups appear on the operator’s list of outstanding backups for the period specified in Run Time(s), and start running at the time you specify in the Day and Time fields. Automatic backups start running as soon as they are initiated. Scheduled backups appear on the operator’s list of outstanding backups for the period specified in Run Time(s), and start running at the time you specify in the Day and Time fields.
;When: Select the day(s) on which the job is to be run. ;When: Select the day(s) on which the job is to be run.
-;Run Time(s): automatic backup: enter the time of day when the backup should run.+;Run Time(s): ''automatic backup:'' enter the time of day when the backup should run. Examples:
-Examples:+::08:00&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;start the job at 8 am
-08:00 start the job at 8 am+::08,11:00&nbsp;&nbsp;&nbsp;start the job at 8 am and 11 am
-08,11:00 start the job at 8 am and 11 am+::08-10:30&nbsp;&nbsp;&nbsp;start the job at 8.30 am, 9.30 am, and 10.30 am
-08-10:30 start the job at 8.30 am, 9.30 am, and 10.30 am+:''scheduled backup:'' enter the time period during which the job should be initiated by an operator. Examples:
-scheduled backup: enter the time period during which the job should be initiated by an operator. Examples:+::<blank>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;all day
-<blank> all day+::08:00-14:30&nbsp;&nbsp;&nbsp;between 8 am and 2.30 pm
-08:00-14:30 between 8 am and 2.30 pm+::-08:00&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from midnight to 8 am
--08:00 from midnight to 8 am+::08:00-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from 8 am to midnight
-08:00- from 8 am to midnight+
;If not done?: (scheduled backups only) select what action to take if the job has not been started by the end of the scheduled time: ;If not done?: (scheduled backups only) select what action to take if the job has not been started by the end of the scheduled time:
-abandon remove the job from the list of outstanding backups. It will not reappear until the next time the backup is scheduled.+::''abandon'' - remove the job from the list of outstanding backups. It will not reappear until the next time the backup is scheduled.
-outstanding leave the job on the list of outstanding backups. It will stay outstanding until it is performed.+::''outstanding'' - leave the job on the list of outstanding backups. It will stay outstanding until it is performed.
The next three fields specify the drive that will write the backup; how long the backup will be kept; and if it will be stored offsite, the location. The next three fields specify the drive that will write the backup; how long the backup will be kept; and if it will be stored offsite, the location.
Line 141: Line 141:
You can tell backup3G to run a command at the start or end of the job, or when the volume is unloaded from the drive. Press Backup cmd(s) to enter one or more of these commands. You can tell backup3G to run a command at the start or end of the job, or when the volume is unloaded from the drive. Press Backup cmd(s) to enter one or more of these commands.
-Figure 14 — Defining commands to be run with the backup job+ Figure 14 — Defining commands to be run with the backup job
The At-start cmd runs before the first backup step. Example: bring down a database before backing it up. The At-start cmd runs before the first backup step. Example: bring down a database before backing it up.
Line 156: Line 156:
Scheduled backups may be initiated hours or days before they are due to run. For example, on Friday afternoon operators may submit scheduled backups to run on Saturday night. In the When and Run Time(s) fields you specified when this backup should be initiated. Now you will enter the Day and Time when the job should start. Scheduled backups may be initiated hours or days before they are due to run. For example, on Friday afternoon operators may submit scheduled backups to run on Saturday night. In the When and Run Time(s) fields you specified when this backup should be initiated. Now you will enter the Day and Time when the job should start.
-Figure 15 — Run day and time for a scheduled backup+ Figure 15 — Run day and time for a scheduled backup
;Day: Select a day of the week, or select ‘Next 24hrs’ to have the job run within 24 hours from when it is scheduled. ;Day: Select a day of the week, or select ‘Next 24hrs’ to have the job run within 24 hours from when it is scheduled.
Line 166: Line 166:
<br> <br>
 +
=== To Define the Steps in a Backup Job === === To Define the Steps in a Backup Job ===
Line 172: Line 173:
At this point backup3G display the list of predefined items. At this point backup3G display the list of predefined items.
-Figure 16 — Choosing the steps for a backup job+ Figure 16 — Choosing the steps for a backup job
 + 
 + 
 +----
 +;Note: Some directories may appear more than once, for example if two different backup methods may be used. You can use Search to find all the items for the directory you want.
 +----
-'''Note -''' Some directories may appear more than once, for example if two different backup methods may be used. You can use Search to find all the items for the directory you want. 
Select the items that you want to include as steps in your job. In GUI mode, click an item to select it, Ctrl-click to add a row to the selection, and Shift-click to add several consecutive rows to the selection. In CUI mode, press the Select button to add a row to the selection, or press Select over a highlighted row to remove it from the selection. Select the items that you want to include as steps in your job. In GUI mode, click an item to select it, Ctrl-click to add a row to the selection, and Shift-click to add several consecutive rows to the selection. In CUI mode, press the Select button to add a row to the selection, or press Select over a highlighted row to remove it from the selection.
Line 184: Line 189:
<br> <br>
 +
=== To Maintain the Steps in a Backup Job === === To Maintain the Steps in a Backup Job ===
Line 189: Line 195:
#From the backup3G configuration menu, select Maintain backup jobs. #From the backup3G configuration menu, select Maintain backup jobs.
#Select the backup job, then select Jobs > Steps to display the steps currently assigned to that job. #Select the backup job, then select Jobs > Steps to display the steps currently assigned to that job.
-Figure 17 — Maintain backup steps window+ 
 + Figure 17 — Maintain backup steps window
Line 196: Line 203:
#From the ‘Maintain steps’ screen, select Maintain > Add. #From the ‘Maintain steps’ screen, select Maintain > Add.
#Select one or more items. #Select one or more items.
-Press Accept to add the steps to the end of the backup job.+#Press Accept to add the steps to the end of the backup job.
Line 213: Line 220:
#From the ‘Maintain steps’ screen, select Maintain > Reorder. #From the ‘Maintain steps’ screen, select Maintain > Reorder.
#Drag and drop the steps into the order required. #Drag and drop the steps into the order required.
-Press Accept to save the changes and return to ‘Maintain steps’.+#Press Accept to save the changes and return to ‘Maintain steps’.
<br> <br>
 +
=== To Set Up a Duty for a Backup Job === === To Set Up a Duty for a Backup Job ===
Line 227: Line 235:
=== Example: Define a Backup Job === === Example: Define a Backup Job ===
-Task: define a job to do a full cpio backup of /usr/home and /usr/COSmanager to a new media set every Friday at 11.00 p.m. The backup should be scheduled some time between noon and 5.00 pm on Friday afternoon. Retain each backup for one week. Print the media contents and mail a message when the job is finished.+Task: define a job to do a full cpio backup of <tt>/usr/home</tt> and <tt>/usr/cosmos</tt> to a new media set every Friday at 11.00 p.m. The backup should be scheduled some time between noon and 5.00 pm on Friday afternoon. Retain each backup for one week. Print the media contents and mail a message when the job is finished.
 + 
 + 
 +----
 +;Note: In the following example, backup items must already exist for <tt>/usr/home</tt> and <tt>/usr/cosmos</tt>. See To define a backup item on page 74 for details of how to add items. Use other directory names if your home and COSmanager directories are in a different location.
 +----
-'''Note -''' In the following example, backup items must already exist for /usr/home and /usr/COSmanager. See To define a backup item on page 74. for details of how to add items. Use other directory names if your home and COSmanager directories are in a different location. 
#Select Maintain backup jobs from the backup3G configuration menu. A list of existing backup jobs is displayed. #Select Maintain backup jobs from the backup3G configuration menu. A list of existing backup jobs is displayed.
-#Select Jobs > Add to display the prompt form. Job Enter job name ‘test_usr’.+#Select Jobs > Add to display the prompt form.
-Description Enter a description that will help the user to identify this job.+#;Job: Enter job name ‘test_usr’.
-Mode Press Select until the mode is set to ‘scheduled’.+#;Description: Enter a description that will help the user to identify this job.
-Auto-acknowledge+#;Mode: Press Select until the mode is set to ‘scheduled’.
-Leave at the default setting of ‘onsuccess’.+#;Auto-acknowledge: Leave at the default setting of ‘onsuccess’.
-When Choose ‘Weekly - Friday’.+#;When: Choose ‘Weekly - Friday’.
-Run Time(s) Enter 12:00-17:00 to have the job appear on the operators’+#;Run Time(s): Enter 12:00-17:00 to have the job appear on the operators’ ‘outstanding backups’ console at noon. Running the job will involve the operator loading the requested tape into the drive in preparation for the 11 p.m. execution of backup.
-‘outstanding backups’ console at noon. Running the job will involve the operator loading the requested tape into the drive in preparation for the 11 p.m. execution of backup.+#;If not done?: select ‘outstanding’ to keep the job on the console until it is scheduled.
-If not done? select ‘outstanding’ to keep the job on the console until it is scheduled.+#;Drive/Pool: Press Choose to see the list of valid drive/pool names. Select a drive and press Accept.
-Drive/Pool Press Choose to see the list of valid drive/pool names. Select a+#;Retention: Select one week.
-drive and press Accept.+#;Store offsite: As this backup won’t be stored offsite, press Enter or the down arrow key to skip over this field.
-Retention Select one week.+#Press Backup cmd(s).
-Store offsite As this backup won’t be stored offsite, press Enter or the down arrow key to skip over this field.+#;At-start cmd: Skip this field.
-Press Backup cmd(s).+#;At-end cmd: Enter “<tt>mailx -s “incremental backup of /usr/home and /usr/COSmanager: status $maxstatus” < /dev/null</tt>“.
-At-start cmd Skip this field.+#;At-unload cmd: Enter “<tt>( banner $Set_ID; medprint $Set_ID )</tt>”.
-At-end cmd Enter “mailx -s “incremental backup of /usr/home and /usr/COSmanager: status $maxstatus” < /dev/null“.+#Press Accept to return to the main ‘Add Backup Job’ window.
-At-unload cmd+#;Day: Select ‘Friday’.
-Enter “( banner $Set_ID; medprint $Set_ID )”.+#;Time: Enter 23:00 to have the job start at 11 p.m.
-Press Return to return to the main ‘Add Backup Job’ window.+#;Append to: As you want to write each backup to a new media set, leave this field blank.
-Day Select ‘Friday’.+#Press Accept to save the job.
-Time Enter 23:00 to have the job start at 11 p.m.+ 
-Append to As you want to write each backup to a new media set, leave this field blank.+ 
 +The list of predefined backup items is then displayed automatically.
 + 
 +#Press the Search key and enter <tt>/usr/home</tt> or just scroll to that item. Move the cursor to the row for ‘full cpio of <tt>/usr/home</tt> directory’ and select that line. It doesn’t matter for this example whether the Index column says ‘yes’ or ‘no’.
 +#Now add <tt>/usr/cosmos</tt> to your selection by middle-clicking or by using the Select function. Press Accept to save the selection and return to the ‘Maintain backup jobs’ window.<br>If you miss a step or want to change an item after returning to the ‘Maintain backup jobs’ window, simply select the job again and use Jobs > Steps, then Maintain > Add to redisplay the choose list of items.
 + 
-Press Accept to save the job. The list of predefined backup items is then displayed automatically. 
-#Press the Search key and enter /usr/home or just scroll to that item. 
-Move the cursor to the row for ‘full cpio of /usr/home directory’ and select that line. It doesn’t matter for this example whether the Index column says ‘yes’ or ‘no’. 
-#Now add /usr/COSmanager to your selection by middle-clicking or by using the Select function. Press Accept to save the selection and return to the ‘Maintain backup jobs’ window. 
-If you miss a step or want to change an item after returning to the ‘Maintain backup jobs’ window, simply select the job again and use Jobs > Steps, then Maintain > Add to redisplay the choose list of items. 
This backup will now appear on the console as an outstanding job on the following Friday. It can also be run at other times; See Initiating and Managing Backups on page 89. This backup will now appear on the console as an outstanding job on the following Friday. It can also be run at other times; See Initiating and Managing Backups on page 89.
Line 282: Line 294:
#;Comment: Enter a description. Example: ‘retain for four weeks’. #;Comment: Enter a description. Example: ‘retain for four weeks’.
#Press Accept to save these details. #Press Accept to save these details.
 +
You can now select this period when you next define a backup job. You can now select this period when you next define a backup job.
<br> <br>

Current revision

The initial configuration procedure includes a task to automatically generate a weekly schedule of filesystem backups (see Generate Simple Backup Scheme on page 149). You can expand the basic schedule by adding new jobs and backup items to back up other data objects.

This section describes the process of defining backup jobs, including:

Background information on all of these topics can be found in Information on Backup Jobs on page 19.


Contents

How to Define a Backup Item

A backup item describes the ‘what’ and ‘how’ of a backup. It identifies a directory or filesystem on one host, and the method that will be used to back it up. One backup item maps to one step in a backup job.

A directory name can appear several times in the list of backup items, so that you have the choice of using different backup methods and of whether to keep an online index.


When not to create an online index

Online indexes may take up large amounts of disk space. You may choose not to create an index if the filesystem is very large or if you don’t expect to perform selected file recovery. For backups created using FScpio or FStar, an index can be created later from the backup volume.

If you want to index some backups but not others, define one item with Index=yes and one with Index=no.


Passing optional arguments to the backup method

You can use the Options field to pass extra flags and arguments to the backup command. These options are not validated when you define the backup item but are simply passed to the backup method to be evaluated at run time. See Passing Options to a Backup Method on page 163.


To define a backup item

  1. Select backup3G configuration > Maintain backup jobs, then select Items > Maintain to display the list of previously defined backup items, then select Maintain > Add.
    Item
    Defaults to one more than the current highest item number. You can change it to any unused item number, but it is recommended that you accept the default.
    Object
    Enter the name of the data object (filesystem or directory) to be backed up. For an image backup of a disk partition, enter the raw disk device name here. Make sure that the name is correct, as backup3G doesn’t check that the object exists at this point. Leave the field blank if this item will be used in a non-backup step.
    Except for backup3G variables such as $APPL_HOME and $APPL_DB, you should not use environment variables in this field. Reason: if on a remote host the variable is not set or is set to a different value, the directory name will be expanded incorrectly. Examples:
    Correct     /users/jemima/mail
                    $APPL_HOME
    Incorrect   $HOME/mail
    Host
    Select the host on which the directory is stored. If you want to back up a directory on multiple hosts, you must define a separate backup item for each.
    Method
    Press Choose to list the backup methods. Scroll to the right to see the attributes supported by each method, such as online indexes, remote backup, and multi-part backups.
    Index
    Enter ‘yes’ if you want an online index to be created when this item is backed up. If the backup method doesn’t support indexes, this field will automatically be set to ‘no’.
    Options
    Enter any optional flags and arguments to be passed to the backup method at run time.
    Comment
    Enter a descriptive comment.
    On error
    Should the backup job continue if this step fails? Select ‘continue’ if the job should continue after an error in this step. Select ‘abort’ if the job should not continue.
  2. Press Accept to save this item.



Note
Use double quotes around file patterns in Options to ensure that they are parsed correctly.


Example: single part backup step

Define an item to take a full backup of the directory /usr/home on your host machine (use a different directory name if /usr/home doesn’t exist on your host). Exclude core files from the backup.

The backup should use cpio format and an online index should be kept. If this step were to fail, the backup job should continue to the next step.

  1. Select backup3G configuration > Maintain backup jobs > Items > Maintain then select Maintain > Add.
  2. Accept the default item number.
  3. Type in the directory name: /usr/home
  4. Select the name of your host machine. You can press Choose to see the list of all the available hosts at your site.
  5. Press Choose to display the valid backup methods. Move the pointer next to full cpio and scroll right a few times. You will see that the Index column for ‘full cpio’ says ‘yes’. Choose full cpio.
  6. Set Index to ‘yes’.
  7. Enter in the Options field: -x “ */core”
  8. Now enter a comment, such as “Full backup of users home directories”
  9. Set On error to ‘continue’.
  10. Press Accept to add this item.

You can now select this item when defining a step in a backup job (see How to Define a Backup Job on page 78).


Example: multi-part backup step

Task: /usr/home is growing and may soon exceed the capacity of a single tape. Change the item defined above to allow for /usr/home to be written to multiple volumes if necessary.

  1. Select backup3G configuration > Maintain backup jobs, then Items > Maintain.
  2. Choose the item you defined in the previous example (/usr/home, ‘full cpio’), then select Maintain > Change.
  3. Move the cursor to the Method field and press Choose. Select “full cpio - MP”
  4. Press Accept to save the changed item details.


Any backup job that uses this item will now write to more than one volume if necessary.


How to Define a Backup Job

This topic tells you how to define all the information required to run a backup job:

scheduling
how and when the job is initiated, when it will run, and whether to auto-acknowledge it.
output
the drive and media type, whether this backup should be appended to an existing tape, how long the backup should be retained, and what location it should be sent to.
backup steps
which items will be backed up, plus any extra commands that must be run at the start or end of the job.


Backup3G’s scheduling features will be sufficient for most backups. If complex scheduling and inter-task dependencies are required, we recommend you use backup3G’s companion product duty3G.


To Define Information About a Backup Job

  1. Select Maintain backup jobs from the backup3G configuration menu. A list of existing backup jobs is displayed.
  2. Select Jobs > Add to display the prompt form.
    Job
    Enter a unique and representative name.
    Description
    Appears in the duty schedule, so make it meaningful to help users to choose the right backup job.
    Mode
    Select the default method for running this job:
    scheduled - if the job will run to a regular schedule and requires some operator action (such as loading a tape)
    automatic - if it will be run as an automatic duty (that is, at a set time without user intervention)
    request - if there is no regular schedule—the job will be run as required.
    Auto-acknowledge
    You may wish to avoid operators having to manually acknowledge completion of the job. The options are:
    onsuccess - automatically acknowledge this job if it finishes successfully (return status 0). This is the default.
    never - an operator must always manually acknowledge this job whatever its return status.
    always - always automatically acknowledge this job. If you choose this, you must use some other way to warn if this backup fails, such as an At-end command that sends mail to an administrator when the job returns a non-zero exit status.


When to initiate the job (scheduled or automatic backup)

The When and Run Time(s) fields determine when a scheduled or automatic backup job will be initiated.

Automatic backups start running as soon as they are initiated. Scheduled backups appear on the operator’s list of outstanding backups for the period specified in Run Time(s), and start running at the time you specify in the Day and Time fields.

When
Select the day(s) on which the job is to be run.
Run Time(s)
automatic backup: enter the time of day when the backup should run. Examples:
08:00        start the job at 8 am
08,11:00   start the job at 8 am and 11 am
08-10:30   start the job at 8.30 am, 9.30 am, and 10.30 am
scheduled backup: enter the time period during which the job should be initiated by an operator. Examples:
<blank>        all day
08:00-14:30   between 8 am and 2.30 pm
-08:00            from midnight to 8 am
08:00-            from 8 am to midnight
If not done?
(scheduled backups only) select what action to take if the job has not been started by the end of the scheduled time:
abandon - remove the job from the list of outstanding backups. It will not reappear until the next time the backup is scheduled.
outstanding - leave the job on the list of outstanding backups. It will stay outstanding until it is performed.

The next three fields specify the drive that will write the backup; how long the backup will be kept; and if it will be stored offsite, the location.

Drive/Pool
Choose the name of a drive or drive pool.
Retention
Select a retention period. The tape or disk will be released for reuse after this time.
To add a new retention period, see How to Define a Retention Period on page 88.
Store offsite
You have the option of moving this backup to another media location. Select a location or leave blank.
To add a new location, see Adding a New Media Location on page 116.


At-start, at-end, and at-unload commands

You can tell backup3G to run a command at the start or end of the job, or when the volume is unloaded from the drive. Press Backup cmd(s) to enter one or more of these commands.

Figure 14 — Defining commands to be run with the backup job

The At-start cmd runs before the first backup step. Example: bring down a database before backing it up.

The At-end cmd runs after the last backup step, just before the job ends. Example: if any step returned a non-zero exit status ($maxstatus != 0) mail details of the backup to the senior operator.

The At-unload cmd runs when the job is acknowledged. Example: printing the catalog for this media set (see Figure 30 on page 114 for a sample.) This aids data recovery when backup3G itself is unavailable.

Commands that are common to several jobs, or that need to be performed in the middle of the job, can be defined as non-backup items and then selected as required at the end of this process.


When to run the job (scheduled backup)

Scheduled backups may be initiated hours or days before they are due to run. For example, on Friday afternoon operators may submit scheduled backups to run on Saturday night. In the When and Run Time(s) fields you specified when this backup should be initiated. Now you will enter the Day and Time when the job should start.

Figure 15 — Run day and time for a scheduled backup
Day
Select a day of the week, or select ‘Next 24hrs’ to have the job run within 24 hours from when it is scheduled.
Time
Enter the time (in the format HH:MM, 24 hour clock) when the job should start.
Append to
You can write this backup to the end of an existing media set. Choose the name of the backup job you want to append to. To always write to a new media set, leave this field blank.
Appending backup strategies are discussed in Appending Backups onpage 36.

Press Accept to finish defining the job and scheduling details.


To Define the Steps in a Backup Job

The next task is to select the items to be backed up by this job. Each item comprises a filesystem or directory and the method that will be used to back it up.

At this point backup3G display the list of predefined items.

Figure 16 — Choosing the steps for a backup job



Note
Some directories may appear more than once, for example if two different backup methods may be used. You can use Search to find all the items for the directory you want.


Select the items that you want to include as steps in your job. In GUI mode, click an item to select it, Ctrl-click to add a row to the selection, and Shift-click to add several consecutive rows to the selection. In CUI mode, press the Select button to add a row to the selection, or press Select over a highlighted row to remove it from the selection.

If an item you want doesn’t appear in the list, you can add it: see How to Define a Backup Item on page 74.

Press Accept to create a backup step for each of the selected items.



To Maintain the Steps in a Backup Job

You can add, remove, or reorder the steps performed by a backup.

  1. From the backup3G configuration menu, select Maintain backup jobs.
  2. Select the backup job, then select Jobs > Steps to display the steps currently assigned to that job.
Figure 17 — Maintain backup steps window


To add steps to a job

  1. From the ‘Maintain steps’ screen, select Maintain > Add.
  2. Select one or more items.
  3. Press Accept to add the steps to the end of the backup job.


To append steps from another job

If your new job is similar to an existing backup, it may be quicker to append the steps from the older backup.

  1. From the ‘Maintain steps’ screen, select Maintain > Append.
  2. From the list of jobs displayed, select the job from which you wish to copy steps.
  3. Select Accept to have all of the steps from the chosen job added to the end of your current list.
  4. Delete unwanted steps by selecting them and using the Maintain > Remove option.


To change the order in which the steps will be run

  1. From the ‘Maintain steps’ screen, select Maintain > Reorder.
  2. Drag and drop the steps into the order required.
  3. Press Accept to save the changes and return to ‘Maintain steps’.


To Set Up a Duty for a Backup Job

This section applies only to sites with duty3G installed. When the definition of a backup job and all of its steps is complete, the job can be set up as a duty as follows:

  1. Select backup3G configuration > Maintain backup jobs.
  2. Select the job you wish to create a duty for.
  3. Select Jobs > Duty.
    The addition of the duty will be confirmed. The relevant fields are filled with values from the backup job. If there are any inconsistencies or errors, duty3G will be started so you can make the necessary alterations.
  4. Run duty3G to verify that the duty has been created. Make any changes to the name or to the scheduled run time as required using duty3G Administration options as described in the duty3G User Guide.


Example: Define a Backup Job

Task: define a job to do a full cpio backup of /usr/home and /usr/cosmos to a new media set every Friday at 11.00 p.m. The backup should be scheduled some time between noon and 5.00 pm on Friday afternoon. Retain each backup for one week. Print the media contents and mail a message when the job is finished.



Note
In the following example, backup items must already exist for /usr/home and /usr/cosmos. See To define a backup item on page 74 for details of how to add items. Use other directory names if your home and COSmanager directories are in a different location.


  1. Select Maintain backup jobs from the backup3G configuration menu. A list of existing backup jobs is displayed.
  2. Select Jobs > Add to display the prompt form.
    Job
    Enter job name ‘test_usr’.
    Description
    Enter a description that will help the user to identify this job.
    Mode
    Press Select until the mode is set to ‘scheduled’.
    Auto-acknowledge
    Leave at the default setting of ‘onsuccess’.
    When
    Choose ‘Weekly - Friday’.
    Run Time(s)
    Enter 12:00-17:00 to have the job appear on the operators’ ‘outstanding backups’ console at noon. Running the job will involve the operator loading the requested tape into the drive in preparation for the 11 p.m. execution of backup.
    If not done?
    select ‘outstanding’ to keep the job on the console until it is scheduled.
    Drive/Pool
    Press Choose to see the list of valid drive/pool names. Select a drive and press Accept.
    Retention
    Select one week.
    Store offsite
    As this backup won’t be stored offsite, press Enter or the down arrow key to skip over this field.
  3. Press Backup cmd(s).
    At-start cmd
    Skip this field.
    At-end cmd
    Enter “mailx -s “incremental backup of /usr/home and /usr/COSmanager: status $maxstatus” < /dev/null“.
    At-unload cmd
    Enter “( banner $Set_ID; medprint $Set_ID )”.
  4. Press Accept to return to the main ‘Add Backup Job’ window.
    Day
    Select ‘Friday’.
    Time
    Enter 23:00 to have the job start at 11 p.m.
    Append to
    As you want to write each backup to a new media set, leave this field blank.
  5. Press Accept to save the job.


The list of predefined backup items is then displayed automatically.

  1. Press the Search key and enter /usr/home or just scroll to that item. Move the cursor to the row for ‘full cpio of /usr/home directory’ and select that line. It doesn’t matter for this example whether the Index column says ‘yes’ or ‘no’.
  2. Now add /usr/cosmos to your selection by middle-clicking or by using the Select function. Press Accept to save the selection and return to the ‘Maintain backup jobs’ window.
    If you miss a step or want to change an item after returning to the ‘Maintain backup jobs’ window, simply select the job again and use Jobs > Steps, then Maintain > Add to redisplay the choose list of items.


This backup will now appear on the console as an outstanding job on the following Friday. It can also be run at other times; See Initiating and Managing Backups on page 89.


How to Define a Retention Period

Backups are retained for a set period. At midnight on the expiry date, the media set is released. The backup data is not physically erased, but the tape or disk becomes available to be selected by another job. Example: a media set with an expiry date of 30 June cannot be re-selected until 1 July.

The retention period is specified in the backup job.

There is a special retention period, ‘forever’. This sets the expiry date to null, meaning that the volume never expires. You can also add your own retention periods.


To define a retention period

  1. Select backup3G configuration > Maintain tables.
  2. Select the ‘Retention Periods’ table, then select Table > Maintain.
  3. Select Maintain > Add.
    Retention
    Enter a name. Example: ‘pay month’.
    Days
    Enter the period in whole days. Example: ‘28’.
    Comment
    Enter a description. Example: ‘retain for four weeks’.
  4. Press Accept to save these details.


You can now select this period when you next define a backup job.