| Previous | Next |
| hrBadLogVersion | hrLoggingDisabled |
hrInvalidLogSequence
Where the workflow stopped
hrInvalidLogSequence means the next log does not continue the expected sequence identity or timestamp chain.
The stored value is 0xC8000203 (negative JET error -515; -515). Current ESE documentation uses JET_errInvalidLogSequence for the corresponding published JET condition.
The first useful distinction is that contiguous filenames alone are insufficient when the internal sequence identity changes. Start by capturing adjacent generation numbers, timestamps, signatures, base names, and the directories from which each file came.
Similar-looking outcomes
This result specifically means that contiguous filenames alone are insufficient when the internal sequence identity changes. Related values below can appear in the same workflow but require a different response:
hrMissingLogFile | the active or current transaction log expected by the instance is absent |
|---|---|
hrLogSequenceEnd | the legacy log generation namespace reached its maximum value |
hrMissingPreviousLogFile | the checkpoint requires an earlier log generation that is absent from the available sequence |
Objects and state involved
| Diagnostic layer | checkpoint position and the continuous transaction-log generation sequence |
|---|---|
| Relevant API surface | JetInit recovery, hard restore ranges, checkpoint processing, and log enumeration |
| Code-specific condition | the next log does not continue the expected sequence identity or timestamp chain |
| Narrow corrective direction | remove the foreign branch and supply a continuous sequence from the same database/log lineage |
The checkpoint identifies the oldest log work not yet fully represented in database pages. Recovery requires every mandatory generation in order and from one signature lineage.
Minimum useful trace
- Code-specific observation: capture adjacent generation numbers, timestamps, signatures, base names, and the directories from which each file came.
- Checkpoint generation: capture the value and timestamp from the first occurrence.
- Complete generation inventory: capture the value and timestamp from the first occurrence.
- Log signatures and timestamps: capture the value and timestamp from the first occurrence.
- Database required range: capture the value and timestamp from the first occurrence.
Steps to resolve it
- Record it,
0xC8000203, the API name, the current phase, and all live context or file owners. - Verify the condition by capturing adjacent generation numbers, timestamps, signatures, base names, and the directories from which each file came.
- Apply only the targeted fix: remove the foreign branch and supply a continuous sequence from the same database/log lineage.
Actions that can make diagnosis worse
- Do not create an empty replacement log.
- Do not join gaps with logs from a different server or backup lineage.
Acceptance criteria for a fix
A useful regression test should force the condition “the next log does not continue the expected sequence identity or timestamp chain”, call one documented API transition, and assert the exact HRESULT.
Technical references
- ESE checkpoint and log files — API ordering, file semantics, warning/error interpretation, or recovery behavior relevant to this HRESULT.
- Transaction-log parameters
- JetExternalRestore phases
- Microsoft JET_ERR enumeration
Looking for a different code? Search another status or error code.
