JP2972223B2 - Rollback method for sequential files without journal - Google Patents

Rollback method for sequential files without journal

Info

Publication number
JP2972223B2
JP2972223B2 JP1105997A JP10599789A JP2972223B2 JP 2972223 B2 JP2972223 B2 JP 2972223B2 JP 1105997 A JP1105997 A JP 1105997A JP 10599789 A JP10599789 A JP 10599789A JP 2972223 B2 JP2972223 B2 JP 2972223B2
Authority
JP
Japan
Prior art keywords
file
position pointer
input
output
pointer
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.)
Expired - Fee Related
Application number
JP1105997A
Other languages
Japanese (ja)
Other versions
JPH02285438A (en
Inventor
徹 三輪
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.)
NEC Corp
Original Assignee
Nippon Electric Co 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 Nippon Electric Co Ltd filed Critical Nippon Electric Co Ltd
Priority to JP1105997A priority Critical patent/JP2972223B2/en
Publication of JPH02285438A publication Critical patent/JPH02285438A/en
Application granted granted Critical
Publication of JP2972223B2 publication Critical patent/JP2972223B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は高水準言語処理プログラム,利用者プログラ
ム等のプログラムの障害発生時に再処理のために行われ
るファイルの復旧処理に関し、特にジャーナル無し順処
理ファイル(ジャーナルがとられていない順データセッ
トをいう。以下同様)でなる入力ファイルおよび出力フ
ァイルの復旧処理を自動的に行うジャーナル無し処理フ
ァイルのロールバック方式に関する。
Description: BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a file recovery process performed for reprocessing when a failure occurs in a program such as a high-level language processing program, a user program, etc. The present invention relates to a rollback method for a journal-less process file that automatically performs a process of restoring an input file and an output file that is a process file (referred to as a sequential data set that has not been journaled; the same applies hereinafter).

〔従来の技術〕[Conventional technology]

従来、ジャーナル無し順処理ファイルでなる入力ファ
イルの復旧処理では、プログラム自身で入力ファイルに
対するレコード位置の位置付け(入力ファイルのVTOC
(Volume Table Of Contents)中のファイル位置ポ
インタの回復)を行うことにより、入力ファイルのロー
ルバックを行っていた。
Conventionally, in input file recovery processing consisting of sequential files without journals, the program itself positions the record position with respect to the input file (VTOC of the input file).
(Recovery of file position pointer in (Volume Table Of Contents)) to roll back the input file.

また、ジャーナル無し順処理ファイルでなる出力ファ
イルの復旧処理では、出力ファイルに対してはレコード
位置の位置付け(出力ファイルのVTOC中のファイル位置
ポインタの回復)ができなかったので、プログラムの実
行を最初からやり直していた。
Also, in the recovery processing of the output file consisting of the sequential files without journal, the record position could not be positioned (recovery of the file position pointer in the VTOC of the output file) for the output file. Was starting over.

〔発明が解決しようとする課題〕[Problems to be solved by the invention]

上述した従来のジャーナル無し順処理ファイルでなる
入力ファイルの復旧処理では、入力ファイルに対するレ
コード位置の位置付けをプログラム自身で行っていたの
で、プログラムにおける処理が煩雑になるという欠点が
ある。
In the above-described conventional input file recovery processing that is a journal-less sequential processing file, since the program positions the record position with respect to the input file by itself, there is a disadvantage that the processing in the program becomes complicated.

また、従来のジャーナル無し順処理ファイルでなる出
力ファイルの復旧処理では、出力ファイルに対するレコ
ード位置の位置付けができなかったので、出力ファイル
のロールバックができないという致命的な欠点がある。
Further, in the conventional recovery processing of an output file that is a sequential processing file without a journal, there is a fatal drawback that the output file cannot be rolled back because the record position cannot be positioned with respect to the output file.

本発明の目的は、上述の点に鑑み、ジャーナル無し順
処理ファイルでなる入力ファイルおよび出力ファイルの
ロールバックを自動的に行えるようにしたジャーナル無
し順処理ファイルのロールバック方式を提供することに
ある。
SUMMARY OF THE INVENTION An object of the present invention is to provide a journal-less sequential processing file rollback method in which an input file and an output file consisting of a journal-less sequential processing file can be automatically rolled back. .

〔課題を解決するための手段〕[Means for solving the problem]

本発明のジャーナル無し順処理ファイルのロールバッ
ク方式は、ジャーナル無し順処理ファイルである入力フ
ァイルから少なくとも1レコードのデータを入力し必要
な処理を施してジャーナル無し順処理ファイルである出
力ファイルに出力するトランザクションに障害が発生し
た場合に前記入力ファイルおよび前記出力ファイルを該
トランザクションの実行前の状態にロールバックするジ
ャーナル無し順処理ファイルのロールバック方式におい
て、VTOC中の前記入力ファイルのファイル内レコード位
置を示すファイル位置ポインタおよび前記出力ファイル
のファイル内レコード位置を示すファイル位置ポインタ
を更新するVTOC情報更新手段と、プログラムのトランザ
クション処理の開始時に、その時点での前記入力ファイ
ルの入力ファイル位置ポインタおよび前記出力ファイル
の出力ファイル位置ポインタを渡して前記VTOC情報更新
手段を呼び出し、VTOC中の前記入力ファイルのファイル
位置ポインタおよび前記出力ファイルのファイル位置ポ
インタを更新させるとともに、その時点での前記入力フ
ァイルの入力ファイル位置ポインタおよび前記出力ファ
イルの出力ファイル位置ポインタを退避エリアに退避す
るファイル位置ポインタ退避手段と、プログラムの障害
発生時に、前記退避エリアに退避されている入力ファイ
ル位置ポインタおよび出力ファイル位置ポインタを渡し
て前記VTOC情報更新手段を呼び出し、VTOC中の前記入力
ファイルのファイル位置ポインタおよび前記出力ファイ
ルのファイル位置ポインタを回復させるファイル位置ポ
インタ回復手段とを有する。
According to the rollback method of a non-journaled sequential processing file of the present invention, at least one record of data is input from an input file which is a non-journaled sequential processing file, subjected to necessary processing, and output to an output file which is a non-journaled sequential processing file. When a failure occurs in a transaction, the input file and the output file are rolled back to a state before execution of the transaction. VTOC information updating means for updating a file position pointer indicating a file position pointer and a file position pointer indicating a record position in the file of the output file; and input file position of the input file at the time of starting transaction processing of a program. Calling the VTOC information updating means by passing the interface and the output file position pointer of the output file to update the file position pointer of the input file and the file position pointer of the output file in the VTOC, and File position pointer saving means for saving an input file position pointer of a file and an output file position pointer of the output file to a save area, and an input file position pointer and an output file position saved in the save area when a program failure occurs File position pointer recovery means for calling the VTOC information updating means by passing a pointer and recovering a file position pointer of the input file and a file position pointer of the output file in the VTOC.

〔作用〕[Action]

本発明のジャーナル無し順処理ファイルのロールバッ
ク方式では、VTOC情報更新手段が入力ファイルのVTOC中
のファイル位置ポインタおよび出力ファイルのVTOC中の
ファイル位置ポインタを更新し、ファイル位置ポインタ
退避手段がプログラムのトランザクション処理の開始時
にその時点での入力ファイルの入力ファイル位置ポイン
タおよび出力ファイルの出力ファイル位置ポインタを渡
してVTOC情報更新手段を呼び出し入力ファイルのVTOC中
のファイル位置ポインタおよび出力ファイルのVTOC中の
ファイル位置ポインタを更新させるとともにその時点で
の入力ファイルの入力ファイル位置ポインタおよび出力
ファイルの出力ファイル位置ポインタを退避エリアに退
避し、ファイル位置ポインタ回復手段がプログラムの障
害発生時に退避エリアに退避されている入力ファイル位
置ポインタおよび出力ファイル位置ポインタを渡してVT
OC情報更新手段を呼び出し入力ファイルのVTOC中のファ
イル位置ポインタおよび出力ファイルのVTOC中のファイ
ル位置ポインタを回復させる。
In the rollback method of the sequential processing file without journal according to the present invention, the VTOC information updating means updates the file position pointer in the VTOC of the input file and the file position pointer in the VTOC of the output file, and the file position pointer saving means stores the program. At the start of the transaction processing, the input file position pointer of the input file and the output file position pointer of the output file at that time are passed and the VTOC information updating means is called, and the file position pointer in the VTOC of the input file and the file in the VTOC of the output file Updates the position pointer and saves the input file position pointer of the input file and the output file position pointer of the output file at that time to the save area, and the file position pointer recovery means saves to the save area when a program failure occurs VT passes the input file position pointer and the output file position pointer has been
The OC information updating means is called to recover the file position pointer in the VTOC of the input file and the file position pointer in the VTOC of the output file.

〔実施例〕〔Example〕

次に、本発明について図面を参照して詳細に説明す
る。
Next, the present invention will be described in detail with reference to the drawings.

第1図は、本発明の一実施例に係るジャーナル無し順
処理ファイルのロールバック方式の構成を示すブロック
図である。本実施例のジャーナル無し順処理ファイルの
ロールバック方式は、プログラム1と、ジャーナル無し
順処理ファイルでなる入力ファイル2と、ジャーナル無
し順処理ファイルでなる出力ファイル3と、実行プログ
ラムモニタ4と、退避エリア5とから、その主要部が構
成されている。
FIG. 1 is a block diagram showing a configuration of a rollback method of a journal-less sequential processing file according to an embodiment of the present invention. The rollback method of the journal-less sequential processing file of the present embodiment includes a program 1, an input file 2 consisting of a journal-less sequential processing file, an output file 3 consisting of a journal-less sequential processing file, an execution program monitor 4, and an evacuation program. The main part is composed of the area 5.

実行プログラムモニタ4は、ファイル位置ポインタ退
避手段41と、ファイル位置ポインタ回復手段42と、VTOC
情報更新手段43とを含んで構成されている。
The execution program monitor 4 includes a file position pointer saving unit 41, a file position pointer recovery unit 42, a VTOC
And an information updating means 43.

次に、このように構成された本実施例のジャーナル無
し順処理ファイルのロールバック方式の動作について説
明する。
Next, the operation of the rollback method of the thus-configured non-journal processed file according to the present embodiment will be described.

プログラム1は、トランザクション処理(入力ファイ
ル2から単数または複数のレコードからなる1処理単位
のデータ(以下、トランザクションという)を入力し必
要な処理を施して出力ファイル3に出力する一連の処理
をいう。以下同様)の開始時に、実行プログラムモニタ
4中のファイル位置ポインタ退避手段41を呼び出す。
The program 1 refers to a series of processing of inputting one processing unit of data (hereinafter, referred to as a transaction) including one or a plurality of records from the input file 2, performing necessary processing, and outputting the processed data to the output file 3. At the start of the same, the file position pointer saving means 41 in the execution program monitor 4 is called.

ファイル位置ポインタ退避手段41は、入力ファイル2
に関するファイルコントロールブロック(図示せず)お
よび出力ファイル3に関するファイルコントロールブロ
ック(図示せず)等から入力ファイル2のファイル位置
ポインタ(以下、入力ファイル位置ポインタという)お
よび出力ファイル3のファイル位置ポインタ(以下、出
力ファイル位置ポインタという)を得、得られた入力フ
ァイル位置ポインタおよび出力ファイル位置ポインタを
渡してVTOC情報更新手段43を呼び出す。
The file position pointer saving means 41 stores the input file 2
From the file control block (not shown) for the output file 3 and the file position pointer for the output file 3 (hereinafter referred to as the input file position pointer) , Output file position pointer), and passes the obtained input file position pointer and output file position pointer to call the VTOC information updating means 43.

VTOC情報更新手段43は、渡された入力ファイル位置ポ
インタおよび出力ファイル位置ポインタによって入力フ
ァイル2のVTOC中のファイル位置ポインタおよび出力フ
ァイル3のVTOC中のファイル位置ポインタをそれぞれ更
新し、その時点までに行われた入力ファイル2からの入
力処理および出力ファイル3に対する出力処理を有効と
する。
The VTOC information updating means 43 updates the file position pointer in the VTOC of the input file 2 and the file position pointer in the VTOC of the output file 3 with the passed input file position pointer and output file position pointer, respectively. The executed input processing from the input file 2 and output processing for the output file 3 are validated.

また、ファイル位置ポインタ退避手段41は、得られた
入力ファイル位置ポインタおよび出力ファイル位置ポイ
ンタを退避エリア5に退避する。
In addition, the file position pointer saving means 41 saves the obtained input file position pointer and output file position pointer in the save area 5.

あるトランザクションの処理中にプログラム1に障害
が発生すると、当該トランザクションの処理をやり直す
必要があるので、プログラム1は、実行プログラムモニ
タ4中のファイル位置ポインタ回復手段42を呼び出す。
If a failure occurs in the program 1 during the processing of a certain transaction, the processing of the transaction must be redone. Therefore, the program 1 calls the file position pointer recovery means 42 in the execution program monitor 4.

ファイル位置ポインタ回復手段42は、退避エリア5に
退避されている入力ファイル位置ポインタおよび出力フ
ァイル位置ポインタを取り出し、取り出した入力ファイ
ル位置ポインタおよび出力ファイル位置ポインタを渡し
てVTOC情報更新手段43を呼び出す。
The file position pointer recovery means 42 extracts the input file position pointer and the output file position pointer saved in the save area 5 and passes the extracted input file position pointer and output file position pointer to call the VTOC information updating means 43.

VTOC情報更新手段43は、渡された入力ファイル位置ポ
インタおよび出力ファイル位置ポインタを入力ファイル
2のVTOC中のファイル位置ポインタおよび出力ファイル
3のVTOC中のファイル位置ポインタにそれぞれ回復する
ことにより、障害発生時点で処理中のトランザクション
処理の開始時における入力ファイル2のレコード位置お
よび出力ファイル3のレコード位置にそれぞれ位置付け
る。
The VTOC information updating means 43 restores the passed input file position pointer and output file position pointer to the file position pointer in the VTOC of the input file 2 and the file position pointer in the VTOC of the output file 3, respectively. It is positioned at the record position of the input file 2 and the record position of the output file 3 at the start of the transaction process currently being processed.

以上のようにして、入力ファイル2および出力ファイ
ル3のロールバック処理が自動的に行われる。
As described above, the rollback processing of the input file 2 and the output file 3 is automatically performed.

〔発明の効果〕〔The invention's effect〕

以上説明したように本発明は、プログラムのトランザ
クション処理の開始時に入力ファイル位置ポインタおよ
び出力ファイル位置ポインタの更新処理および退避処理
を行い、プログラムの障害発生時に入力ファイル位置ポ
インタおよび出力ファイル位置ポインタの回復処理を行
うようにしたことにより、プログラムにおいて入力ファ
イルのレコード位置の位置付けを意識して入力ファイル
のロールバックを行う煩雑さを解消することができると
いう効果がある。
As described above, according to the present invention, the input file position pointer and the output file position pointer are updated and saved at the start of the transaction processing of the program, and the input file position pointer and the output file position pointer are restored when the program fails. By performing the processing, there is an effect that the complexity of rolling back the input file in the program while being aware of the position of the record position of the input file can be eliminated.

また、プログラムのトランザクション処理の開始時に
出力ファイルのVTOC中のファイル位置ポインタの更新処
理がかならず行われるので、出力ファイルのロールバッ
ク処理が可能になるとともに、プログラムにおいて出力
ファイルのレコード位置の位置付けを意識して出力ファ
イルのロールバックを行う必要はないという効果があ
る。
Also, since the file position pointer in the VTOC of the output file is always updated at the start of the transaction processing of the program, the output file can be rolled back and the program must be aware of the position of the record position in the output file. The effect is that there is no need to roll back the output file.

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

第1図は本発明の一実施例に係るジャーナル無し順処理
ファイルのロールバック方式の構成を示すブロック図で
ある。 図において、 1……プログラム、 2……入力ファイル、 3……出力ファイル、 4……実行プログラムモニタ、 5……退避エリア、 41……ファイル位置ポインタ退避手段、 42……ファイル位置ポインタ回復手段、 43……VTOC情報更新手段である。
FIG. 1 is a block diagram showing a configuration of a rollback system of a journal-less sequential processing file according to an embodiment of the present invention. In the figure, 1 ... program, 2 ... input file, 3 ... output file, 4 ... execution program monitor, 5 ... save area, 41 ... file position pointer saving means, 42 ... file position pointer recovery means , 43 ... VTOC information updating means.

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】ジャーナル無し順処理ファイルである入力
ファイルから少なくとも1レコードのデータを入力し必
要な処理を施してジャーナル無し順処理ファイルである
出力ファイルに出力するトランザクションに障害が発生
した場合に前記入力ファイルおよび前記出力ファイルを
該トランザクションの実行前の状態にロールバックする
ジャーナル無し順処理ファイルのロールバック方式にお
いて、 VTOC中の前記入力ファイルのファイル内レコード位置を
示すファイル位置ポインタおよび前記出力ファイルのフ
ァイル内レコード位置を示すファイル位置ポインタを更
新するVTOC情報更新手段と、 プログラムのトランザクション処理の開始時に、その時
点での前記入力ファイルの入力ファイル位置ポインタお
よび前記出力ファイルの出力ファイル位置ポインタを渡
して前記VTOC情報更新手段を呼び出し、VTOC中の前記入
力ファイルのファイル位置ポインタおよび前記出力ファ
イルのファイル位置ポインタを更新させるとともに、そ
の時点での前記入力ファイルの入力ファイル位置ポイン
タおよび前記出力ファイルの出力ファイル位置ポインタ
を退避エリアに退避するファイル位置ポインタ退避手段
と、 プログラムの障害発生時に、前記退避エリアに退避され
ている入力ファイル位置ポインタおよび出力ファイル位
置ポインタを渡して前記VTOC情報更新手段を呼び出し、
VTOC中の前記入力ファイルのファイル位置ポインタおよ
び前記出力ファイルのファイル位置ポインタを回復させ
るファイル位置ポインタ回復手段とを有することを特徴
とするジャーナル無し順処理ファイルのロールバック方
式。
When a failure occurs in a transaction for inputting at least one record of data from an input file which is a journal-less sequential processing file, performing necessary processing and outputting the data to an output file which is a journal-less sequential processing file, In a rollback method of a non-journal sequential processing file in which an input file and the output file are rolled back to a state before execution of the transaction, a file position pointer indicating a record position in the input file in the VTOC and a file position pointer of the output file VTOC information updating means for updating a file position pointer indicating a record position in a file; and at the start of a program transaction process, an input file position pointer of the input file and an output file position of the output file at that time. The VOC information updating means is called by passing the location pointer to update the file location pointer of the input file and the file location pointer of the output file in the VTOC, and the input file location pointer and the input file location pointer of the input file at that time. File position pointer saving means for saving the output file position pointer of the output file to the save area; and updating the VTOC information by passing the input file position pointer and the output file position pointer saved to the save area when a program failure occurs. Call means,
A file position pointer recovering means for recovering a file position pointer of the input file and a file position pointer of the output file in a VTOC;
JP1105997A 1989-04-27 1989-04-27 Rollback method for sequential files without journal Expired - Fee Related JP2972223B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP1105997A JP2972223B2 (en) 1989-04-27 1989-04-27 Rollback method for sequential files without journal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP1105997A JP2972223B2 (en) 1989-04-27 1989-04-27 Rollback method for sequential files without journal

Publications (2)

Publication Number Publication Date
JPH02285438A JPH02285438A (en) 1990-11-22
JP2972223B2 true JP2972223B2 (en) 1999-11-08

Family

ID=14422352

Family Applications (1)

Application Number Title Priority Date Filing Date
JP1105997A Expired - Fee Related JP2972223B2 (en) 1989-04-27 1989-04-27 Rollback method for sequential files without journal

Country Status (1)

Country Link
JP (1) JP2972223B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2797749B2 (en) * 1991-03-25 1998-09-17 日本電気株式会社 File destruction pre-check mechanism

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6113328A (en) * 1984-06-28 1986-01-21 Fujitsu Ltd Accessing system of data file

Also Published As

Publication number Publication date
JPH02285438A (en) 1990-11-22

Similar Documents

Publication Publication Date Title
JPH04139544A (en) Data restoring method
JP2972223B2 (en) Rollback method for sequential files without journal
JPH0594353A (en) Database management system
JPH0594356A (en) On-memory table data fault restoration system
JPH02267645A (en) Automatic roll-back system for report file
JP3029812B2 (en) Operation error recovery method and apparatus, and computer-readable recording medium storing a program for causing a computer to execute the method
JP2623968B2 (en) Commit synchronization control method for journalless files
JPS6159538A (en) Queue control system between tasks
JPH01180651A (en) Commit synchronization control system for report file output
JPH0363844A (en) File protection managing system
JPH05134888A (en) Information processor
JPH08249209A (en) Method for testing application program in on-line transaction system
JPH04113428A (en) Data restoring system
JPH07311702A (en) Data base restoration device for deferred processing
JPH02162437A (en) File processor
JPH05265828A (en) Journal sampling device for batch processing program
JPH06187217A (en) System for synchronization between data base and normal file
JPS63228245A (en) Automatic restoration system for data base
JPH01214947A (en) Data preserving system
JP2000293416A (en) Database processor and storage medium
JPS6310251A (en) Control system for record indicator
JPH0588855A (en) Trouble recovering system
JPH0581106A (en) System for restoring data base
JPH03282847A (en) Method for preventing double update for master file update processing re-execution
JPH03233634A (en) Job reprocessing system

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees