Lost Write Detection via Version Number Comparison
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Data corruption due to 'lost writes' occurs when write operations are delayed or fail, leading to incorrect data being read and propagated, causing errors and system instability in database applications and storage systems.
Innovation Solution
The solution involves detecting lost writes by comparing version numbers in redo log entries with those in standby database blocks, and implementing read logging to identify and repair corrupted data, with an enhanced technique using a read validation cache to reduce performance impact.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If version number comparison and read logging are implemented to detect lost writes, then data integrity is improved, but system performance and complexity worsen
Solution Approach 1:
The patent implements preliminary action by maintaining a read validation cache that stores version numbers of previously validated blocks. Before performing a read operation, the system checks the cache to determine if validation is needed, avoiding redundant validation operations and reducing performance overhead while maintaining data integrity.
Solution Approach 2:
The patent applies local quality by selectively validating only those data blocks that are actually read from storage, rather than validating all blocks. The read validation cache tracks which blocks have been validated, allowing the system to focus validation resources on relevant data while minimizing unnecessary processing overhead.
2Measurement precision
If comprehensive read logging is performed to detect lost writes, then detection accuracy is improved, but performance degradation increases
Solution Approach 1:
The patent implements partial action by logging only read operations that require validation, rather than logging all read operations. The read validation cache determines which blocks need validation based on whether their version numbers match cached values, allowing the system to achieve sufficient detection accuracy while minimizing logging overhead.
Solution Approach 2:
The patent uses copying by maintaining a cached copy of version numbers in the read validation cache. This cached copy allows the system to quickly determine validation needs without accessing the full validation data structures, reducing the performance impact of comprehensive validation while maintaining detection accuracy.
3Loss of information
If data validation and repair mechanisms are implemented, then data purity is improved, but processing time and system complexity worsen
Solution Approach 1:
The patent performs preliminary validation by checking the read validation cache before processing read operations. This preliminary check identifies blocks that have already been validated, allowing the system to skip redundant validation and repair operations, thereby maintaining data purity while reducing processing time.
Solution Approach 2:
The read validation cache serves as a self-service mechanism that automatically tracks which blocks have been validated and which need validation. This self-tracking eliminates the need for complex external validation management, reducing system complexity and processing overhead while maintaining data purity through systematic validation.
Data Source
AI summary
Techniques are provided for detecting lost writes so that data corruption can be avoided. According to one technique, lost writes are detected by comparing version numbers that are indicated in redo log entries with version numbers that are indicated in corresponding blocks in a standby database. According to one technique, which may be used in conjunction with the above technique, lost writes are detected by logging read operations that occur relative to a primary database, and comparing version numbers that are indicated in read log entries with version numbers that are indicated in corresponding blocks in a standby database. According to one technique, lost writes are detected by comparing, in response to read operations, (a) version numbers that are stored in a persistent in-memory cache with (b) version numbers that are indicated in corresponding blocks that are read from a primary database.


