JPH0635781A - Recorded data on-line recovery device - Google Patents
Recorded data on-line recovery deviceInfo
- Publication number
- JPH0635781A JPH0635781A JP4190802A JP19080292A JPH0635781A JP H0635781 A JPH0635781 A JP H0635781A JP 4190802 A JP4190802 A JP 4190802A JP 19080292 A JP19080292 A JP 19080292A JP H0635781 A JPH0635781 A JP H0635781A
- Authority
- JP
- Japan
- Prior art keywords
- area
- writing
- disk
- lock
- slave
- 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
Links
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
(57)【要約】
【構成】 複数の計算機よりアクセスされるミラーディ
スクシステムにおいて、ディスク制御装置20のマスタ
ーディスク30側コピー読み取りエリア31をロックエ
リア31として設定し、オンラインよりの書き込みがロ
ックエリアに対応する場合にもエラーとすることなく実
行するとともに、ロックエリア書き込みステータスを報
告し、この報告を受けた計算機側10では次にディスク
制御装置20より対応するロックエリア開放割り込みが
来るまでスレーブディスク40側への書き込みをしな
い。
【効果】 これにより計算機間交信、あるいはロックエ
ラーに伴う計算機よりの書き込み要求の再起動を不要と
し、オンライン回復コピー操作の高速化が図れる。
(57) [Summary] [Configuration] In a mirror disk system accessed by a plurality of computers, a copy read area 31 on the master disk 30 side of the disk controller 20 is set as a lock area 31, and writing from online becomes a lock area. also with run without an error if the corresponding, City broadcast <br/> tell the lock area write status, corresponding to Carlo area is restored more open computer side 10, then the disk control device 20 receives this report Writing to the slave disk 40 side is not performed until an interrupt comes. As a result, it is not necessary to restart the write request from the computer due to the communication between computers or the lock error, and the online recovery copy operation can be speeded up.
Description
【0001】[0001]
【産業上の利用分野】この発明はたとえば、データベー
スシステム、オンライントランザクションシステム等に
おけるオンライン下でのディスクデータ回復の高速化に
関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to online disk data recovery in a database system, an online transaction system, etc.
【0002】[0002]
【従来の技術】近年データベースシステム、オンライン
トランザクション処理システム等において特に強くデー
タの信頼性が求められ、ミラーディスクシステムが広く
採用されて来ているが、その記録媒体障害時等における
回復コピー(現用マスターディスクから回復対象スレー
ブディスクへのコピー)処理時間の増大が問題となって
きている。また計算機システムとしては、2重系、待機
系、負荷分散系等の疎結合システムも多く、これらのシ
ステムでは複数の計算機からのオンラインアクセス下に
おいて、ディスクの回復コピー操作を要求されてきてい
る。ここで記憶内容の回復コピー操作と、オンラインか
らの書き込み(マスター及びスレーブディスクへ)との
順序を規制しなければオンラインからの書き込みデータ
が失われてしまう。これを防ぐために従来は計算機間交
信により回復処理を行う計算機から他の計算機に対して
スレーブディスク側指定エリア(シリンダ、ファイル等
の単位で)への書き込み禁止を指令し、指定エリアの書
き込み禁止が成立したという応答を待ってコピー操作を
行い、コピー後、その指定エリアの書き込み禁止を解き
次のエリアへ移るといったエリアロックを相互に連絡し
あうことが必要であった。あるいはこの計算機間交信を
なくすためディスク制御装置のスレーブディスク側にエ
リアロック機能を持たせ、ロックされたエリアへのオン
ライン書き込みはロックエラーとして返し、ロックエリ
アの開放割り込みを待って再度計算機から書き込み要求
を出すというロックエラー報告方式も考えられていた。2. Description of the Related Art In recent years, data reliability has been particularly strongly demanded in database systems, online transaction processing systems, etc., and mirror disk systems have been widely adopted. Copying from a disk to a recovery target slave disk) The increase in processing time has become a problem. In addition, many computer systems include loosely coupled systems such as a dual system, a standby system, and a load balancing system. In these systems, a recovery copy operation of a disk is requested under online access from a plurality of computers. If the order of the recovery copy operation of the stored contents and the online writing (to the master and slave disks) is not regulated, the online write data will be lost. In order to prevent this, conventionally, a computer that performs recovery processing by communication between computers issues a write-protection command to the slave disk side specified area (in units of cylinders, files, etc.) to another computer, and It was necessary to wait for a response that it was established, perform a copy operation, and after copying, contact each other for area lock such as removing write protection of the specified area and moving to the next area. Alternatively, in order to eliminate this inter-computer communication, the slave disk side of the disk controller has an area lock function, online write to the locked area is returned as a lock error, and a write request is sent again from the computer after waiting for the lock area release interrupt. A lock error reporting method of issuing "." Was also considered.
【0003】[0003]
【発明が解決しようとする課題】エリアロックの交信は
複数の計算機に対して必要な場合もあり、指定エリアの
書き込み禁止の指令が出されたとき各計算機が指定エリ
アへの書き込みをすでに要求していた場合にはそれらの
完了まで書き込み禁止が成立したという応答を返せな
い。また、このエリアロックのための交信回数を減らす
ためエリアのサイズを一回当たりのコピーサイズより大
きく取る。これらの理由で、計算機の交信オーバーヘッ
ド、コピー経過時間が増大し、単独の計算機システムで
のコピー時間に比べてかなり長い時間が必要となってい
た。あるいは、ディスク制御装置のスレーブディスク側
にエリアロックの機能を持たせるロックエラー報告方式
においては、かなり改善されたとはいえロックエラー時
には処理ルーチンの起動回数、割り込み回数とも通常の
書き込みよりは多くなり、計算機負荷、コピー経過時間
ともに最適とは言えなかった。Area lock communication may be required for multiple computers, and when a write-protection command for a designated area is issued, each computer has already requested writing to the designated area. If so, the response that the write-protection is established cannot be returned until the completion. Also, in order to reduce the number of communications for this area lock, the size of the area is set larger than the copy size per one time. For these reasons, the communication overhead of the computer and the copy elapsed time increase, which requires a considerably longer time than the copy time in a single computer system. Alternatively, in the lock error reporting method in which the slave disk side of the disk control device has an area lock function, even though it is considerably improved, the number of times the processing routine is started and the number of interrupts are more than normal writing when a lock error occurs, Neither computer load nor elapsed copy time was optimal.
【0004】この発明は以上のような問題点を解決する
ためになされたもので、データベースのデータに障害が
発生したときにオンライン動作時においてデータを高速
に回復できる記録データオンライン回復装置を提供する
ことを目的とする。The present invention has been made to solve the above problems, and provides a recorded data online recovery apparatus capable of recovering data at high speed during online operation when a failure occurs in the data in the database. The purpose is to
【0005】[0005]
【課題を解決するための手段】この発明に係る記録デー
タオンライン回復装置は以下の要求を有するものであ
る。 (a)データを記録するマスター記録装置、 (b)上記マスター記録装置に記録されるデータと同一
のデータを記録するスレーブ記録装置、 (c)上記マスター記録装置及びスレーブ記録装置に同
一のデータを書き込む書き込み手段、 (d)以下の要素を有し、上記書き込み手段の動作中
に、スレーブ記録装置の障害を回復する障害回復手段、
(d1)上記マスター記録装置からスレーブ記録装置へ
データをコピーするためのマスター記録装置のコピーエ
リアを登録するエリア登録手段、(d2)上記エリア登
録手段により登録されたマスター記録装置のコピーエリ
アのデータをスレーブ記録装置へコピーするコピー手
段、(d3)上記エリア登録手段により登録されたマス
ター記録装置のコピーエリアに対して上記書き込み手段
による書き込みが発生した場合、マスター記録装置への
書き込みは許可するとともに、スレーブ記録装置への書
き込みは保留し、上記コピー手段によるコピー終了後に
保留した書き込みをスレーブ記録装置に対して実行させ
る書き込み制御手段。The recorded data online recovery apparatus according to the present invention has the following requirements. (A) a master recording device for recording data, (b) a slave recording device for recording the same data as the data recorded in the master recording device, (c) the same data for the master recording device and the slave recording device Writing means for writing, (d) failure recovery means for recovering a failure of the slave recording device during the operation of the writing means, including the following elements:
(D1) area registration means for registering a copy area of the master recording device for copying data from the master recording device to the slave recording device, (d2) data of the copy area of the master recording device registered by the area registration means Means for copying the data to the slave recording device, and (d3) when writing by the writing device occurs in the copy area of the master recording device registered by the area registration device, the writing to the master recording device is permitted and Write control means for suspending writing to the slave recording apparatus and causing the slave recording apparatus to execute the suspended writing after the copying by the copying means is completed.
【0006】[0006]
【作用】この発明における記録データオンライン回復装
置では、マスター記録装置とスレーブ記録装置のうち、
マスター記録装置側からスレーブ記録装置へ回復するデ
ータをコピーするためのマスター記録装置のコピーエリ
アを登録するエリア登録手段を有しており、書き込み制
御手段はマスター記録装置への書き込みに対しては、こ
のエリア登録手段により登録されたコピーエリアに関わ
らず全ての書き込みを許可するので、マスター記録装置
への書き込み要求をつぎつぎに出すことができる。一
方、書き込み制御手段はスレーブ記録装置へ対して書き
込み手段がエリア登録手段により登録されたコピーエリ
アへ書き込みを実行する場合には、この書き込みを保留
しコピー手段によるコピー終了後にそのコピーした書き
込みを実行させるようにするため、スレーブ記録装置へ
の書き込み手段によるデータの書き込みがコピー手段に
よるコピーよりも先に行われて最新のデータが失われて
しまうという弊害が無くなる。In the recorded data online recovery device according to the present invention, of the master recording device and the slave recording device,
The master recording device has area registration means for registering a copy area of the master recording device for copying data to be recovered to the slave recording device, and the writing control means for writing to the master recording device, Since all writing is permitted regardless of the copy area registered by the area registration means, it is possible to issue write requests to the master recording device one after another. On the other hand, when the writing means writes to the slave recording device in the copy area registered by the area registration means, the writing control means suspends the writing and executes the copied writing after the copying by the copying means is completed. Therefore, the problem that the latest data is lost by writing the data to the slave recording device by the writing means before the copying by the copying means is eliminated.
【0007】[0007]
【実施例】図1は、この発明に係る記録データオンライ
ン回復装置の一実施例を示す図である。図において10
は計算機、20は計算機10に接続されたディスク制御
装置、30はマスター記録装置、40はマスター記録装
置30に記録されるデータと同一のデータを記録するス
レーブ記録装置である。11はマスター記録装置30に
対してデータを記録するとともに同一のデータをスレー
ブ記録装置40に対して記録する書き込み手段である。
50はスレーブ記録装置のデータに障害が有り、マスタ
ー記録装置からスレーブ記録装置に対してデータをコピ
ーすることによりスレーブ記録装置のデータを回復する
ための障害回復手段である。21はマスター記録装置3
0の、ある特定のエリアをコピーエリア31として登録
するエリア登録手段である。12はエリア登録手段21
により登録されたコピーエリア31にあるデータを読み
込み、そのデータをスレーブ記録装置40の対応するエ
リアに書き込むコピー手段である。22はエリア登録手
段により登録されたコピーエリア31に対して書き込み
手段11がデータを書こうとした場合、マスター記録装
置に対してはその書き込みを許可し、スレーブ記録装置
への書き込みに対してはこれを保留し、コピー手段によ
るコピーが終了した後に書き込み手段によるスレーブ記
録装置へのデータの書き込みを許可する書き込み制御手
段である。1 is a diagram showing an embodiment of a recorded data online recovery device according to the present invention. 10 in the figure
Is a computer, 20 is a disk controller connected to the computer 10, 30 is a master recording device, and 40 is a slave recording device for recording the same data as the data recorded in the master recording device 30. Reference numeral 11 is a writing unit that records data in the master recording device 30 and also records the same data in the slave recording device 40.
Reference numeral 50 denotes a failure recovery means for recovering the data of the slave recording device by copying the data from the master recording device to the slave recording device because the data of the slave recording device has a failure. 21 is a master recording device 3
Area registration means for registering a specific area of 0 as the copy area 31. 12 is area registration means 21
It is a copy means that reads data in the copy area 31 registered by and writes the data in the corresponding area of the slave recording device 40. When the writing unit 11 tries to write data to the copy area 31 registered by the area registration unit, the reference numeral 22 permits the master recording device to write the data and the writing to the slave recording device. It is a write control unit that holds this and permits the writing unit to write data to the slave recording device after the copying by the copying unit is completed.
【0008】以下、マスター記録装置をマスターディス
クと呼び、スレーブ記録装置をスレーブディスクと呼
び、コピーエリアをロックエリアと呼び、動作について
説明する。ディスク制御装置のマスターディスク側にエ
リアロック機能を持たせ、コピーのための読み取りに際
しそのエリアのロックを計算機よりディスク制御装置に
対して指令する。エリア登録手段はこのエリアを登録し
ておく。書き込み制御手段は、書き込み手段がこのロッ
クされたエリア以外への書き込みをする場合はマスター
ディスクとスレーブディスクの両方とも通常の書き込み
を許可する。また、スレーブディスク側への書き込みが
完了せずエリアロック開放指令が来ていないマスターデ
ィスク側ロックエリアへのオンライン書き込みに際して
も、ロックされていないエリアと同様に直接書き込みを
実行するとともに、ロックエリアとのオーバーラップを
検出し、オーバーラップの場合、その書き込みエリアを
ユニークなシーケンス番号と共にディスク制御装置に登
録する。そしてロックエリア書き込みステータスをその
シーケンス番号とともにマスターディスクへの書き込み
終了報告時に計算機に伝える。The operation will be described below with the master recording apparatus referred to as a master disk, the slave recording apparatus referred to as a slave disk, and the copy area referred to as a lock area. The master disk side of the disk controller is provided with an area lock function, and when reading for copying, the computer commands the disk controller to lock the area. The area registration means registers this area. The writing control means permits normal writing to both the master disk and the slave disk when the writing means writes to areas other than this locked area. Also, when writing online to the master disk side locked area where writing to the slave disk side has not been completed and the area lock release command has not come, direct writing is performed as in the unlocked area, and Is detected, and in the case of overlap, the write area is registered in the disk controller together with a unique sequence number. Then, the lock area write status is transmitted to the computer together with the sequence number when the write completion report to the master disk is reported.
【0009】ここで、ロックエリア書き込みステータス
とは計算機からのデータの書き込みがロックエリアに該
当したということを示すためのフラグであり、例えばこ
のロックエリア書き込みステータスを1ビットで示し、
0の時には書き込むデータはロックエリアに該当しない
ことを示し、1の場合にはロックエリアに該当したこと
を示すものとする。またシーケンス番号はロックエリア
書き込みステータスが1になったものに対して順番にふ
られる番号である。書き込み制御手段22は前述したロ
ックエリア書き込みステータスを1にセットするととも
にシーケンスナンバーの割り振りを行い、これをマスタ
ーディスクへのデータの書き込み終了報告と共に計算機
に伝える。Here, the lock area write status is a flag for indicating that writing of data from the computer corresponds to the lock area. For example, this lock area write status is indicated by 1 bit,
When it is 0, it indicates that the data to be written does not correspond to the lock area, and when it is 1, it indicates that it corresponds to the lock area. The sequence number is a number assigned in sequence to the lock area write status of 1. The write control means 22 sets the above-mentioned lock area write status to 1 and allocates a sequence number, and reports this to the computer together with a data write completion report to the master disk.
【0010】計算機側では、書き込み手段11が、通常
はマスターディスクへの書き込み終了に引き続きスレー
ブディスクへの書き込み要求を行うが、ロックエリア書
き込みステータスがマスターディスクから報告された場
合には、伝えられたシーケンス番号を記憶し、スレーブ
ディスクへの書き込みを保留する。On the computer side, the writing means 11 normally issues a write request to the slave disk subsequent to the completion of writing to the master disk, but when the lock area write status is reported from the master disk, it is transmitted. Stores the sequence number and suspends writing to the slave disk.
【0011】次にコピー手段により、ロックエリアのデ
ータがマスターディスクからスレーブディスクにコピー
されると、書き込み制御手段がその終了を検出し、コピ
ー中にスレーブディスクへの書き込みが保留されている
書き込み要求に対して書き込み制御手段が割り振ったシ
ーケンス番号とともにロックエリアを開放することを知
らせるロックエリア開放割り込みを計算機の書き込み手
段に対して出力する。書き込み手段は、記憶したシーケ
ンス番号と同じシーケンス番号を持ったロックエリア開
放割り込みがディスク制御装置から伝えられると、その
シーケンス番号に対応した書き込み要求をスレーブディ
スクに対して行う。Next, when the data in the lock area is copied from the master disk to the slave disk by the copy means, the write control means detects the end of the data and the write request in which writing to the slave disk is suspended during copying. To the write means of the computer, which notifies the write means of the computer of the release of the lock area together with the sequence number assigned by the write control means. When the lock area release interrupt having the same sequence number as the stored sequence number is transmitted from the disk control device, the writing means makes a write request corresponding to the sequence number to the slave disk.
【0012】このように、次に同じシーケンス番号を持
ったロックエリア開放割り込みがディスク制御装置から
伝えられるまで、スレーブディスクへの書き込み起動を
行わずに保留するように制御することにより、スレーブ
ディスク上の新しいオンライン書き込みデータが古いコ
ピーデータにより失われることを防ぐことができる。こ
れにより各計算機はロックエリアの開放を待つことなく
マスターディスクへの書き込み要求をつぎつぎに出すこ
とができ、それらの内、複数のものがロックエリアへの
書き込みに対応するものであっても問題なく対処でき、
従来例で述べたロックエラー報告方式のように処理ルー
チンの再度起動を必要とすることもなくなる。また書き
込みエリア登録時にユニークなシーケンス番号を与える
方式を取ったことにより、シーケンス番号順にスレーブ
ディスクに書き込みをしていけるので先行したロックエ
リアはまだ開放されないのに後のロックエリアが先に開
放されるといった場合にも、実際に書き込みが発生した
順にスレーブディスクに書き込みが行なわれることにな
り、順序逆転という問題も発生しない。As described above, by controlling so as to hold the lock area release interrupt having the same sequence number next from the disk control device without performing writing start to the slave disk, the slave disk on the slave disk is controlled. It is possible to prevent the new online write data of the above from being lost due to the old copy data. This allows each computer to issue write requests to the master disk one after another without waiting for the lock area to be released, and even if a plurality of them correspond to the write to the lock area, there is no problem. Can be dealt with,
There is no need to restart the processing routine as in the lock error reporting method described in the conventional example. In addition, by adopting the method of giving a unique sequence number when registering the writing area, it is possible to write to the slave disk in sequence number order, so the preceding lock area is not released yet but the latter lock area is released first. In this case, the slave disks are written in the order in which the writing actually occurs, and the problem of order inversion does not occur.
【0013】以上のような方式は、ディスク制御装置側
では通常通りにディスクへの起動を行いながら、コマン
ドが書き込みと判明しディスクへの書き込みを開始した
後、ロックエリア指定の有無、ロックエリア内書き込み
の判定、書き込みエリア登録を行う程度のロジック、お
よび終了報告時の簡単な追加処理、ロックエリア登録、
変更指令、開放指令及びそれらに応じたロックエリア開
放処理等ですみ、効率的な方式といえる。According to the above-mentioned method, the disk control device starts the disk as usual, and after the command is found to be writing and the writing to the disk is started, whether the lock area is designated or not Logic for writing judgment, writing area registration, and simple additional processing at the end report, lock area registration,
It can be said that this is an efficient method because it only requires a change command, a release command, and a lock area release process corresponding to them.
【0014】なお書き込み制御手段が書き込みを保留し
た書き込みエリアはディスク制御装置にシーケンス番号
とともに登録されるが、この書き込みエリアは各計算機
に対応して各々複数個登録できる必要がある。The write area in which writing is suspended by the write control means is registered in the disk controller together with the sequence number, but it is necessary to register a plurality of write areas for each computer.
【0015】なお、このように、ディスク制御装置側に
書き込みエリアを登録する方式を取ったことにより、前
回と今回の両方のロックエリアにまたがって書き込み要
求を行っていた場合、前回と今回のロックエリアのロッ
クが開放されてからディスク制御装置がそのシーケンス
番号を持ったロックエリア開放割り込みを出力するの
で、従来のように計算機側でロックエリア開放割り込み
を受けて再度起動を行ったが、今回もロックエラーとし
てはねられるといった事もなくすことができる。By adopting the method of registering the write area on the side of the disk controller as described above, when the write request is made over both the lock areas of the previous time and this time, the lock of the previous time and the current time is performed. After the area lock is released, the disk controller outputs a lock area release interrupt with that sequence number, so the computer side received a lock area release interrupt as in the past and restarted. It can be eliminated without being hit as a lock error.
【0016】以上のように、この実施例は、ミラーディ
スクデータオンライン回復装置において、複数の計算機
よりアクセスされるミラーディスクシステムのオンライ
ン障害回復時のマスターディスクよりスレーブディスク
へのデータコピー操作にあたり、ディスク制御装置のマ
スターディスク側に計算機から指令されたエリア(コピ
ー対象エリア)をロックエリアとして登録する手段を持
ち、マスターディスクへの計算機よりの書き込み指令は
通常通り実行するとともに、書き込みエリアとロックエ
リアとのオーバーラップを検出し、オーバーラップの場
合その書き込みエリアをユニークなシーケンス番号とと
もに登録し、書き込み終了時にロックエリア書き込みス
テータス及びシーケンス番号を報告する手段を有し、コ
ピー対象ロックエリアの変更指令に対し、登録されてい
た書き込みエリアで新しいロックエリアに含まれなくな
ったもの、あるいはロックエリア開放指令に対し登録さ
れていた書き込みエリア全てについて、ロックエリア開
放割り込みをシーケンス番号とともに報告するディスク
制御装置を備えていることを特徴とする。As described above, according to the present embodiment, in the mirror disk data online recovery device, the data is copied from the master disk to the slave disk during the online failure recovery of the mirror disk system accessed by a plurality of computers. The master disk side of the control unit has a means to register the area (copy target area) instructed by the computer as a lock area, and the writing command from the computer to the master disk is executed as usual, and the writing area and the lock area are It has a means to detect the overlap of the lock area, register the write area with a unique sequence number in the case of overlap, and report the lock area write status and sequence number at the end of writing. In response to the change command of (a), the lock area release interrupt is reported together with the sequence number for the registered write area that is no longer included in the new lock area or for all the write areas registered for the lock area release command. A disk control device is provided.
【0017】なお、ディスク制御装置にコピー対象ロッ
クエリアの指令コマンドとして、リード&ロック機能
(通常のリード機能の他に、前回のロックエリアを開放
する機能、及びリードア対象エリアをロックエリアとし
て登録する機能)を持つようにしてもよい。A read and lock function (in addition to the normal read function, a function of releasing the previous lock area and a read target area are registered as lock areas in the disk control device as command commands for the copy target lock area). Function).
【0018】このリード&ロック機能によれば、通常行
われているようなエリアロック要求、開放要求を(最後
の開放要求を除いて)別途必要とせず、1つの指令コマ
ンドで、通常のリード機能の他に、前回のロックエリア
を開放する機能、及びリード対象エリアをロックエリア
として登録する機能をあわせもつためディスク制御装置
への入出力回数を減らすことが可能となる。またロック
する範囲を必要最小限に限ることにより、ロックされる
確率も少なくなりオーバーヘッド少なく効率的な方式と
いえる。According to the read & lock function, the area lock request and the release request which are normally performed are not separately required (except the last release request), and the normal read function can be performed by one command command. In addition to this, since it has the function of releasing the previous lock area and the function of registering the read target area as the lock area, it is possible to reduce the number of inputs and outputs to the disk control device. Also, by limiting the lock range to the necessary minimum, the probability of lock is reduced, and it can be said that this is an efficient method with less overhead.
【0019】次に、この実施例の具体的動作例について
説明する。図2は2重系計算機システムへの本発明の適
用例を示し、ディスク制御装置、ミラーディスク(マス
ターディスクA,C,EにスレーブディスクB,D,F
が各々対応する)を示す。図3はミラーディスクの回復
処理時の書き込みエリアロックの必要性を示す図であ
り、a,bの線上にマスター、スレーブディスクへの入
出力を示す。ここで回復処理はa0r−b0w,a1r
−b1w,・・・の順序でマスターディスクからの読み
取り、スレーブディスクへの書き込みを繰り返してい
る。xa0w−xb0w,ya0w−yb0w等はオン
ラインプログラムからのミラーモード書き込みを示す。
エリアa0への書き込みがすでに回復コピー用読み取り
a0rより前に終了しているxa0wに対応する書き込
みxb0wはコピープログラムからの書き込みb0wと
は無関係に実行してよいが、a0rより後の書き込みy
a0wに対応するyb0wがコピープログラムからの書
き込みb0wより先行すると、そのデータはBディスク
には結局書き込まれなかったことと同じで失われてしま
う。したがって本実施例ではAディスクへのオンライン
書き込みの終了処理をロックエリア書き込みステータス
が報告された場合には、Bディスクへのコピー書き込み
が終了しエリアロック開放割り込みが報告されるまで
(エリアロック要求、開放指令を単独で実行する場
合)、あるいはAディスクからの次エリアのコピー読み
取りa1rの実行開始によりエリアロック開放割り込み
が報告されるまで(リード&ロック機能を使用の場合)
Aディスクの終了処理、Bディスクへのミラーモード書
き込みを実質的に保留することによりデータの消失を防
いだ。ここでya0wの終了割り込み処理はBディスク
へのコピー書き込み終了時点まで、区間Xの間遅らせば
良いが、リード&ロック方式の場合ディスク装置との問
答を少なくする意味で次のコピー読み取り開始まで(あ
るいはエリアロック開放まで)の間:区間Sの間遅らせ
ることとした。Next, a specific operation example of this embodiment will be described. FIG. 2 shows an example of application of the present invention to a dual computer system, in which a disk controller, mirror disks (master disks A, C, E are slave disks B, D, F).
Correspond to each other). FIG. 3 is a diagram showing the necessity of the write area lock at the time of recovery processing of the mirror disk, and the lines a and b show the input / output to / from the master and slave disks. Here, the recovery process is a0r-b0w, a1r.
Reading from the master disk and writing to the slave disk are repeated in the order of -b1w, .... xa0w-xb0w, ya0w-yb0w, etc. indicate the mirror mode writing from the online program.
The write xb0w corresponding to xa0w whose writing to the area a0 has already finished before the recovery copy read a0r may be executed independently of the write b0w from the copy program, but the write y after a0r
If yb0w corresponding to a0w precedes writing b0w from the copy program, the data will be lost as if it were not written to the B disc. Therefore, in this embodiment, when the lock area write status is reported for the completion of the online writing to the A disk, the copy writing to the B disk is completed and the area lock release interrupt is reported (area lock request, (When the release command is executed independently), or until the area lock release interrupt is reported by the start of execution of the next area copy reading a1r from the A disk (when the read & lock function is used)
Data loss was prevented by substantially suspending the end processing of the A disk and the mirror mode writing to the B disk. Here, the end interrupt processing of ya0w may be delayed for the period X until the end of the copy writing to the B disk, but in the case of the read & lock method, it means until the next copy reading is started in order to reduce the number of questions and answers with the disk device. Or until the area lock is released): Delayed during section S.
【0020】実施例2.実施例1では複数の計算機を含
む場合について述べたが、単独の計算機の場合にも有効
である。また実施例1ではディスク制御装置をマスター
側スレーブ側と2個持った場合を考えたが、ディスク媒
体/装置の信頼度を上げることを中心に考え制御装置1
個でミラーディスクシステムを構成する場合等も考えら
れる。この場合にはロックエリアへの書き込みが終了し
ても計算機への報告をすぐには行わず、ロックエリアの
開放を待って終了割り込みを出力し、回復コピー処理プ
ログラム以外は全くエリアロックを意識しないですむ方
式とすることも考えられる。但しこの場合各々の計算機
毎に複数個の起動要求を受け付けディスクの有効利用を
計るようにする必要がある。Example 2. Although the first embodiment has described the case of including a plurality of computers, it is also effective in the case of a single computer. Further, in the first embodiment, the case where the two disk control devices are provided on the master side and the slave side is considered, but the control device 1 is focused on improving the reliability of the disk medium / device.
There may be a case where a mirror disk system is composed of individual pieces. In this case, even if the writing to the lock area is completed, it is not reported to the computer immediately, the end interrupt is output after waiting for the lock area to be released, and the area other than the recovery copy processing program is not aware of the area lock at all. It is also possible to adopt a system that allows it. However, in this case, it is necessary to accept a plurality of activation requests for each computer and measure the effective use of the disk.
【0021】実施例3.上記実施例1においては、デー
タを記録する媒体がディスクである場合を示したが、デ
ィスクである場合に限らずその他の磁気記録装置あるい
は光記録装置等のデータを記録する記録装置であれば構
わない。Example 3. In the first embodiment, the case where the medium for recording the data is the disk is shown, but the recording medium is not limited to the disk, and any other magnetic recording device or an optical recording device may be used as the recording device for recording the data. Absent.
【0022】実施例4.上記実施例1ではマスターディ
スクからスレーブディスクにデータを回復する場合を示
したが、このマスターというのはデータを保有している
方を指し、スレーブとは障害が起こっている方を指すも
のとし、計算機システムの通常の使用時において、主従
の関係でデータを記録する場合のマスターあるいはスレ
ーブという関係に限定されるものではない。すなわち、
回復させるべきデータを保持しているものがマスターで
あり、障害が起きている方がスレーブである。Example 4. In the first embodiment described above, the case of recovering data from the master disk to the slave disk is shown. However, the master refers to the person who holds the data, and the slave refers to the person who has a failure. It is not limited to a master or slave relationship when data is recorded in a master-slave relationship during normal use of the computer system. That is,
The one holding the data to be recovered is the master, and the one with the failure is the slave.
【0023】[0023]
【発明の効果】以上のように、この発明によれば、計算
機間交信及びロックエラーにともなう計算機からの書き
込み要求の再起動を不要とし、オンライン回復コピー操
作の高速化が計れる。As described above, according to the present invention, it is not necessary to restart the write request from the computer due to the communication between computers and the lock error, and the online recovery copy operation can be speeded up.
【図1】この発明に係る記録データオンライン回復装置
の構成を示す図である。FIG. 1 is a diagram showing a configuration of a recorded data online recovery device according to the present invention.
【図2】この発明に係る記録データオンライン回復装置
の一具体例を示す図である。FIG. 2 is a diagram showing a specific example of a recorded data online recovery device according to the present invention.
【図3】この発明に係る記録データオンライン回復装置
の動作を説明するための図である。FIG. 3 is a diagram for explaining the operation of the recorded data online recovery device according to the present invention.
10 計算機 11 書き込み手段 12 コピー手段 20 ディスク制御装置 21 エリア登録手段 22 書き込み制御手段 30 マスター記録装置(マスターディスク) 40 スレーブ記録装置(スレーブディスク) 50 障害回復手段 10 computer 11 writing means 12 copying means 20 disk control device 21 area registration means 22 writing control means 30 master recording device (master disk) 40 slave recording device (slave disk) 50 failure recovery means
─────────────────────────────────────────────────────
─────────────────────────────────────────────────── ───
【手続補正書】[Procedure amendment]
【提出日】平成5年7月12日[Submission date] July 12, 1993
【手続補正1】[Procedure Amendment 1]
【補正対象書類名】明細書[Document name to be amended] Statement
【補正対象項目名】全文[Correction target item name] Full text
【補正方法】変更[Correction method] Change
【補正内容】[Correction content]
【書類名】 明細書[Document name] Statement
【発明の名称】 記録データオンライン回復装置Recorded data online recovery device
【特許請求の範囲】[Claims]
【発明の詳細な説明】Detailed Description of the Invention
【0001】[0001]
【産業上の利用分野】この発明はたとえば、データベー
スシステム、オンライントランザクションシステム等に
おけるオンライン下でのディスクデータ回復の高速化に
関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to online disk data recovery in a database system, an online transaction system, etc.
【0002】[0002]
【従来の技術】近年データベースシステム、オンライン
トランザクション処理システム等において特に強くデー
タの信頼性が求められ、ミラーディスクシステムが広く
採用されて来ているが、その記録媒体障害時等における
回復コピー(現用マスターディスクから回復対象スレー
ブディスクへのコピー)処理時間の増大が問題となって
きている。また計算機システムとしては、2重系、待機
系、負荷分散系等の疎結合システムも多く、これらのシ
ステムでは複数の計算機からのオンラインアクセス下に
おいて、ディスクの回復コピー操作を要求されてきてい
る。ここで記憶内容の回復コピー操作と、オンラインか
らの書き込み(マスター及びスレーブディスクへ)との
順序を規制しなければオンラインからの書き込みデータ
が失われてしまう。これを防ぐために従来は計算機間交
信により回復処理を行う計算機から他の計算機に対して
スレーブディスク側指定エリア(シリンダ、ファイル等
の単位で)への書き込み禁止を指令し、指定エリアの書
き込み禁止が成立したという応答を待ってコピー操作を
行い、コピー後、その指定エリアの書き込み禁止を解き
次のエリアへ移るといったエリアロックを相互に連絡し
あうことが必要であった。あるいはこの計算機間交信を
なくすためディスク制御装置のスレーブディスク側にエ
リアロック機能を持たせ、ロックされたエリアへのオン
ライン書き込みはロックエラーとして返し、ロックエリ
アの開放割り込みを待って再度計算機から書き込み要求
を出すというロックエラー報告方式も考えられていた。2. Description of the Related Art In recent years, data reliability has been particularly strongly demanded in database systems, online transaction processing systems, etc., and mirror disk systems have been widely adopted. Copying from a disk to a recovery target slave disk) The increase in processing time has become a problem. In addition, many computer systems include loosely coupled systems such as a dual system, a standby system, and a load balancing system. In these systems, a recovery copy operation of a disk is requested under online access from a plurality of computers. If the order of the recovery copy operation of the stored contents and the online writing (to the master and slave disks) is not regulated, the online write data will be lost. In order to prevent this, conventionally, a computer that performs recovery processing by communication between computers issues a write-protection command to the slave disk side specified area (in units of cylinders, files, etc.) to another computer, and It was necessary to wait for a response that it was established, perform a copy operation, and after copying, contact each other for area lock such as removing write protection of the specified area and moving to the next area. Alternatively, in order to eliminate this inter-computer communication, the slave disk side of the disk controller has an area lock function, online write to the locked area is returned as a lock error, and a write request is sent again from the computer after waiting for the lock area release interrupt. A lock error reporting method of issuing "." Was also considered.
【0003】[0003]
【発明が解決しようとする課題】エリアロックの交信は
複数の計算機に対して必要な場合もあり、指定エリアの
書き込み禁止の指令が出されたとき各計算機が指定エリ
アへの書き込みをすでに要求していた場合にはそれらの
完了まで書き込み禁止が成立したという応答を返せな
い。また、このエリアロックのための交信回数を減らす
ためエリアのサイズを一回当たりのコピーサイズより大
きく取る。これらの理由で、計算機の交信オーバーヘッ
ド、コピー経過時間が増大し、単独の計算機システムで
のコピー時間に比べてかなり長い時間が必要となってい
た。あるいは、ディスク制御装置のスレーブディスク側
にエリアロックの機能を持たせるロックエラー報告方式
においては、かなり改善されたとはいえロックエラー時
には処理ルーチンの起動回数、割り込み回数とも通常の
書き込みよりは多くなり、計算機負荷、コピー経過時間
ともに最適とは言えなかった。Area lock communication may be required for multiple computers, and when a write-protection command for a designated area is issued, each computer has already requested writing to the designated area. If so, the response that the write-protection is established cannot be returned until the completion. Also, in order to reduce the number of communications for this area lock, the size of the area is set larger than the copy size per one time. For these reasons, the communication overhead of the computer and the copy elapsed time increase, which requires a considerably longer time than the copy time in a single computer system. Alternatively, in the lock error reporting method in which the slave disk side of the disk control device has an area lock function, even though it is considerably improved, the number of times the processing routine is started and the number of interrupts are more than normal writing when a lock error occurs, Neither computer load nor elapsed copy time was optimal.
【0004】この発明は以上のような問題点を解決する
ためになされたもので、データベースのデータに障害が
発生したときにオンライン動作時においてデータを高速
に回復できる記録データオンライン回復装置を提供する
ことを目的とする。The present invention has been made to solve the above problems, and provides a recorded data online recovery apparatus capable of recovering data at high speed during online operation when a failure occurs in the data in the database. The purpose is to
【0005】[0005]
【課題を解決するための手段】この発明に係る記録デー
タオンライン回復装置は以下の要求を有するものであ
る。 (a)データを記録するマスター記録装置、 (b)上記マスター記録装置に記録されるデータと同一
のデータを記録するスレーブ記録装置、 (c)上記マスター記録装置及びスレーブ記録装置に同
一のデータを書き込むとともに、条件によりスレーブ記
憶装置への書き込みを一時保留できる書き込み手段、 (d)以下の要素を有し、上記書き込み手段の動作中
に、スレーブ記録装置の障害を回復する障害回復手段、
(d1)上記マスター記録装置からスレーブ記録装置へ
データをコピーするためのマスター記録装置のコピーエ
リアを登録するエリア登録手段、(d2)上記エリア登
録手段により登録されたマスター記録装置のコピーエリ
アのデータをスレーブ記録装置へコピーするコピー手
段、(d3)上記エリア登録手段により登録されたマス
ター記録装置のコピーエリアに対して上記書き込み手段
による書き込みが発生した場合、マスター記録装置への
書き込みは許可するとともに、上記書き込み手段により
スレーブ記録装置への書き込みを保留させ、上記コピー
手段によるコピー終了後に保留した書き込みをスレーブ
記録装置に対して実行させる書き込み制御手段。The recorded data online recovery apparatus according to the present invention has the following requirements. (A) a master recording device for recording data, (b) a slave recording device for recording the same data as the data recorded in the master recording device, (c) the same data for the master recording device and the slave recording device Writing means capable of temporarily holding writing to the slave storage device depending on conditions while writing, (d) failure recovery means for recovering a failure of the slave recording device while the writing means is in operation, having the following elements:
(D1) area registration means for registering a copy area of the master recording device for copying data from the master recording device to the slave recording device, (d2) data of the copy area of the master recording device registered by the area registration means Means for copying the data to the slave recording device, and (d3) when writing by the writing device occurs in the copy area of the master recording device registered by the area registration device, the writing to the master recording device is permitted and Writing control means for holding the writing to the slave recording apparatus by the writing means, and executing the held writing to the slave recording apparatus after the copying by the copying means is completed.
【0006】[0006]
【作用】この発明における記録データオンライン回復装
置では、マスター記録装置とスレーブ記録装置のうち、
マスター記録装置側からスレーブ記録装置へ回復するデ
ータをコピーするためのマスター記録装置のコピーエリ
アを登録するエリア登録手段を有しており、書き込み制
御手段はマスター記録装置への書き込みに対しては、こ
のエリア登録手段により登録されたコピーエリアに関わ
らず全ての書き込みを許可するので、マスター記録装置
への書き込み要求をつぎつぎに出すことができる。一
方、書き込み制御手段はスレーブ記録装置に対して書き
込み手段がエリア登録手段により登録されたコピーエリ
アへ書き込みを実行する場合には、この書き込みを保留
しコピー手段によるコピー終了後にその保留した書き込
みを実行させるようにするため、スレーブ記録装置への
書き込み手段によるデータの書き込みがコピー手段によ
るコピーよりも先に行われて最新のデータが失われてし
まうという弊害が無くなる。In the recorded data online recovery device according to the present invention, of the master recording device and the slave recording device,
The master recording device has area registration means for registering a copy area of the master recording device for copying data to be recovered to the slave recording device, and the writing control means for writing to the master recording device, Since all writing is permitted regardless of the copy area registered by the area registration means, it is possible to issue write requests to the master recording device one after another. On the other hand, the writing control means suspends this writing when the writing means writes to the slave recording device in the copy area registered by the area registration means, and executes the suspended writing after the copying by the copying means is completed. Therefore, the problem that the latest data is lost by writing the data to the slave recording device by the writing means before the copying by the copying means is eliminated.
【0007】[0007]
【実施例】図1は、この発明に係る記録データオンライ
ン回復装置の一実施例を示す図である。図において10
は計算機、20は計算機10に接続されたディスク制御
装置、30はマスター記録装置、40はマスター記録装
置30に記録されるデータと同一のデータを記録するス
レーブ記録装置である。11はマスター記録装置30に
対してデータを記録するとともに同一のデータをスレー
ブ記録装置40に対して記録する書き込み手段である。
50はスレーブ記録装置のデータに障害が有り、マスタ
ー記録装置からスレーブ記録装置に対してデータをコピ
ーすることによりスレーブ記録装置のデータを回復する
ための障害回復手段である。21はマスター記録装置3
0の、ある特定のエリアをコピーエリア31として登録
するエリア登録手段である。12はエリア登録手段21
により登録されたコピーエリア31にあるデータを読み
込み、そのデータをスレーブ記録装置40の対応するエ
リアに書き込むコピー手段である。22はエリア登録手
段により登録されたコピーエリア31に対して書き込み
手段11がデータを書こうとした場合、マスター記録装
置に対してはその書き込みを許可し、スレーブ記録装置
への書き込みに対してはこれを保留し、コピー手段によ
るコピーが終了した後に書き込み手段によるスレーブ記
録装置へのデータの書き込みを許可する書き込み制御手
段である。1 is a diagram showing an embodiment of a recorded data online recovery device according to the present invention. 10 in the figure
Is a computer, 20 is a disk controller connected to the computer 10, 30 is a master recording device, and 40 is a slave recording device for recording the same data as the data recorded in the master recording device 30. Reference numeral 11 is a writing unit that records data in the master recording device 30 and also records the same data in the slave recording device 40.
Reference numeral 50 denotes a failure recovery means for recovering the data of the slave recording device by copying the data from the master recording device to the slave recording device because the data of the slave recording device has a failure. 21 is a master recording device 3
Area registration means for registering a specific area of 0 as the copy area 31. 12 is area registration means 21
It is a copy means that reads data in the copy area 31 registered by and writes the data in the corresponding area of the slave recording device 40. When the writing unit 11 tries to write data to the copy area 31 registered by the area registration unit, the reference numeral 22 permits the master recording device to write the data and the writing to the slave recording device. It is a write control unit that holds this and permits the writing unit to write data to the slave recording device after the copying by the copying unit is completed.
【0008】以下、マスター記録装置をマスターディス
クと呼び、スレーブ記録装置をスレーブディスクと呼
び、コピーエリアをロックエリアと呼び、動作について
説明する。ディスク制御装置のマスターディスク側にエ
リアロック機能を持たせ、コピーのための読み取りに際
しそのエリアのロックを計算機よりディスク制御装置に
対して指令する。エリア登録手段はこのエリアを登録し
ておく。書き込み制御手段は、書き込み手段がこのロッ
クされたエリア以外への書き込みをする場合はマスター
ディスクとスレーブディスクの両方とも通常の書き込み
を許可する。また、スレーブディスク側への書き込みが
完了せずエリアロック開放指令が来ていないマスターデ
ィスク側ロックエリアへのオンライン書き込みに際して
も、ロックされていないエリアと同様に直接書き込みを
実行するとともに、ロックエリアとのオーバーラップを
検出し、オーバーラップの場合、ロックエリア書き込み
ステータスを各書き込み対応、及び各計算機対応でディ
スク制御装置に登録する。そしてロックエリア書き込み
ステータスをマスターディスクへの書き込み終了報告時
に計算機に伝える。The operation will be described below with the master recording apparatus referred to as a master disk, the slave recording apparatus referred to as a slave disk, and the copy area referred to as a lock area. The master disk side of the disk controller is provided with an area lock function, and when reading for copying, the computer commands the disk controller to lock the area. The area registration means registers this area. The writing control means permits normal writing to both the master disk and the slave disk when the writing means writes to areas other than this locked area. Also, when writing online to the master disk side locked area where writing to the slave disk side has not been completed and the area lock release command has not come, direct writing is performed as in the unlocked area, and Is detected, and in the case of overlap, the lock area write status is registered in the disk controller for each write and each computer. Then, the lock area write status is notified to the computer when the writing completion report to the master disk is reported.
【0009】ここで、ロックエリア書き込みステータス
とは計算機からのデータの書き込みがロックエリアに該
当したということを示すためのフラグであり、例えばこ
のロックエリア書き込みステータスを1ビットで示し、
0の時には書き込むデータはロックエリアに該当しない
ことを示し、1の場合にはロックエリアに該当したこと
を示すものとする。書き込み制御手段22は前述したロ
ックエリア書き込みステータスを1にセットし、これを
マスターディスクへのデータの書き込み終了報告と共に
計算機に伝える。Here, the lock area write status is a flag for indicating that writing of data from the computer corresponds to the lock area. For example, this lock area write status is indicated by 1 bit,
When it is 0, it indicates that the data to be written does not correspond to the lock area, and when it is 1, it indicates that it corresponds to the lock area. The write control means 22 sets the above-mentioned lock area write status to 1, and notifies the computer together with the data write completion report to the master disk.
【0010】計算機側では、書き込み手段11が、通常
はマスターディスクへの書き込み終了に引き続きスレー
ブディスクへの書き込み要求を行うが、ロックエリア書
き込みステータスがマスターディスクから報告された場
合には、スレーブディスクへの書き込みを保留する。On the computer side, the writing means 11 normally issues a write request to the slave disk following the completion of writing to the master disk. However, when the lock area write status is reported from the master disk, the write operation is sent to the slave disk. Write pending.
【0011】次にコピー手段により、ロックエリアのデ
ータがマスターディスクからスレーブディスクにコピー
されると、書き込み制御手段がその終了を検出し、ロッ
クエリア書き込みステータスが登録されていた計算機に
対して、ロックエリア開放割り込みを出力する。書き込
み手段は、ロックエリア開放割り込みがディスク制御装
置から伝えられると、保留していたスレーブディスクへ
の書き込み要求を一括して解き、スレーブディスクへの
書き込みを行う。Next, when the data in the lock area is copied from the master disk to the slave disk by the copy means, the write control means detects the end thereof and locks the computer for which the lock area write status is registered. Outputs area release interrupt. When the lock area release interrupt is transmitted from the disk controller, the writing means collectively cancels the pending write requests to the slave disks and writes the slave disks.
【0012】このように、ロックエリア開放割り込みが
ディスク制御装置から伝えられるまで、スレーブディス
クへの書き込み起動を行わずに保留するように制御する
ことにより、スレーブディスク上の新しいオンライン書
き込みデータが古いコピーデータにより失われることを
防ぐことができる。これにより各計算機はロックエリア
の開放を待つことなくマスターディスクへの書き込み要
求をつぎつぎに出すことができ、それらの内、複数のも
のがロックエリアへの書き込みに対応するものであって
も問題なく対処でき、従来例で述べたロックエラー報告
方式のようにマスターディスクへの再起動を必要とする
こともなくなる。In this way, until the lock area release interrupt is transmitted from the disk controller, by controlling so as to hold without starting writing to the slave disk, new online write data on the slave disk is copied to the old copy. Data can be prevented from being lost. This allows each computer to issue write requests to the master disk one after another without waiting for the lock area to be released, and even if a plurality of them correspond to the write to the lock area, there is no problem. This can be dealt with, and it is not necessary to restart the master disk as in the lock error reporting method described in the conventional example.
【0013】以上のような方式は、ディスク制御装置側
では通常通りにディスクへの起動を行いながら、コマン
ドが書き込みと判明しディスクへの書き込みを開始した
後、ロックエリア指定の有無、ロックエリア内書き込み
の判定、各書き込み要求毎、各計算機毎のフラグ設定を
行う程度のロジック、および終了報告時の簡単な追加処
理、ロックエリア登録、変更指令、開放指令及びそれら
に応じたロックエリア開放処理等ですみ、効率的な方式
といえる。According to the above-mentioned method, the disk control device starts the disk as usual, and after the command is found to be writing and the writing to the disk is started, whether the lock area is designated or not Logic for writing judgment, each write request, flag setting for each computer, simple addition processing at the end report, lock area registration, change command, release command and corresponding lock area release processing Therefore, it is an efficient method.
【0014】なお、このように、マスターディスク側書
き込みを直接実行する方式を取ったことにより、前回と
今回の両方のロックエリアにまたがって書き込み要求を
行っていた場合、従来のように計算機側で前回のロック
エリア開放割り込みを受けて再度起動を行ったが、今回
もロックエラーとしてはねられるといった事もなくすこ
とができる。By adopting the method of directly executing the writing on the master disk side as described above, when a writing request is made over both the previous and present lock areas, the computer side is required as in the conventional case. It was restarted after receiving the previous lock area release interrupt, but this time it can be eliminated as a lock error.
【0015】以上のように、この実施例は、ミラーディ
スクデータオンライン回復装置において、複数の計算機
よりアクセスされるミラーディスクシステムのオンライ
ン障害回復時のマスターディスクよりスレーブディスク
へのデータコピー操作にあたり、ディスク制御装置のマ
スターディスク側に計算機から指令されたエリア(コピ
ー対象エリア)をロックエリアとして登録する手段を持
ち、マスターディスクへの計算機よりの書き込み指令は
通常通り実行するとともに、書き込みエリアとロックエ
リアとのオーバーラップを検出し、オーバーラップの場
合そのロックエリア書き込みステータスを登録し、書き
込み終了時にロックエリア書き込みステータスを報告す
る手段を有し、コピー対象ロックエリアの変更指令、あ
るいはロックエリア開放指令に対し登録されていた計算
機全てについて、ロックエリア開放割り込みを報告する
ディスク制御装置を備えていることを特徴とする。As described above, according to this embodiment, in the mirror disk data online recovery device, the data is copied from the master disk to the slave disk during the online failure recovery of the mirror disk system accessed by a plurality of computers. The master disk side of the control unit has a means to register the area (copy target area) instructed by the computer as a lock area, and the writing command from the computer to the master disk is executed as usual, and the writing area and the lock area are Has the means to detect the overlap of the lock area, register the lock area write status in the case of overlap, and report the lock area write status at the end of writing. For computer all that has been registered to the opening command, characterized in that it comprises a disk controller for reporting the lock area open interrupt.
【0016】なお、ディスク制御装置にコピー対象ロッ
クエリアの指令コマンドとして、リード&ロック機能
(通常のリード機能の他に、前回のロックエリアを開放
する機能、及びリード対象エリアをロックエリアとして
登録する機能)を持つようにしてもよい。A read & lock function (in addition to the normal read function, a function of releasing the previous lock area and a read target area as a lock area are registered as command commands for the copy target lock area in the disk controller. Function).
【0017】このリード&ロック機能によれば、通常行
われているようなエリアロック要求、開放要求を(最後
の開放要求を除いて)別途必要とせず、1つの指令コマ
ンドで、通常のリード機能の他に、前回のロックエリア
を開放する機能、及びリード対象エリアをロックエリア
として登録する機能をあわせもつためディスク制御装置
への入出力回数を減らすことが可能となる。またロック
する範囲を必要最小限に限ることにより、ロックされる
確率も少なくなりオーバーヘッド少なく効率的な方式と
いえる。According to the read & lock function, the area lock request and the release request which are normally performed are not separately required (except the last release request), and the normal read function can be executed by one command command. In addition to this, since it has the function of releasing the previous lock area and the function of registering the read target area as the lock area, it is possible to reduce the number of inputs and outputs to the disk control device. Also, by limiting the lock range to the necessary minimum, the probability of lock is reduced, and it can be said that this is an efficient method with less overhead.
【0018】次に、この実施例の具体的動作例について
説明する。図2は2重系計算機システムへの本発明の適
用例を示し、ディスク制御装置、ミラーディスク(マス
ターディスクA,C,EにスレーブディスクB,D,F
が各々対応する)を示す。図3はミラーディスクの回復
処理時の書き込みエリアロックの必要性を示す図であ
り、a,bの線上にマスター、スレーブディスクへの入
出力を示す。ここで回復処理はa0r−b0w,a1r
−b1w,・・・の順序でマスターディスクからの読み
取り、スレーブディスクへの書き込みを繰り返してい
る。xa0w−xb0w,ya0w−yb0w等はオン
ラインプログラムからのミラーモード書き込みを示す。
エリアa0への書き込みがすでに回復コピー用読み取り
a0rより前に終了しているxa0wに対応する書き込
みxb0wはコピープログラムからの書き込みb0wと
は無関係に実行してよいが、a0rより後の書き込みy
a0wに対応するyb0wがコピープログラムからの書
き込みb0wより先行すると、そのデータはBディスク
には結局書き込まれなかったことと同じで失われてしま
う。したがって本実施例ではAディスクへのオンライン
書き込みの終了処理をロックエリア書き込みステータス
が報告された場合には、Bディスクへのコピー書き込み
が終了しエリアロック開放割り込みが報告されるまで
(エリアロック要求、開放指令を単独で実行する場
合)、あるいはAディスクからの次エリアのコピー読み
取りa1rの実行開始によりエリアロック開放割り込み
が報告されるまで(リード&ロック機能を使用の場合)
Aディスクの終了処理、Bディスクへのミラーモード書
き込みを実質的に保留することによりデータの消失を防
いだ。ここでya0wの終了割り込み処理はBディスク
へのコピー書き込み終了時点まで、区間Xの間遅らせば
良いが、リード&ロック方式の場合ディスク装置との問
答を少なくする意味で次のコピー読み取り開始まで(あ
るいはエリアロック開放まで)の間:区間Sの間遅らせ
ることとした。Next, a specific operation example of this embodiment will be described. FIG. 2 shows an example of application of the present invention to a dual computer system, in which a disk controller, mirror disks (master disks A, C, E are slave disks B, D, F).
Correspond to each other). FIG. 3 is a diagram showing the necessity of the write area lock at the time of recovery processing of the mirror disk, and the lines a and b show the input / output to / from the master and slave disks. Here, the recovery process is a0r-b0w, a1r.
Reading from the master disk and writing to the slave disk are repeated in the order of -b1w, .... xa0w-xb0w, ya0w-yb0w, etc. indicate the mirror mode writing from the online program.
The write xb0w corresponding to xa0w whose writing to the area a0 has already finished before the recovery copy read a0r may be executed independently of the write b0w from the copy program, but the write y after a0r
If yb0w corresponding to a0w precedes writing b0w from the copy program, the data will be lost as if it were not written to the B disc. Therefore, in this embodiment, when the lock area write status is reported for the completion of the online writing to the A disk, the copy writing to the B disk is completed and the area lock release interrupt is reported (area lock request, (When the release command is executed independently), or until the area lock release interrupt is reported by the start of execution of the next area copy reading a1r from the A disk (when the read & lock function is used)
Data loss was prevented by substantially suspending the end processing of the A disk and the mirror mode writing to the B disk. Here, the end interrupt processing of ya0w may be delayed for the period X until the end of the copy writing to the B disk, but in the case of the read & lock method, it means until the next copy reading is started in order to reduce the number of questions and answers with the disk device. Or until the area lock is released): Delayed during section S.
【0019】実施例2.実施例1では複数の計算機を含
む場合について述べたが、単独の計算機の場合にも有効
である。また実施例1ではディスク制御装置をマスター
側スレーブ側と2個持った場合を考えたが、ディスク媒
体/装置の信頼度を上げることを中心に考え制御装置1
個でミラーディスクシステムを構成する場合等も考えら
れる。この場合にはマスターディスクロックエリアへの
書き込みが終了しても計算機への報告をすぐには行わ
ず、ロックエリアの開放を待ってスレーブディスクへの
書き込みを完了した後終了割り込みを出力し、回復コピ
ー処理プログラム以外は全くエリアロックを意識しない
ですむ方式とすることも考えられる。但しこの場合各々
の計算機毎に複数個の起動要求を受け付けディスクの効
率的な利用を計るようにする必要がある。Example 2. Although the first embodiment has described the case of including a plurality of computers, it is also effective in the case of a single computer. Further, in the first embodiment, the case where the two disk control devices are provided on the master side and the slave side is considered, but the control device 1 is focused on improving the reliability of the disk medium / device.
There may be a case where a mirror disk system is composed of individual pieces. In this case, even if writing to the master disk lock area is completed, it will not be reported to the computer immediately, but will wait for the lock area to be released, complete writing to the slave disk, then output an end interrupt and recover. It is conceivable to adopt a method that does not need to be aware of area lock except for the copy processing program. However, in this case, it is necessary to accept a plurality of activation requests for each computer and to plan efficient use of the disk.
【0020】実施例3.上記実施例1においては、デー
タを記録する媒体がディスクである場合を示したが、デ
ィスクである場合に限らずその他の磁気記録装置あるい
は光記録装置等のデータを記録する記録装置であれば構
わない。Example 3. In the first embodiment, the case where the medium for recording the data is the disk is shown, but the recording medium is not limited to the disk, and any other magnetic recording device or an optical recording device may be used as the recording device for recording the data. Absent.
【0021】実施例4.上記実施例1ではマスターディ
スクからスレーブディスクにデータを回復する場合を示
したが、このマスターというのはデータを保有している
方を指し、スレーブとは障害が起こっている方を指すも
のとし、計算機システムの通常の使用時において、主従
の関係でデータを記録する場合のマスターあるいはスレ
ーブという関係に限定されるものではない。すなわち、
回復させるべきデータを保持しているものがマスターで
あり、障害が起きている方がスレーブである。Example 4. In the first embodiment described above, the case of recovering data from the master disk to the slave disk is shown. However, the master refers to the person who holds the data, and the slave refers to the person who has a failure. It is not limited to a master or slave relationship when data is recorded in a master-slave relationship during normal use of the computer system. That is,
The one holding the data to be recovered is the master, and the one with the failure is the slave.
【0022】[0022]
【発明の効果】以上のように、この発明によれば、計算
機間交信及びロックエラーにともなう計算機からの書き
込み要求の再起動を不要とし、オンライン回復コピー操
作の高速化が計れる。As described above, according to the present invention, it is not necessary to restart the write request from the computer due to the communication between computers and the lock error, and the online recovery copy operation can be speeded up.
【図面の簡単な説明】[Brief description of drawings]
【図1】この発明に係る記録データオンライン回復装置
の構成を示す図である。FIG. 1 is a diagram showing a configuration of a recorded data online recovery device according to the present invention.
【図2】この発明に係る記録データオンライン回復装置
の一具体例を示す図である。FIG. 2 is a diagram showing a specific example of a recorded data online recovery device according to the present invention.
【図3】この発明に係る記録データオンライン回復装置
の動作を説明するための図である。FIG. 3 is a diagram for explaining the operation of the recorded data online recovery device according to the present invention.
【符号の説明】 10 計算機 11 書き込み手段 12 コピー手段 20 ディスク制御装置 21 エリア登録手段 22 書き込み制御手段 30 マスター記録装置(マスターディスク) 40 スレーブ記録装置(スレーブディスク) 50 障害回復手段[Explanation of reference numerals] 10 computer 11 writing means 12 copying means 20 disk control device 21 area registration means 22 writing control means 30 master recording device (master disk) 40 slave recording device (slave disk) 50 failure recovery means
【手続補正2】[Procedure Amendment 2]
【補正対象書類名】図面[Document name to be corrected] Drawing
【補正対象項目名】図1[Name of item to be corrected] Figure 1
【補正方法】変更[Correction method] Change
【補正内容】[Correction content]
【図1】 [Figure 1]
Claims (1)
ン回復装置 (a)データを記録するマスター記録装置、 (b)上記マスター記録装置に記録されるデータと同一
のデータを記録するスレーブ記録装置、 (c)上記マスター記録装置及びスレーブ記録装置に同
一のデータを書き込む書き込み手段、 (d)以下の要素を有し、上記書き込み手段の動作中
に、スレーブ記録装置の障害を回復する障害回復手段、
(d1)上記マスター記録装置からスレーブ記録装置へ
データをコピーするためのマスター記録装置のコピーエ
リアを登録するエリア登録手段、(d2)上記エリア登
録手段により登録されたマスター記録装置のコピーエリ
アのデータをスレーブ記録装置へコピーするコピー手
段、(d3)上記エリア登録手段により登録されたマス
ター記録装置のコピーエリアに対して上記書き込み手段
による書き込みが発生した場合、マスター記録装置への
書き込みは許可するとともに、スレーブ記録装置への書
き込みは保留し、上記コピー手段によるコピー終了後に
保留した書き込みをスレーブ記録装置に対して実行させ
る書き込み制御手段。1. A recorded data online recovery device having the following elements: (a) a master recording device for recording data; (b) a slave recording device for recording the same data as the data recorded in the master recording device; c) writing means for writing the same data in the master recording device and the slave recording device; (d) failure recovery means for recovering a failure of the slave recording device while the writing means is in operation, having the following elements:
(D1) area registration means for registering a copy area of the master recording device for copying data from the master recording device to the slave recording device, (d2) data of the copy area of the master recording device registered by the area registration means Means for copying the data to the slave recording device, and (d3) when writing by the writing device occurs in the copy area of the master recording device registered by the area registration device, the writing to the master recording device is permitted and Write control means for suspending writing to the slave recording apparatus and causing the slave recording apparatus to execute the suspended writing after the copying by the copying means is completed.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP4190802A JPH0635781A (en) | 1992-07-17 | 1992-07-17 | Recorded data on-line recovery device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP4190802A JPH0635781A (en) | 1992-07-17 | 1992-07-17 | Recorded data on-line recovery device |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH0635781A true JPH0635781A (en) | 1994-02-10 |
Family
ID=16263992
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP4190802A Pending JPH0635781A (en) | 1992-07-17 | 1992-07-17 | Recorded data on-line recovery device |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH0635781A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2001134482A (en) * | 1999-06-29 | 2001-05-18 | Emc Corp | Method for performing independent data copy in a data processing system |
-
1992
- 1992-07-17 JP JP4190802A patent/JPH0635781A/en active Pending
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2001134482A (en) * | 1999-06-29 | 2001-05-18 | Emc Corp | Method for performing independent data copy in a data processing system |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| USRE37038E1 (en) | Method and system for automated termination and resumption in a time zero backup copy process | |
| US5375232A (en) | Method and system for asynchronous pre-staging of backup copies in a data processing storage subsystem | |
| JP2557172B2 (en) | Method and system for secondary file status polling in a time zero backup copy process | |
| US5241670A (en) | Method and system for automated backup copy ordering in a time zero backup copy session | |
| JP2003223287A (en) | Storage device, backup method and program for the storage device | |
| JPH0683687A (en) | Data processing system and method thereof | |
| JPH0743676B2 (en) | Back-up data dump control method and device | |
| WO2005122007A2 (en) | Method, system, and program for migrating source data to target data | |
| US8555012B2 (en) | Data storage apparatus | |
| JPH05210555A (en) | Method and apparatus for zero-time data backup copy | |
| JP4104281B2 (en) | Database access method | |
| US6954835B1 (en) | Intercepting control of a host I/O process | |
| JPH11242566A (en) | Multiplexed data storage system | |
| JPS648848B2 (en) | ||
| JPS63305445A (en) | Data writing system at power break | |
| US6453323B1 (en) | Resolving long-busy conditions for synchronized data sets | |
| JP2834036B2 (en) | Lock controller | |
| JP2001101051A (en) | Magnetic disk drive | |
| JP3033509B2 (en) | Transaction delay recovery method, delay recovery method, and recording medium recording delay recovery program | |
| JPH0264815A (en) | Disk cache control system | |
| JPH01128122A (en) | Control system for volume dynamic copying | |
| JPS61208119A (en) | Disk controller | |
| JPS6167153A (en) | Partial trouble recovery processing system of direct access storage device | |
| JPH05181613A (en) | Information processor | |
| JPH0713943A (en) | Parallel computer |