JPS61193241A - Updated career recording - Google Patents

Updated career recording

Info

Publication number
JPS61193241A
JPS61193241A JP60033449A JP3344985A JPS61193241A JP S61193241 A JPS61193241 A JP S61193241A JP 60033449 A JP60033449 A JP 60033449A JP 3344985 A JP3344985 A JP 3344985A JP S61193241 A JPS61193241 A JP S61193241A
Authority
JP
Japan
Prior art keywords
updated
update
journal
record
contents
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP60033449A
Other languages
Japanese (ja)
Inventor
Koyo Hashimoto
橋本 幸洋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hitachi Ltd
Original Assignee
Hitachi Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hitachi Ltd filed Critical Hitachi Ltd
Priority to JP60033449A priority Critical patent/JPS61193241A/en
Publication of JPS61193241A publication Critical patent/JPS61193241A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment

Abstract

PURPOSE:To reduce the amount of updated career to be recorded on a recording medium by half by obtaining exclusive OR 8 of the contents before and after updated, merging them to one content and outputting it to the recording medium as a journal when updating a main memory or a data base, etc. CONSTITUTION:The shaped portions show updated areas. Conventionally an updated history journal 23 is made of record contents before and after updating without any modification, while this updated career journal 24 is made by exclusively ORing 8 record contents before and after updating which are merged to one content. In addition, to this updated career journal 24, the initial byte of the initial field to be updated in the before record 21 is added as an identification information 25 to judge whether the system is at the before state or the after state when the system is recovered from a trouble. In such a way, the updated career is made not of both before and after record contents, but of one content whereto both the contents are merged; thus the record quantity of updated history on the recording medium can be reduced by half compared with the conventional method.

Description

【発明の詳細な説明】 C発明の利用分野〕 本発明はオンラインリアルタイムシステムやデータベー
スシステムにおいて、主記憶装置あるいはデータベース
の更新履歴をジャーナルとして記録媒体に記録する方式
に関する。
DETAILED DESCRIPTION OF THE INVENTION C. Field of Application of the Invention The present invention relates to a method for recording update history of a main storage device or a database in a recording medium as a journal in an online real-time system or a database system.

〔発明の背景〕[Background of the invention]

一般的にオンラインリアルタイムシステム等においては
、障害対策のため、主記憶装置あるいはデータベースを
更新した場合、その更新履歴をジャーナルとしてディス
ク装置等に出力している。
Generally, in an online real-time system, when a main storage device or a database is updated, the update history is output as a journal to a disk device, etc. as a countermeasure against failures.

この場合、従来は、更新履歴として、更新前と更新後の
両方の内容をディスク装置等に出力している。この方式
によれば、障害発生時に更新前後いずれの状態にも直ち
に回復できる利点があるが、反面、更新前後の両方の内
容を出力しているため、ディスク装置等の記録媒体にお
いて更新履歴情報で占める領域が増加し、また、記録媒
体に対する入出力回数が増加して、システムの性能が低
下するという問題があった。
In this case, conventionally, both the pre-update and post-update contents are output as the update history to a disk device or the like. This method has the advantage of being able to immediately recover from either the pre- or post-update state when a failure occurs, but on the other hand, since the contents of both the pre- and post-update states are output, the update history information cannot be stored on a recording medium such as a disk device. There is a problem in that the area occupied increases and the number of inputs and outputs to the recording medium increases, resulting in a decrease in system performance.

〔発明の目的〕[Purpose of the invention]

本発明の目的は、更新履歴情報の記録量を削減すること
によって、記録媒体の利用効率、シスシムの処理効率を
高めると共に、障害発生時、更新前後のいずれの状態に
も回復できる更新履歴記録方式を提供することにある。
It is an object of the present invention to provide an update history recording method that improves the usage efficiency of recording media and system processing efficiency by reducing the amount of update history information recorded, and that can recover from any state before or after an update when a failure occurs. Our goal is to provide the following.

〔発明の概要〕[Summary of the invention]

本発明は、主記憶装置あるいはデータベース等を更新す
る場合、更新前と更新後の内容を排他的論理和゛して1
つにマージし、ジャーナルとして記録媒体に、出力する
。、これにより、記録媒体における更新履歴の記録量を
半減することができる。また、障害発生時、更新前の状
態に戻すには、主記憶装置あるいはデータベース上の更
新後の内iと更新履歴情報とを再び排他的論理和すれば
よい。
When updating a main storage device, a database, etc., the present invention performs an exclusive OR of the contents before and after the update.
and output it to a recording medium as a journal. , Thereby, the amount of update history recorded on the recording medium can be halved. Furthermore, in order to return to the state before the update when a failure occurs, it is sufficient to perform an exclusive OR operation on the updated i in the main storage device or the database and the update history information again.

〔発明の実施例〕[Embodiments of the invention]

第1図は本発明が適用されるオンラインリアルタイムシ
ステムの概略構成を示す、、システム立上げに先立って
、中央処理装置2はバックアップ取得プログラム21に
より、主記憶装置3やデータベース4のデータを磁気テ
ープ装置等のバックアップファイル6に出力して保管す
る。後述するように、このバックアップファイル6は、
障害発生によりシステム状態が壊滅的状態となった場合
FIG. 1 shows a schematic configuration of an online real-time system to which the present invention is applied. Prior to system startup, the central processing unit 2 uses a backup acquisition program 21 to transfer data from the main storage device 3 and database 4 to magnetic tape. It is output and stored in a backup file 6 of the device, etc. As described later, this backup file 6 is
When the system status becomes catastrophic due to the occurrence of a failure.

まずシステム状態を処理開始時の状態に回復させる上で
必要となる。主記憶装置3やデータベース4のデータを
ファイル6にバックアップした後。
First, it is necessary to restore the system state to the state at the start of processing. After backing up data in the main storage device 3 and database 4 to file 6.

システムは稼動を開始する。The system starts operating.

システムの稼動中において、端末装置1から入力され元
メツセージを処理する中央処理装置2のプログラムが、
主記憶装置3上のテーブル31やデータベース4上のレ
コード41を更新する場合。
While the system is in operation, a program in the central processing unit 2 that processes original messages input from the terminal device 1
When updating the table 31 on the main storage device 3 or the record 41 on the database 4.

更新した内容を中央処理装!12内に保持した後、ジャ
ーナル取得ルーチン22が呼び出される。ジャーナル取
得ルーチン22は、主記憶装置3やデ、−タベース4上
にある未だ更新前の内容と中央処、理装置2内に保持さ
れている更新後の内容とによって更新履歴情報(更新履
歴ジャーナル)31’。
Central processing unit with updated contents! 12, the journal acquisition routine 22 is called. The journal acquisition routine 22 acquires update history information (update history journal) based on the unupdated contents in the main storage device 3 and database 4 and the updated contents held in the central processing unit 2. )31'.

41′を作成し、磁気ディスク装置等のジャーナルファ
イル5に出力する。その後1通常のプログラムに処理が
戻り、該プログラムは中央処理装置2内に保持しておい
た更新データを主記憶装置3やデータベース4に転送す
る。
41' and output it to the journal file 5 of a magnetic disk device or the like. Thereafter, the processing returns to the normal program 1, which transfers the update data held in the central processing unit 2 to the main storage device 3 and database 4.

第2図は従来方式と本発明方式による更新履歴ジャーナ
ルのフォーマットを比較する図である。
FIG. 2 is a diagram comparing the formats of update history journals according to the conventional method and the method according to the present invention.

第2図において、21は更新前のレコード、22は更新
後のレコードである。斜線で囲った部分が更新領域を示
す。従来は両レコード21.22の更・新前と更新後の
記録内容をそのまN更新履歴として更新層・歴ジャーナ
ル23を・作成していた。これに対して、本発明は更新
前の記録内容と更新後の記録内容を排他的論理和して1
つにマージし。
In FIG. 2, 21 is a record before updating, and 22 is a record after updating. The shaded area indicates the update area. Conventionally, the update layer/history journal 23 was created by using the recorded contents of both records 21 and 22 before and after the update as the N update history. In contrast, the present invention performs an exclusive OR of the recorded content before the update and the recorded content after the update.
merge into.

更新履歴ジャーナル24を作成する。さらに、この更新
履歴ジャーナル24に、障害発生後のシステム回復時に
システムの状態が更新前と更新後のいずれの状態にある
かを判定するための識別情報25として、更新前レコー
ド21中の更新される先頭フィールドの先頭1バイトを
付加する。
An update history journal 24 is created. Furthermore, this update history journal 24 contains information about the updated information in the pre-update record 21 as identification information 25 for determining whether the system status is before or after the update when the system recovers after a failure occurs. Add the first 1 byte of the first field.

前述したように、主記憶装置3上のテーブル31やデー
タベース4上のレコード41を更新する場合、ジャーナ
ル取得ルーチン22で更新履歴ジャーナル33’、41
’ を作成してジャーナルファイル5に出力し、その・
後、通常のプログラム処理に戻って中央処理袋@2に保
持しておいた更新後、の内容を主記憶装置l!3やデー
タベース4に転送し、テーブル31やレコード41を更
新する。従って、更新履歴ジャーナル33’ 、34’
 をジャーナルファイル5に取得してから主記憶装置3
のテーブル31やデータベース4のレコード41が実際
に書き替えられるまでには、ある程度の時間遅れが生じ
る。この間に障害が発生すると、ジャーナルフ1.アイ
ル5に更新履歴ジャーナルが出力されていても、主記憶
装置3やデータベース4には更新前の内容が残っている
ことになる。障害発生後のシステム回復時、主記憶装置
3やデータベース4の内容が更新前か更新後かは、第3
図の更新履歴ジャーナル24に付加した識別情報25で
判定する。即ち、識別情報25は更新前のデータである
ため、これと主記憶装置3やデータベース4の該当デー
タを比較することにより、一致した場合は主記憶装置3
やデータベース4は更新前の状態、一致しない場合は更
新後の状態と判定できる。
As mentioned above, when updating the table 31 on the main storage device 3 or the record 41 on the database 4, the journal acquisition routine 22 updates the update history journals 33' and 41.
' and output it to journal file 5, and
After that, return to normal program processing and save the updated contents stored in the central processing bag @2 to the main memory l! 3 and database 4, and updates the table 31 and records 41. Therefore, update history journals 33', 34'
is acquired in the journal file 5 and then transferred to the main storage device 3.
There is a certain amount of time delay before the table 31 and records 41 of the database 4 are actually rewritten. If a failure occurs during this period, journal file 1. Even if the update history journal is output to the file 5, the contents before the update remain in the main storage device 3 and the database 4. When recovering the system after a failure occurs, whether the contents of the main storage device 3 or database 4 are before or after the update is determined by the third
The determination is made based on the identification information 25 added to the update history journal 24 shown in the figure. That is, since the identification information 25 is data before updating, by comparing this with the corresponding data in the main storage device 3 and the database 4, if they match, the main storage device 3
The database 4 can be determined to be in its pre-update state, and if they do not match, it can be determined that it is in its post-update state.

次に、本発明の更新履歴ジャーナルによる場合の障害発
生後の回復処理を第3図により説明する。
Next, the recovery process after the occurrence of a failure using the update history journal of the present invention will be explained with reference to FIG.

障害発生後の回復処理には1次の2通りの方法がある。There are two methods for recovery processing after a failure occurs.

1、障害発生後のシステム状態から障害発生したメツセ
ージを処理する直前の状態に回復する。
1. Restore the system state after the failure to the state immediately before processing the message in which the failure occurred.

2.障害発生後のシステム状態が壊滅的な状態となった
場合にはバックアップファイルより先ず処理開始時の状
態に回復し、その後ジャーナルより障害メツセージを処
理する前の状態に回復する。
2. If the system status becomes catastrophic after a failure occurs, the backup file first restores the system to the state at the start of processing, and then the journal restores the system to the state before the failure message was processed.

前者1の場合では、障害発生したメツセージを処理した
プログラムが更新したレコードを全て更新前の状態に戻
す必要がある。従来は更新前の情報も更新履歴ジャーナ
ルとして取っていたきめ簡単に戻すことができたが1本
発明では更新前の情報を更新履歴ジャーナルに持たない
ため、第3図のブロック31のようにして回復する。即
ち、まず障害発生後のシステム状態が更新前後のいずれ
の状態にあるかを、第2図で説明した更新履歴ジャーナ
ル24上の識別情報25により判定する。
In the former case 1, it is necessary to return all records updated by the program that processed the failed message to their pre-update state. Conventionally, it was possible to easily restore the information before the update to the update history journal, but in the present invention, since the information before the update is not stored in the update history journal, it is possible to return the information before the update to the update history journal as shown in block 31 of FIG. Recover. That is, first, it is determined whether the system state after the occurrence of a failure is before or after an update, based on the identification information 25 on the update history journal 24 described in FIG.

その結果、システム状態が更新前の状態の場合は、回復
処理は必要ない0次にシステム状態が更新後の状態の場
合は、システムの記憶内容(更新前レコード)とジャー
ナルファイル上の更新履歴ジャーナルと排他的論理和を
とって更新前の状態(更新前レコード)に戻す。
As a result, if the system state is the state before the update, no recovery processing is required. If the system state is the state after the update, the system memory contents (pre-update records) and the update history journal in the journal file Exclusive OR is performed with and returns to the state before update (pre-update record).

後者2のシステム状態が壊滅的な状態となった場合には
、第3図のブロック32のようにして回復する。即ち、
まずバックアップファイルによりシステム状態をシステ
ムの処理開始時の状態に回復する。次に、システムの処
理開始後に更新した記憶エリアに対し、ジャーナルファ
イル上に取得されている更新履歴ジャーナルとの排他的
論理和を順次とることにより、更新後の状態を順次再現
していき、障害発生直前のシステム状態(更新後レコー
ド)に戻す。
If the latter system state becomes catastrophic, recovery is performed as in block 32 of FIG. That is,
First, a backup file is used to restore the system state to the state at the start of system processing. Next, for the storage areas that have been updated after system processing started, by sequentially performing an exclusive OR with the update history journal acquired in the journal file, the state after the update is sequentially reproduced, and the failure is detected. Return to the system state (post-update record) immediately before the occurrence.

〔発明の効果〕〔Effect of the invention〕

本発明によれば、更新履歴として更新前と更新後の両方
の記録内容をとらず1両方を一つにマージして取得する
ので、記録媒体における更新履歴の記録量を従来に比べ
て半減することができる。
According to the present invention, since the update history does not include both pre-update and post-update recorded contents, but merges both into one, the amount of update history recorded on the recording medium is halved compared to the conventional method. be able to.

また、これに伴ない、ジャーナルファイルへの入出力回
数が削減し、システムの処理効率の向上がもたらされる
Additionally, the number of inputs and outputs to the journal file is reduced, resulting in improved system processing efficiency.

【図面の簡単な説明】[Brief explanation of drawings]

第1図は本発明で対象とするシステム例のブロック図、
第2図は従来方式と本発明方式による更新履歴ジャーナ
ルのフォーマット例を示す図、第3図は本発明方式によ
る更新履歴ジャーナルを用いた障害発生後の回復処理を
説明する図である。 1・・・端末装置、  2・・・中央処理装置、3・・
・主記憶装置、 4・・・データベース、5・・・ジャ
ーナルファイル、  6・・・バックアップファイル、
  21・・・更新前レコード。 22・・・更新後レコード、 24・・・更新履歴ジャ
ーナル、 25・・・識別情報。 第  1  図 第  2  図 第  3  図
FIG. 1 is a block diagram of an example of a system targeted by the present invention.
FIG. 2 is a diagram showing format examples of update history journals according to the conventional method and the method of the present invention, and FIG. 3 is a diagram illustrating recovery processing after a failure occurs using the update history journal according to the method of the present invention. 1...Terminal device, 2...Central processing unit, 3...
・Main storage device, 4...Database, 5...Journal file, 6...Backup file,
21... Record before update. 22...Updated record, 24...Update history journal, 25...Identification information. Figure 1 Figure 2 Figure 3

Claims (2)

【特許請求の範囲】[Claims] (1)情報処理システムにおいて処理の履歴を記録する
場合、更新前の内容と更新後の内容を排他的論理和して
一つにマージし、該マージした情報を記録媒体に記録す
ることを特徴とする更新履歴記録方式。
(1) When recording the processing history in an information processing system, the content before the update and the content after the update are exclusively ORed and merged into one, and the merged information is recorded on a recording medium. Update history recording method.
(2)前記マージした情報に、更新前あるいは更新後の
内容の一部を更新識別情報として付加することを特徴と
する特許請求の範囲第1項記載の更新履歴記録方式。
(2) The update history recording method according to claim 1, wherein a part of the content before or after the update is added to the merged information as update identification information.
JP60033449A 1985-02-21 1985-02-21 Updated career recording Pending JPS61193241A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP60033449A JPS61193241A (en) 1985-02-21 1985-02-21 Updated career recording

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP60033449A JPS61193241A (en) 1985-02-21 1985-02-21 Updated career recording

Publications (1)

Publication Number Publication Date
JPS61193241A true JPS61193241A (en) 1986-08-27

Family

ID=12386842

Family Applications (1)

Application Number Title Priority Date Filing Date
JP60033449A Pending JPS61193241A (en) 1985-02-21 1985-02-21 Updated career recording

Country Status (1)

Country Link
JP (1) JPS61193241A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5785141A (en) * 1980-11-17 1982-05-27 Fujitsu Ltd Log data obtaining device
JPS5949062A (en) * 1982-09-13 1984-03-21 Hitachi Ltd Information storing system
JPS5962957A (en) * 1982-08-25 1984-04-10 Fujitsu Ltd Data updating system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5785141A (en) * 1980-11-17 1982-05-27 Fujitsu Ltd Log data obtaining device
JPS5962957A (en) * 1982-08-25 1984-04-10 Fujitsu Ltd Data updating system
JPS5949062A (en) * 1982-09-13 1984-03-21 Hitachi Ltd Information storing system

Similar Documents

Publication Publication Date Title
US7484051B2 (en) Apparatus, system and method for reliably updating a data group in a read-before-write data replication environment using a comparison file
US5421003A (en) Disk storage system with fault tolerant media maintenance
US20050262033A1 (en) Data recording apparatus, data recording method, program for implementing the method, and program recording medium
JPS5913783B2 (en) Duplicate file method
JPS61193241A (en) Updated career recording
JPS62245348A (en) Method and device for updating data base
JPH04184641A (en) Data base restoring system
JPS63187347A (en) Data base file recovering system
JP2946465B2 (en) Failure recovery processing method
JPH04209044A (en) Data base control system
JPS58175065A (en) Processing system of multiplex volume
JPS63262737A (en) Data base updating and recording processing method
JPH04141751A (en) Fault recovery system for mass storage medium
JP2972439B2 (en) Portable terminal backup method
JPH01140353A (en) System for maintaining data in data base
JP2806779B2 (en) Journal block recovery method and journal block recovery method
JP2806342B2 (en) Database failure recovery method and device
JPS62232049A (en) File control table restoring system
JPH0136140B2 (en)
JP2001092690A (en) Time data correcting device and computer system and computer readable recording medium recorded with program
JPS63257962A (en) Data saving/recovering system for magnetic disk at the time of reformatting
JPH02211557A (en) Data base saving system
JPH05324439A (en) Data base control journal output system
JP2000267920A (en) Method for recovering backup and recording medium
JPH04207554A (en) Exchange