...
It is the basic transport protocol of bsr and is a standard protocol that can be used on all systems that support IPv4/v6.
...
Fast Synchronization
In bsr , replication and (re)synchronization are separate concepts. Replication is a process that reflects all disk write operations of the resource of the primary role in real time to a secondary node, and synchronization is a process of copying block data from the perspective of all block devices excluding real-time write I/O. Replication and synchronization work individually, but they can be processed simultaneously.
If the connection between the primary and secondary is maintained, replication continues. However, if the replication connection is interrupted due to a failure of the primary or secondary node, or the replication network is disconnected, synchronization between the primary and secondary is required.
When synchronizing, bsr does not synchronize blocks in the order in which the original I/O was written to disk. Synchronization sequentially synchronizes only the areas that are not synchronized from sector 0 to the last sector based on the information in the metadata and efficiently processes as follows.
Synchronization is performed block by block according to the block layout of the disk, so disk search is rarely performed.
It is efficient because it synchronizes only once for blocks in which multiple writes have been made in succession.
During synchronization, some of the Standby node's entire dataset is past and some are updated to the latest. The status of this data is called Inconsistent, and the status that all blocks are synchronized with the latest data is called UpToDate. Nodes in an inconsistent state are generally in a state where the volume is not available, so it is desirable to keep this state as short as possible.
Of course, even if synchronization is performed in the background, the application service of the Active node can be operated continuously with or without interruption.
Fixed-rate synchronization
In fixed-rate synchronization, the data rate synchronized to the peer node can be adjusted within the upper limit in seconds (this is called the synchronization rate), and can be specified as the minimum (c-min-rate) and maximum (c-max-rate).
Variable-rate synchronization
In Variable-rate synchronization bsr detects the available network bandwidth and compares it to I/O received from the application, automatically calculates the appropriate synchronization speed. bsr defaults to variable-band synchronization.
Checksum-based synchronization
Checksum data summarization can further improve the efficiency of the synchronization algorithm. Checksum-based synchronization reads blocks before synchronizationimplements FastSync, which synchronizes only the part being used in the volume. If FastSync does not work, synchronization is required for the entire volume area, so if the volume is large, it takes a lot of synchronization time. FastSync is a powerful feature of bsr that can save a lot of synchronization time.
Efficient synchronization
In bsr, replication and (re)synchronization are separate concepts. Replication is a process that reflects all disk write operations of the resource of the primary role in real time to a secondary node, and synchronization is a process of copying block data from the perspective of all block devices excluding real-time write I/O. Replication and synchronization work individually, but they can be processed simultaneously.
If the connection between the primary and secondary is maintained, replication continues. However, if the replication connection is interrupted due to a failure of the primary or secondary node, or the replication network is disconnected, synchronization between the primary and secondary is required.
When synchronizing, bsr does not synchronize blocks in the order in which the original I/O was written to disk. Synchronization sequentially synchronizes only the areas that are not synchronized from sector 0 to the last sector based on the information in the metadata and efficiently processes as follows.
Synchronization is performed block by block according to the block layout of the disk, so disk search is rarely performed.
It is efficient because it synchronizes only once for blocks in which multiple writes have been made in succession.
During synchronization, some of the Standby node's entire dataset is past and some are updated to the latest. The status of this data is called Inconsistent, and the status that all blocks are synchronized with the latest data is called UpToDate. Nodes in an inconsistent state are generally in a state where the volume is not available, so it is desirable to keep this state as short as possible.
Of course, even if synchronization is performed in the background, the application service of the Active node can be operated continuously with or without interruption.
Fixed-rate synchronization
In fixed-rate synchronization, the data rate synchronized to the peer node can be adjusted within the upper limit in seconds (this is called the synchronization rate), and can be specified as the minimum (c-min-rate) and maximum (c-max-rate).
Variable-rate synchronization
In Variable-rate synchronization bsr detects the available network bandwidth and compares it to I/O received from the application, automatically calculates the appropriate synchronization speed. bsr defaults to variable-band synchronization.
Checksum-based synchronization
Checksum data summarization can further improve the efficiency of the synchronization algorithm. Checksum-based synchronization reads blocks before synchronization, obtains a hash summary of what is currently on disk, and then compares the obtained hash summary by reading the same sector from the other node. If the hash values match, the re-write of the block is omitted. This method can be advantageous in performance compared to simply overwriting a block that needs to be synchronized, and if the file system rewrites the same data to a sector while disconnected (disconnected), resynchronization is skipped for that sector, so you can shorten the synchronization time in overall.
...
A secondary node that has a primary crash or a disconnected connection may have a disk status of Outdated.
Truck based synchronization
Tuck based synchronization, which directly imports and configures the disk, is suitable for the following situations.
When the amount of data to be initially synchronized is very large (over tens of terabytes)
When the rate of change of the data to be copied is expected to be small compared to the huge data size
When available network bandwidth between sites is limited
In the above case, if you do the normal initial synchronization, it will take a very long time. This method is recommended if the disk size is large and you can directly copy and initialize it physically.