Selecting the backup policy should be decided in consideration of the operation environment, such as the importance of data, recovery policy, and backup size. This chapter describes the considerations for determining a backup policy.
Select backup target
To determine a backup policy, the first thing to do is to select a backup target. In addition, in consideration of the characteristics of the backup target the recovery policy, backup type, backup cycle, backup time, and storage period of backup files must be determined first.
This backup plan is not something that the DBA can do alone and requires a data manager to cooperate with. This is because the person who is in charge of the operation needs to know which backup target is most suitable.
Recovery point
There is a difference in the time of recovery depending on the backup type. Depending on the importance of the backup target, a recovery point should be determined a backup method should be selected accordingly.
There are three major recovery points.
Recovery point | Description |
---|---|
Backup point | This refers to the restoration to the point in time when the backup was performed. |
Complete recovery | This refers to the restoration to the most recent point in the database. This is possible only when online log files and archive log files are not lost. |
Incomplete recovery | This refers to the restoration to a certain past point in time. Incomplete recovery is possible at two points in time.
|
The table below summarizes the recovery points by backup type. Select a backup method suitable for the backup target by referring to the table.
Backup type | Backup point | Complete backup | Incomplete backup | |
---|---|---|---|---|
Logical backup | Possible | N/A | N/A | |
Physical backup | Online backup | Possible | Possible | Possible |
Online backup | Possible | N/A | N/A | |
Incremental backup | Possible | Possible | Possible |
Recovery time
Recovery is an operation that must be performed after a service interruption. Operation environments in which service downtime must be minimized when determining the backup policy.
Since the factors that affect the recovery time differ depending on the backup type, please refer to the table below and select the method that suits the characteristics of the backup target.
Backup type | Factors affecting recovery time | Description | |
---|---|---|---|
Logical backup | aexport |
| If creating objects is necessary during the recovery process, the number of objects can affect the recovery time. |
iloader |
| Since the information of the file is read and inserted into the table (INSERT), the number of tables, the number of records, and the number of indexes affect the recovery time. | |
Physical backup | Online backup |
| Recovery is in progress while the Altibase server is running. |
Offline backup |
| The recovery time is shortest because the Altibase is restored by running only the backup file. When running the Altibase server, it takes time to load the memory table data into the memory and rebuild the memory index.
| |
Incremental backup |
| During the recovery process, it takes time to load the memory table data into memory and rebuild the memory index. |
Backup performing time
The backup performing time takes a long time as the size of the database is larger, and it affects the transaction while executing the backup. Therefore, it is recommended to perform a backup at idle time during the Altibase operation.
This table summarizes the factors that affect the backup time by backup type and how they affect transactions.
Backup time
Backup type Factors affecting the time to back up Description Logical backup aexport - Number of database objects Since the object creation script is created, it is affected by the number of database objects at backup time. iloader - Number of tables
- Usage of tablesSince a text file created by retrieving data for each table, the time required for backup is affected by the number and usage of tables. Physical backup Online backup - Size of disk table data file
- Size of memory checkpoint imageOnline backup is a process of physically copying data files, so the size of the data file affects the time required for backup. Offline backup - Size of disk table data file
- Size of memory checkpoint image fileOffline backup is also a process of physically copying data files, and the time required for backup is affected by the size of the data file. Incremental backup Level 0 incremental backup - Size of disk table data file
- Size of memory checkpoint image fileAs a backup in a similar method to online backup, the size of the data file affects the time required for backup. Level 1 incremental backup - amount of change of data page The time required for level 1 incremental backup is affected by the amount of data page change caused by the change transaction.
Transaction
This is a table comparing the impact on transactions when performing a backup
Backup type Impact on transaction Logical backup aexport Temporarily unable to perform DDL iloader Memory GC increase during backup Physical backup Online backup Online log file increase due to inability to perform checkpoint during backup Offline backup Service downtime required Incremental backup Normal DB performance degradation by activating the 'Page Change Tracking' function
Online log file increase due to inability to perform checkpoint during backup
Backup copy storage cycle
It is recommended to keep at least two backup copies.
This is to prepare for the loss of backup copies due to an incorrect backup or a disk fault or user fault.
Configuring disk partitions for backup
If the object storing the backup file is a disk, it is recommended that the backup location be set to space physically separated from the path where the database data files and log files are located.
During the database operation, disk I/O occurs as follows. However, an exception in the case of a service that mainly occurs only retrieving transactions in the memory table.
- Disk I/O for log files where changes to the database are recorded
- Disk I/O to record to the memory checkpoint image file in the memory table
- Disk I/O to read and record data files in the disk table
Therefore, disk space is separated to minimize bottlenecks between disk I/O occurring during database operation and disk I/O while executing the backup.