Patent ID: 8554733
Filing Date: 2013-10-08
Classification: G06F

Abstract:
1. A log application method for maintaining a backup database in a sub-storage of a sub-site, the backup database being a replica of a main database maintained in a main storage of a main site by a database system, said log application method comprising the steps of: storing, by a first server, log records in said main storage, the log records indicating history of updating of said main database, wherein the log records are stored in units of log blocks, each log block including a header and a trailer, and a plurality of said log records between said header and said trailer, wherein a second server reads from said header to said trailer when said second server reads said log block, wherein said main site comprises said first server, said main storage, and a first controller, and said sub-site comprises said second server, said sub-storage, and a second controller, wherein said sub-site is located at a remote site, and wherein said first controller and said main storage are coupled to said first server, and said second controller and said sub-storage are coupled to said second server; copying said log blocks of said main database from said main storage of said main site to said sub-storage of said sub-site through a remote copy operation performed by said first controller of said main storage of said main site and said second controller of said sub-storage of said sub-site, by transferring said log blocks stored in said main storage from said main storage of said main site to said sub-storage of said sub-site, wherein said remote copy operation is performed independently of said first server and said second server; reading, by said second server, a first log block including log records to be applied to said backup database, which is stored next to a log block including log records last applied, from said sub-storage to verify consistency of said first log block, said header and said trailer included in said first log block being used to verify the consistency; determining, after said second server has read said header and said trailer included in said first log block, whether a rereading process on said first log block is expected to be free from conflicting with the writing process of said remote copy operation by first determining whether a second log block can be read, and when the second log block can be read, reading said second log block, which is next to said first log block; and when said rereading process on said first log block has been determined to be free from conflicting with the writing process of said remote copy operation, rereading, by the second server, the first log block including the log records to be applied, and then applying the log records contained in the reread first log block to said backup database.