# US 12,417,153 B2 · Optimization of log record application during database recovery

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 12,417,153 B2
- Document ID: US12417153B2
- Status: Granted
- Kind: B2
- Application number: 18/401,293
- Filed: 2023-12-29
- Published: 2025-07-03
- Granted: 2025-09-16
- Earliest claimed: 2023-12-29
- Assignees: BMC Software, Inc.
- Applicants: BMC Software, Inc.
- Inventors: William J. Pothoff; Vladimir Prasolov; Konstantin Lavren Bobovich
- Web page: https://patentgrep.com/patent/US12417153B2

## CPC

- G06F 11/1471: involving logging of persistent data for recovery
- G06F 11/1469: {Backup restoration techniques}
- G06F 2201/80: Database-specific techniques
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A captured sequence of log records for a copy of a database may be inspected to identify an obviating log record at a captured sequence position of the captured sequence and related to a page of the plurality of pages, the obviating log record corresponding to an obviating change that replaces an earlier change of an earlier log record. The captured sequence of log records may be sorted into an applied sequence of log records for applying changes of the sequence of changes, in which the obviating log record is moved from the captured sequence position to an applied sequence position that is prior to the earlier sequence position of the earlier log record. The database may then be recovered using the applied sequence of log records.

## Claims

### Claim 1

A computer program product including a non-transitory computer-readable storage medium storing instructions that, when executed by at least one computing device, are configured to cause the at least one computing device to:
identify, for a database recovery, a copy for a database, the copy being stored at a first time as a plurality of pages;
identify a captured sequence of log records, the captured sequence of log records being captured between the first time and a second time and corresponding to a sequence of changes made to the database between the first time and the second time, with each log record of the captured sequence of log records corresponding to a change of the sequence of changes;
identify, in the captured sequence of log records, an obviating log record at a captured sequence position of the captured sequence of log records and related to a page of the plurality of pages, the obviating log record corresponding to an obviating change that replaces an earlier change of an earlier log record at an earlier sequence position within the captured sequence of log records and with respect to the page;
sort the captured sequence of log records into an applied sequence of log records for applying changes of the sequence of changes, in which the obviating log record is moved from the captured sequence position to an applied sequence position that is prior to the earlier sequence position of the earlier log record; and
recover the database to the second time using the applied sequence of log records during the database recovery.

### Claim 2 (depends on 1)

The computer program product of claim 1, wherein the copy is a copy of an index of the database.

### Claim 3 (depends on 1)

The computer program product of claim 1, wherein the instructions are further configured to cause the at least one computing device to:
classify each log record of the captured sequence of log records as either a full page log record affecting full page content or as a partial page log record affecting a portion of page content of a corresponding page of the plurality of pages.

### Claim 4 (depends on 1)

The computer program product of claim 1, wherein the instructions are further configured to cause the at least one computing device to:
identify the obviating log record as corresponding to a full page log record affecting full page content of a corresponding page of the plurality of pages.

### Claim 5 (depends on 1)

The computer program product of claim 1, wherein the instructions are further configured to cause the at least one computing device to:
sort the captured sequence of log records by page of the plurality of pages.

### Claim 6 (depends on 1)

The computer program product of claim 1, wherein the instructions are further configured to cause the at least one computing device to:
select a selected page of the plurality of pages of the captured sequence of log records; and
classify corresponding log records for the selected page as either a full page log record affecting full page content of the selected page or as a partial page log record affecting a portion of page content of the selected page.

### Claim 7 (depends on 6)

The computer program product of claim 6, wherein the instructions are further configured to cause the at least one computing device to:
sort one or more full page log records of the selected page in descending log record sequence order within the applied sequence of log records to identify a first full page log record of the sorted one or more full page log records as the obviating log record.

### Claim 8 (depends on 7)

The computer program product of claim 7, wherein the instructions are further configured to cause the at least one computing device to:
sort partial page log records of the selected page in ascending log record sequence order, following the one or more full page log records, within the applied sequence of log records.

### Claim 9 (depends on 8)

The computer program product of claim 8, wherein the instructions are further configured to cause the at least one computing device to:
apply the first full page log record of the sorted one or more full page log records within the applied sequence of log records to the selected page; and
skip application of a second or subsequent full page log record of the sorted one or more full page log records within the applied sequence of log records, if any, to the selected page.

### Claim 10 (depends on 8)

The computer program product of claim 8, wherein the instructions are further configured to cause the at least one computing device to:
apply the first full page log record of the sorted one or more full page log records within the applied sequence of log records to the selected page; and
skip application of a partial page log record of the sorted partial page log records to the selected page when the partial page log record occurs prior to the first full page log record within the captured sequence of log records.

### Claim 11

A computer-implemented method, the method comprising:
identify, for a database recovery, a copy for a database, the copy being stored at a first time as a plurality of pages;
identifying a captured sequence of log records, the captured sequence of log records being captured between the first time and a second time and corresponding to a sequence of changes made to the database between the first time and the second time, with each log record of the captured sequence of log records corresponding to a change of the sequence of changes;
identifying, in the captured sequence of log records, an obviating log record at a captured sequence position of the captured sequence of log records and related to a page of the plurality of pages, the obviating log record corresponding to an obviating change that replaces an earlier change of an earlier log record at an earlier sequence position within the captured sequence of log records and with respect to the page;
sorting the captured sequence of log records into an applied sequence of log records for applying changes of the sequence of changes, in which the obviating log record is moved from the captured sequence position to an applied sequence position that is prior to the earlier sequence position of the earlier log record; and
recovering the database to the second time using the applied sequence of log records during the database recovery.

### Claim 12 (depends on 11)

The method of claim 11, further comprising:
classifying each log record of the captured sequence of log records as either a full page log record affecting full page content or as a partial page log record affecting a portion of page content of a corresponding page of the plurality of pages.

### Claim 13 (depends on 11)

The method of claim 11, further comprising:
identifying the obviating log record as corresponding to a full page log record affecting full page content of a corresponding page of the plurality of pages.

### Claim 14 (depends on 11)

The method of claim 11, further comprising:
selecting a selected page of the plurality of pages of the captured sequence of log records; and
classifying corresponding log records for the selected page as either a full page log record affecting full page content of the selected page or as a partial page log record affecting a portion of page content of the selected page.

### Claim 15 (depends on 14)

The method of claim 14, further comprising:
sorting one or more full page log records of the selected page in descending log record sequence order within the applied sequence of log records to identify a first full page log record of the sorted one or more full page log records as the obviating log record.

### Claim 16 (depends on 15)

The method of claim 15, further comprising:
sorting partial page log records of the selected page in ascending log record sequence order, following the one or more full page log records, within the applied sequence of log records.

### Claim 17 (depends on 16)

The method of claim 16, further comprising:
applying the first full page log record of the sorted one or more full page log records within the applied sequence of log records to the selected page;
skipping application of a second or subsequent full page log record of the sorted one or more full page log records within the applied sequence of log records, if any, to the selected page; and
skipping application of a partial page log record of the sorted partial page log records to the selected page when the partial page log record occurs prior to the first full page log record within the captured sequence of log records.

### Claim 18

A system comprising:
at least one memory including instructions; and
at least one processor that is operably coupled to the at least one memory and that is arranged and configured to execute instructions that, when executed, cause the at least one processor to:
identify, for a database recovery, a copy for a database, the copy being stored at a first time as a plurality of pages;
identify a captured sequence of log records, the captured sequence of log records being captured between the first time and a second time and corresponding to a sequence of changes made to the database between the first time and the second time, with each log record of the captured sequence of log records corresponding to a change of the sequence of changes;
identify, in the captured sequence of log records, an obviating log record at a captured sequence position of the captured sequence of log records and related to a page of the plurality of pages, the obviating log record corresponding to an obviating change that replaces an earlier change of an earlier log record at an earlier sequence position within the captured sequence of log records and with respect to the page;
sort the captured sequence of log records into an applied sequence of log records for applying changes of the sequence of changes, in which the obviating log record is moved from the captured sequence position to an applied sequence position that is prior to the earlier sequence position of the earlier log record; and
recover the database to the second time using the applied sequence of log records during the database recovery.

### Claim 19 (depends on 18)

The system of claim 18, wherein the instructions are further configured to cause the at least one processor to:
select a selected page of the plurality of pages of the captured sequence of log records;
classify corresponding log records for the selected page as either a full page log record affecting full page content of the selected page or as a partial page log record affecting a portion of page content of the selected page;
sort one or more full page log records of the selected page in descending log record sequence order within the applied sequence of log records to identify a first full page log record of the sorted one or more full page log records as the obviating log record; and
sort partial page log records of the selected page in ascending log record sequence order, following the one or more full page log records, within the applied sequence of log records.

### Claim 20 (depends on 19)

The system of claim 19, wherein the instructions are further configured to cause the at least one processor to:
apply the first full page log record of the sorted one or more full page log records within the applied sequence of log records to the selected page;
skip application of a second or subsequent full page log record of the sorted one or more full page log records within the applied sequence of log records, if any, to the selected page; and
skip application of a partial page log record of the sorted partial page log records to the selected page when the partial page log record occurs prior to the first full page log record within the captured sequence of log records.
