JPH10161932A - Disk cache control system - Google Patents

Disk cache control system

Info

Publication number
JPH10161932A
JPH10161932A JP8319624A JP31962496A JPH10161932A JP H10161932 A JPH10161932 A JP H10161932A JP 8319624 A JP8319624 A JP 8319624A JP 31962496 A JP31962496 A JP 31962496A JP H10161932 A JPH10161932 A JP H10161932A
Authority
JP
Japan
Prior art keywords
data
file
disk cache
input
cache memory
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.)
Granted
Application number
JP8319624A
Other languages
Japanese (ja)
Other versions
JP3111912B2 (en
Inventor
Takahiro Okonogi
崇宏 小此木
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
NEC Corp
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 NEC Corp filed Critical NEC Corp
Priority to JP08319624A priority Critical patent/JP3111912B2/en
Publication of JPH10161932A publication Critical patent/JPH10161932A/en
Application granted granted Critical
Publication of JP3111912B2 publication Critical patent/JP3111912B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Memory System Of A Hierarchy Structure (AREA)

Abstract

PROBLEM TO BE SOLVED: To improve the hit rate of disk cache and to shorten the input/output processing time. SOLUTION: When data for a user program 1 to request input are stored in a disk cache memory 7, these data are read out of the dish cache memory 7 and applied to the user program 1 by a cache control means 5 but when these data are not stored, they are read out of a file and applied to the user program 1. When it is judged while referring to input/output history information in the past to data in the file that possibility for data read out of the disk cache memory 7 to be inputted/outputted again is high the cache control means 5 improves the resident degree of these data in the disk cache memory 7. When the possibility for the data read out of the file to be inputted/outputted again is judged high, these data are stored in the disk cache memory 7.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、ファイルの特性に
応じて、該ファイルから読み出されたデータのディスク
キャッシュ上における常駐度を制御するディスクキャッ
シュ制御方式に関する。
[0001] 1. Field of the Invention [0002] The present invention relates to a disk cache control method for controlling the degree of residence of data read from a file on a disk cache according to the characteristics of the file.

【0002】[0002]

【従来の技術】特開昭64−82239号公報には、磁
気ディスク上に作成されるファイルに対して予め近接す
るブロックを割り当てておき、ファイル管理システムか
らディスクキャッシュに存在しないブロックデータの読
み出しが要求された際には、要求されたブロックと該ブ
ロックに近接する複数のブロックのデータを磁気ディス
クから読み出して、ディスクキャッシュに格納するもの
が記載されている。
2. Description of the Related Art Japanese Unexamined Patent Publication No. 64-82239 discloses that a file created on a magnetic disk is allocated with adjacent blocks in advance, and a file management system reads block data that does not exist in a disk cache. It describes that when requested, data of a requested block and a plurality of blocks adjacent to the requested block are read from a magnetic disk and stored in a disk cache.

【0003】[0003]

【発明が解決しようとする課題】しかしながら、特開昭
64−82239号公報記載の技術は、ファイル作成時
に予めディスク装置内の近接するブロック群を確保して
該ファイルに割り当てなければならないが、ディスク装
置内にこのような近接する該ブロック群を確保すること
は容易ではないという問題点がある。
However, in the technique described in Japanese Patent Application Laid-Open No. Sho 64-82239, it is necessary to secure a group of adjacent blocks in a disk device in advance when creating a file and to allocate the block to the file. There is a problem that it is not easy to secure such close blocks in the apparatus.

【0004】また、あるブロックデータの読み出しが要
求されたからといって、必ずしも該ブロックデータの近
接するブロックデータに対する読み出し要求が後続する
とは限らず、読み出し要求が後続しない場合には、読み
出されないブロック群がディスクキャッシュに滞留して
しまい、該ディスクキャッシュのヒット率が低下してし
まうという問題点がある。
[0004] Also, just because a request to read certain block data does not always follow a read request for block data adjacent to the block data, and if no read request follows, a block that is not read is not read. There is a problem that the group stays in the disk cache and the hit rate of the disk cache decreases.

【0005】本発明の目的は、ディスクキャッシュのヒ
ット率を向上させ、入出力処理時間を短縮することにあ
る。
An object of the present invention is to improve the hit rate of a disk cache and reduce the input / output processing time.

【0006】本発明の他の目的は、ファイルの過去のア
クセス特性に基づいて、該ファイルを構成するブロック
データのディスクキャッシュ上における常駐度を調整す
ることにより、該ディスクキャッシュのヒット率を向上
させ、入出力処理時間を短縮することにある。
Another object of the present invention is to improve the hit rate of the disk cache by adjusting the degree of residence of the block data constituting the file on the disk cache based on the past access characteristics of the file. Another object is to reduce input / output processing time.

【0007】[0007]

【課題を解決するための手段】本発明の第1のディスク
キャッシュ制御方式は、ブロック単位でデータを入出力
するファイルを格納するディスク装置と、前記ファイル
との間で前記データを入出力するユーザプログラム手段
と、前記ファイルと前記ユーザプログラム手段との間で
入出力される前記データを一時的に蓄積するディスクキ
ャッシュメモリと、前記ユーザプログラム手段が入力を
要求する前記データが前記ディスクキャッシュメモリに
格納されている場合には、該データを該ディスクキャッ
シュメモリから読み出して該ユーザプログラム手段に与
え、前記データが前記ディスクキャッシュメモリに格納
されていない場合には、該データを前記ファイルから読
み出して該ユーザプログラム手段に与えるキャッシュ制
御手段とを備えた計算機システムにおいて、前記ファイ
ル中の前記データに対する過去の入出力履歴情報を格納
するファイル情報管理テーブルを備え、前記キャッシュ
制御手段が、さらに、前記入出力履歴情報を参照して、
前記ディスクキャッシュメモリから読み出した前記デー
タが再度入出力される可能性が高いと判断した場合に
は、該データの前記ディスクキャッシュメモリ内におけ
る常駐度を高めることを特徴とする。
According to a first disk cache control method of the present invention, a disk device for storing a file for inputting / outputting data in block units and a user for inputting / outputting the data between the file are provided. Program means, a disk cache memory for temporarily storing the data input / output between the file and the user program means, and the data requested by the user program means to be stored in the disk cache memory If the data has not been stored in the disk cache memory, the data is read from the file and the user program data is read from the file. Cache control means provided to the program means. In calculation system includes a file information management table for storing past output history information for said data in said file, said cache control means further with reference to the input history information,
When it is determined that there is a high possibility that the data read from the disk cache memory is input / output again, the resident degree of the data in the disk cache memory is increased.

【0008】本発明の第2のディスクキャッシュ制御方
式は、第1のディスクキャッシュ制御方式において、前
記キャッシュ制御手段が、さらに、前記入出力履歴情報
を参照して、前記ファイルから読み出した前記データが
再度入出力される可能性が高いと判断した場合には、該
データを前記ディスクキャッシュメモリに格納すること
を特徴とする。
According to a second disk cache control method of the present invention, in the first disk cache control method, the cache control means further refers to the input / output history information and stores the data read from the file. When it is determined that there is a high possibility of input / output again, the data is stored in the disk cache memory.

【0009】本発明の第3のディスクキャッシュ制御方
式は、第1または第2のディスクキャッシュ制御方式に
おいて、前記キャッシュ制御手段が、さらに、前記入出
力履歴情報を参照して、前記ディスクキャッシュメモリ
から読み出した前記データが含まれるファイル内の他の
データについても入出力される可能性が高いと判断した
場合には、該他のデータの前記ディスクキャッシュメモ
リ内における常駐度を高めることを特徴とする。
In a third disk cache control method according to the present invention, in the first or second disk cache control method, the cache control means further refers to the input / output history information to read data from the disk cache memory. If it is determined that there is a high possibility that other data in the file including the read data is also input / output, the resident degree of the other data in the disk cache memory is increased. .

【0010】本発明の第4のディスクキャッシュ制御方
式は、第2または第3のディスクキャッシュ制御方式に
おいて、前記キャッシュ制御手段が、さらに、前記入出
力履歴情報を参照して、前記ファイルから読み出した前
記データが含まれるファイル内の他のデータについても
入出力される可能性が高いと判断した場合には、該他の
データを前記ディスクキャッシュメモリに格納すること
を特徴とする。
According to a fourth disk cache control method of the present invention, in the second or third disk cache control method, the cache control means further reads out from the file with reference to the input / output history information. When it is determined that there is a high possibility that other data in a file including the data is also input / output, the other data is stored in the disk cache memory.

【0011】本発明の第5のディスクキャッシュ制御方
式は、ブロック単位でデータを入出力するファイルを格
納するディスク装置と、前記ファイルとの間で前記デー
タを入出力するユーザプログラム手段と、前記ファイル
と前記ユーザプログラム手段との間で入出力される前記
データを一時的に蓄積するディスクキャッシュメモリ
と、前記ユーザプログラム手段が出力要求した前記デー
タにより置換される前記ファイル上の元データが前記デ
ィスクキャッシュメモリにも格納されている場合には、
前記データにより前記ディスクキャッシュメモリおよび
前記ファイル上の前記元データを置換し、前記元データ
が前記ディスクキャッシュメモリに格納されていない場
合には、前記データにより前記ファイル上の前記元デー
タを置換するキャッシュ制御手段とを備えた計算機シス
テムにおいて、前記ファイル中の前記データに対する過
去の入出力履歴情報を格納するファイル情報管理テーブ
ルを備え、前記キャッシュ制御手段が、前記入出力履歴
情報を参照して、前記ディスクキャッシュメモリ上の前
記元データを置換した前記データが再度入出力される可
能性が高いと判断した場合には、該データの前記ディス
クキャッシュメモリ内における常駐度を高めることを特
徴とする。
According to a fifth disk cache control method of the present invention, there is provided a disk device for storing a file for inputting / outputting data in block units, user program means for inputting / outputting the data to / from the file, A disk cache memory for temporarily storing the data input and output between the user program and the user program, and a disk cache for storing original data on the file replaced by the data requested by the user program for output. If it is also stored in memory,
A cache that replaces the original data on the disk cache memory and the file with the data, and replaces the original data on the file with the data when the original data is not stored in the disk cache memory. A computer system comprising a control unit and a file information management table for storing past input / output history information for the data in the file, wherein the cache control unit refers to the input / output history information, When it is determined that there is a high possibility that the data obtained by replacing the original data on the disk cache memory is input / output again, the degree of residence of the data in the disk cache memory is increased.

【0012】本発明の第6のディスクキャッシュ制御方
式は、第5のディスクキャッシュ制御方式において、前
記キャッシュ制御手段が、さらに、前記入出力履歴情報
を参照して、前記ファイル上の前記元データのみを置換
した前記データが再度入出力される可能性が高いと判断
した場合には、該データを前記ディスクキャッシュメモ
リに書き込むことを特徴とする。
According to a sixth disk cache control method of the present invention, in the fifth disk cache control method, the cache control means further refers to the input / output history information to read only the original data on the file. If it is determined that there is a high possibility that the data obtained by replacing the data is input / output again, the data is written to the disk cache memory.

【0013】本発明の第7のディスクキャッシュ制御方
式は、第5または第6のディスクキャッシュ制御方式に
おいて、前記キャッシュ制御手段が、さらに、前記入出
力履歴情報を参照して、前記ディスクキャッシュメモリ
上の前記元データを置換した前記データが含まれるファ
イル内の他のデータについても入出力される可能性が高
いと判断した場合には、該他のデータの前記ディスクキ
ャッシュメモリ内における常駐度を高めることを特徴と
する。
According to a seventh disk cache control method of the present invention, in the fifth or sixth disk cache control method, the cache control means further refers to the input / output history information and stores the data in the disk cache memory. If it is determined that there is a high possibility that other data in the file including the data that has replaced the original data is input / output, the degree of residence of the other data in the disk cache memory is increased. It is characterized by the following.

【0014】本発明の第8のディスクキャッシュ制御方
式は、第6または第7のディスクキャッシュ制御方式に
おいて、前記キャッシュ制御手段が、さらに、前記入出
力履歴情報を参照して、前記ファイル上の前記元データ
のみを置換した前記データが含まれるファイル内の他の
データについても入出力される可能性が高いと判断した
場合には、該他のデータを前記ディスクキャッシュメモ
リに格納することを特徴とする。
According to an eighth disk cache control system of the present invention, in the sixth or seventh disk cache control system, the cache control means further refers to the input / output history information and When it is determined that there is a high possibility that other data in a file including the data obtained by replacing only the original data is input / output, the other data is stored in the disk cache memory. I do.

【0015】[0015]

【発明の実施の形態】次に本発明の実施の形態について
図面を参照して詳細に説明する。
Embodiments of the present invention will now be described in detail with reference to the drawings.

【0016】図1を参照すると、本発明のディスクキャ
ッシュ制御方式の実施の形態は、ユーザプログラム1
と、ユーザメモリ2と、入出力インタフェース3と、フ
ァイル管理機能4と、キャッシュ制御5と、ファイル情
報管理テーブル6と、ディスクキャッシュメモリ7と、
キャッシュメモリ管理テーブル8と、ディスク装置制御
機能9と、ディスク装置10とから構成される。
Referring to FIG. 1, an embodiment of the disk cache control system of the present invention is a user program 1
A user memory 2, an input / output interface 3, a file management function 4, a cache control 5, a file information management table 6, a disk cache memory 7,
It comprises a cache memory management table 8, a disk device control function 9, and a disk device 10.

【0017】次に、図1を参照して、本発明のディスク
キャッシュ制御方式の実施の形態の動作について詳細に
説明する。
Next, the operation of the embodiment of the disk cache control system of the present invention will be described in detail with reference to FIG.

【0018】ユーザプログラム1は、ディスク装置10
に格納されているファイルの名前と入出力を行うデータ
のファイル内の位置、およびデータ転送を行うユーザメ
モリ2内のアドレスとを指定する入出力命令を入出力イ
ンタフェース3に渡す。
The user program 1 is stored in the disk device 10
To the input / output interface 3 to specify the name of the file stored in the file, the position in the file of the data to be input / output, and the address in the user memory 2 to perform the data transfer.

【0019】入出力インタフェース3は、ユーザプログ
ラム1から受け取った入出力命令の内、ファイルの名前
と該ファイル中のデータ位置とをディスク装置10の中
のブロック番号に変換し、キャッシュ制御機能5に渡
す。ブロック番号とは、ディスク装置10内の領域をあ
る一定の大きさに分割したそれぞれのブロックに昇順に
付された、ディスク装置10内の位置を示す番号であ
る。
The input / output interface 3 converts the name of the file and the data position in the file into the block number in the disk device 10 among the input / output commands received from the user program 1, and sends it to the cache control function 5. hand over. The block number is a number indicating a position in the disk device 10 that is assigned to each block obtained by dividing an area in the disk device 10 into a certain size in ascending order.

【0020】ファイル管理機能4は、個々のファイルを
構成するブロックのディスク装置10上における位置情
報と、入出力要求がどのファイルのどのブロックに対し
てどのような順番で発行されたかを示すアクセス履歴情
報とをファイル情報管理テーブル6内に記憶し、管理す
る。
The file management function 4 includes information on the position of blocks constituting each file on the disk device 10 and an access history indicating an input / output request issued to which block of which file and in which order. The information is stored in the file information management table 6 and managed.

【0021】入出力インタフェース3は、このファイル
情報管理テーブル6に記憶されている情報を、ファイル
管理機能4に問い合わせて得ることができる。
The input / output interface 3 can obtain the information stored in the file information management table 6 by inquiring the file management function 4.

【0022】キャッシュ制御機能5は、入出力インタフ
ェース3から受け取った入出力命令が入力、すなわちフ
ァイルからの読み出しを指示するものである場合には、
読み出すべきブロックのデータがディスクキャッシュメ
モリ7の中に格納されているか否かをキャッシュメモリ
管理テーブル8を参照して判定し、格納されていると判
定した場合には、該当データをディスクキャッシュメモ
リ7から読み出してユーザメモリ2に転送し、ディスク
キャッシュメモリ7中に格納されていないと判定した場
合は、ディスク装置10から該当データを読み出すため
のディスク装置制御命令をディスク装置制御機能9に対
して発行し、読み出したデータをユーザメモリ2に転送
する。
When the input / output command received from the input / output interface 3 is an instruction to input, that is, read from a file, the cache control function 5
It is determined whether or not the data of the block to be read is stored in the disk cache memory 7 by referring to the cache memory management table 8. If it is determined that the data is stored, the corresponding data is stored in the disk cache memory 7. If it is determined that the data is not stored in the disk cache memory 7, a disk device control command for reading the corresponding data from the disk device 10 is issued to the disk device control function 9. Then, the read data is transferred to the user memory 2.

【0023】この際、キャッシュ制御機能5は、ファイ
ル情報管理テーブル6のアクセス履歴情報を参照して、
ディスクキャッシュメモリ7から読み出したデータが再
度アクセスされる可能性が高いと判断した場合には、該
データのディスクキャッシュメモリ7内における常駐度
を高め、再度アクセスされる可能性が高くないと判断し
た場合には、該データのディスクキャッシュメモリ7内
における常駐度はそのままにする。また、ファイル情報
管理テーブル6のアクセス履歴情報を参照して、ディス
ク装置10から読み出したデータが再度アクセスされる
可能性が高いと判断した場合には、該データを該ディス
クキャッシュメモリ7に格納し、再度アクセスされる可
能性が高くないと判断した場合には、該データを該ディ
スクキャッシュメモリ7に格納しない。
At this time, the cache control function 5 refers to the access history information of the file information management table 6 and
If it is determined that the data read from the disk cache memory 7 is likely to be accessed again, the degree of residence of the data in the disk cache memory 7 is increased, and it is determined that the data is not likely to be accessed again. In this case, the resident degree of the data in the disk cache memory 7 is kept as it is. When it is determined that the data read from the disk device 10 is highly likely to be accessed again with reference to the access history information of the file information management table 6, the data is stored in the disk cache memory 7. If it is determined that there is no high possibility of being accessed again, the data is not stored in the disk cache memory 7.

【0024】さらに、キャッシュ制御機能5は、ディス
クキャッシュメモリ7またはディスク装置10から読み
出したデータが含まれるファイルの他のデータについて
もアクセスされる可能性が高いことをファイル情報管理
テーブル6のアクセス履歴情報が示唆している場合に
は、それらの他のデータについてもディスクキャッシュ
メモリ7における常駐度を高めるかまたはディスクキャ
ッシュメモリ7に置くようにする。
Further, the cache control function 5 confirms that there is a high possibility that other data of the file including the data read from the disk cache memory 7 or the disk device 10 will be accessed. If the information suggests, the resident degree of the other data in the disk cache memory 7 is also increased or the other data is stored in the disk cache memory 7.

【0025】キャッシュ制御機能5は、入出力インタフ
ェース3から受け取った入出力命令が出力、すなわちフ
ァイルに対するデータの書き込みを指示するものである
場合には、データを書き込むべきディスク装置10内の
ブロックが、すでにディスクキャッシュメモリ7に格納
されているかどうかをキャッシュメモリ管理テーブル8
を参照して判定し、格納されていると判定した場合に
は、書き込むデータをユーザメモリ2から読み出し、デ
ィスクキャッシュメモリ7に書き込むとともに、該デー
タをディスク装置10上の対応するブロックに書き込む
ため、ディスク制御機能9にディスク装置制御命令を発
行する。
If the input / output command received from the input / output interface 3 is an instruction to output, that is, write data to a file, the cache control function 5 determines whether the block in the disk device 10 to which data is to be written is The cache memory management table 8 determines whether or not the data is already stored in the disk cache memory 7.
When it is determined that the data is stored, the data to be written is read from the user memory 2 and written to the disk cache memory 7 and the data is written to the corresponding block on the disk device 10. A disk device control command is issued to the disk control function 9.

【0026】この際、キャッシュ制御機能5は、ファイ
ル情報管理テーブル6のアクセス履歴情報を参照して、
ディスクキャッシュメモリ7に書き込んだデータが再度
アクセスされる可能性が高いと判断した場合には、該デ
ータのディスクキャッシュメモリ7内における常駐度を
高め、再度アクセスされる可能性が高くないと判断した
場合には、該データのディスクキャッシュメモリ7内に
おける常駐度はそのままにする。
At this time, the cache control function 5 refers to the access history information in the file information management table 6 and
If it is determined that the data written in the disk cache memory 7 is likely to be accessed again, the degree of resident of the data in the disk cache memory 7 is increased, and it is determined that the data is not likely to be accessed again. In this case, the resident degree of the data in the disk cache memory 7 is kept as it is.

【0027】また、データを書き込むべきディスク装置
10内のブロックが、ディスクキャッシュメモリ7に格
納されていないと判定した場合には、ユーザメモリ2か
ら書き込むデータを読み出し、ディスク装置10上の対
応するブロックに書き込むため、ディスク装置制御機能
9にディスク装置制御命令を発行する。
If it is determined that the block in the disk device 10 to which data is to be written is not stored in the disk cache memory 7, the data to be written is read from the user memory 2 and the corresponding block in the disk device 10 is read. Then, a disk device control command is issued to the disk device control function 9 in order to write the data.

【0028】この際、キャッシュ制御機能5は、ファイ
ル情報管理テーブル6のアクセス履歴情報を参照して、
ディスク装置10に書き込んだデータが再度アクセスさ
れる可能性が高いと判断した場合には、該データを該デ
ィスクキャッシュメモリ7に書き込み、再度アクセスさ
れる可能性が高くないと判断した場合には、該データを
該ディスクキャッシュメモリ7に格納しない。
At this time, the cache control function 5 refers to the access history information in the file information management table 6 and
If it is determined that the data written to the disk device 10 is likely to be accessed again, the data is written to the disk cache memory 7 and if it is determined that the possibility of being accessed again is not high, The data is not stored in the disk cache memory 7.

【0029】さらに、キャッシュ制御機能5は、ディス
クキャッシュメモリ7に書き込んだデータが含まれるフ
ァイルの他のデータについてもアクセスされる可能性が
高いことをファイル情報管理テーブル6のアクセス履歴
情報が示唆している場合には、それらの他のデータにつ
いてもディスクキャッシュメモリ7における常駐度を高
めるかまたはディスクキャッシュメモリ7に置くように
する。
Further, the cache control function 5 suggests that the access history information of the file information management table 6 indicates that there is a high possibility that other data of the file including the data written in the disk cache memory 7 will be accessed. In such a case, the resident degree of the other data in the disk cache memory 7 is increased or the other data is stored in the disk cache memory 7.

【0030】[0030]

【実施例】次に、本発明の実施例について図1〜図3を
参照して説明する。
Next, an embodiment of the present invention will be described with reference to FIGS.

【0031】図2はディスク装置上のファイルAに対す
る書き込み要求が発行された場合の実施例を示してい
る。
FIG. 2 shows an embodiment in which a write request for file A on the disk device is issued.

【0032】この実施例においてファイルAは5個のブ
ロックから構成されている。そのブロックはファイルの
先頭から順番にA1・A2・A3・A4・A5であり、
ディスク装置10上に散在している。これら5個のブロ
ックのうち、A1とA2はディスクキャッシュメモリ7
上にデータが格納されており、ディスクキャッシュメモ
リ7のその他の領域は他のファイルのデータによりすべ
て使用されている。
In this embodiment, the file A is composed of five blocks. The blocks are A1, A2, A3, A4, A5 in order from the top of the file,
It is scattered on the disk device 10. Of these five blocks, A1 and A2 are the disk cache memory 7
Data is stored in the upper part, and the other areas of the disk cache memory 7 are all used by data of other files.

【0033】また、ファイル情報管理テーブル6にはフ
ァイルAに対する入出力要求がどのブロックに対してど
のような順番で発行されたかを示すアクセス履歴が過去
の一定回数分記憶されており、該アクセス履歴によれ
ば、ファイルAの各ブロックはそれぞれデータの書き込
みが行われた直後に必ず読み出し要求が発行されている
ことがわかる。
The file information management table 6 stores an access history indicating a certain number of past access histories indicating an input / output request for the file A and in which order the block is issued. According to the above, it is understood that a read request is always issued to each block of the file A immediately after data is written.

【0034】この状態で、ファイルAの中のブロックA
3とA4に対してデータの書き込み要求が発行された場
合を想定する。これらのブロックはディスクキャッシュ
メモリ7に格納されておらず、また過去の一定期間内に
アクセスされたこともないため、現時点での使用頻度は
低いと言うことができる。しかしこの2個のブロックが
属するファイルAの他のブロックについてのアクセス履
歴によれば、あるブロックに対するデータの書き込みが
発生した直後に同じブロックに対する読み出し要求が発
生していることがわかるため、このA3とA4のブロッ
クについても同じように読み出しが要求される可能性が
高いと判断できる。
In this state, block A in file A
It is assumed that a data write request has been issued to Nos. 3 and A4. Since these blocks are not stored in the disk cache memory 7 and have not been accessed within a certain period in the past, it can be said that their use frequency is low at the present time. However, according to the access history of the other blocks of the file A to which the two blocks belong, it can be understood that a read request for the same block has occurred immediately after the writing of data to a certain block has occurred. Similarly, it can be determined that there is a high possibility that reading is requested for the blocks A4 and A4.

【0035】このような、ファイル毎のアクセス履歴が
図1におけるファイル情報管理テーブル6に記憶されて
おり、キャッシュ制御機能5がファイル管理機能4に問
い合わせを行うことにより参照が可能となっている。
Such an access history for each file is stored in the file information management table 6 in FIG. 1, and can be referred to by the cache control function 5 making an inquiry to the file management function 4.

【0036】キャッシュ制御機能5は以上のような判断
に基づいて、書き込み要求のあったブロックA3・A4
のデータをディスク装置に書き込むとともにディスクキ
ャッシュメモリ7内にも格納することを決定し、現在デ
ィスクキャッシュメモリ7内に格納されているブロック
の中で最も使用頻度の低いものを削除し、ブロックA3
およびA4のデータに置換する。
The cache control function 5 determines, based on the above judgment, the blocks A3 and A4 for which a write request has been issued.
Is written to the disk device and is also stored in the disk cache memory 7, and the least frequently used block among the blocks currently stored in the disk cache memory 7 is deleted.
And A4.

【0037】この後、ブロックA3またはA4に対して
データの読み出し要求が発生した場合、これらのブロッ
クのデータはディスクキャッシュメモリ7内に格納され
ているためディスク装置10に対してアクセスを行う必
要がなく、ユーザメモリ2へのデータ転送を高速に行う
ことができる。
Thereafter, when a data read request is issued to the block A3 or A4, it is necessary to access the disk device 10 because the data of these blocks is stored in the disk cache memory 7. Therefore, data transfer to the user memory 2 can be performed at high speed.

【0038】図3は、ディスク装置上のファイルBに対
するデータ読み出し要求が発行された場合の実施例を示
している。
FIG. 3 shows an embodiment in which a data read request for file B on the disk device is issued.

【0039】この実施例においてファイルBは6個のブ
ロックから構成されている。そのブロックはB1・B2
・B3・B4・B5・B6であり、ディスク装置10上
に散在している。これら6個のブロックはすべてディス
クキャッシュメモリ7上にデータが格納されており、ユ
ーザプログラム1からの読み出し要求に対してディスク
装置10へのアクセスを行うことなくデータを転送でき
る状態にある。ただし、ディスクキャッシュメモリ7内
の他のブロックに比べて相対的に長い時間アクセスがな
かったために優先度が下がっており、次に新しいブロッ
クをディスクキャッシュメモリ7内に格納する必要が生
じたときに替わりに削除されるブロックの候補になって
いるものとする。このような情報は図1におけるキャッ
シュメモリ管理テーブル8に格納されている。
In this embodiment, the file B is composed of six blocks. The block is B1, B2
B3, B4, B5, B6, which are scattered on the disk device 10. All of these six blocks have data stored in the disk cache memory 7 and can transfer data without accessing the disk device 10 in response to a read request from the user program 1. However, the priority is lowered because access has not been performed for a relatively long time as compared with other blocks in the disk cache memory 7, and when it becomes necessary to store a new block in the disk cache memory 7 next time, Instead, it is assumed that the block is a candidate for a block to be deleted. Such information is stored in the cache memory management table 8 in FIG.

【0040】ファイル情報管理テーブル6には、ファイ
ルBに対して発行された入出力要求であるアクセス履歴
が過去一定回数分記憶されており、それによるとファイ
ルBに対する入出力要求はすべてデータの読み出し要求
であり、かつファイルの先頭のブロックであるB1から
最終ブロックであるB6までの順次アクセスになってい
ることがわかる。
The file information management table 6 stores an access history as an input / output request issued to the file B for a fixed number of times in the past. It can be seen that the request is a request and the access is sequentially from B1 which is the first block of the file to B6 which is the last block.

【0041】この状態で、ファイルBの中のブロックB
1に対してデータの読み出し要求が発行された場合を想
定する。ブロックB1はディスクキャッシュメモリ7内
にデータが存在するため、ディスク装置10へのアクセ
スを行うことなくユーザメモリ2にデータを転送するこ
とができる。同時に、それまで使用頻度が低かったため
に削除されるブロックの候補となっていたB1に対する
アクセスがあったためキャッシュ制御機能5はB1の優
先度を上げる。
In this state, block B in file B
Assume that a data read request has been issued for No. 1. Since the block B1 has data in the disk cache memory 7, the data can be transferred to the user memory 2 without accessing the disk device 10. At the same time, the cache control function 5 raises the priority of B1 because there has been access to B1 which has been a candidate for a block to be deleted because of its low usage frequency.

【0042】さらにキャッシュ制御機能5は、ファイル
管理機能4に問い合わせることによりファイルBに対す
るデータ読み出し要求がファイルの先頭のブロックから
の順次アクセスにより行われる可能性が高いことを知
り、ファイルBの残りのブロックであるB2〜B6に対
しても近いうちに読み出し要求が発行されると判断す
る。その結果、ブロックB2〜B6に対するアクセスが
まだ発生しないうちに、キャッシュメモリ管理テーブル
8の情報を更新し、ブロックB2〜B6の優先度を上
げ、ディスクキャッシュメモリ7からすぐには削除され
ないようにしておく。
Further, the cache control function 5 inquires of the file management function 4 that the data read request for the file B is highly likely to be made by sequential access from the first block of the file, and the remaining of the file B is It is determined that a read request will be issued to the blocks B2 to B6 soon. As a result, before access to the blocks B2 to B6 has not yet occurred, the information in the cache memory management table 8 is updated, and the priority of the blocks B2 to B6 is increased so that the blocks B2 to B6 are not immediately deleted from the disk cache memory 7. deep.

【0043】この後、ファイルBに対して順次アクセス
が行われ、ブロックB2〜B6に対してデータの読み出
し要求が発生すれば、それらのブロックは高い確率でま
だディスクキャッシュメモリ7内に格納されたままにな
っているため、ディスク装置10へのアクセスを行うこ
となくユーザメモリ2へのデータ転送を高速に行うこと
が可能となる。
Thereafter, if the file B is sequentially accessed and a data read request is issued to the blocks B2 to B6, those blocks are still stored in the disk cache memory 7 with a high probability. Since it is left as it is, data transfer to the user memory 2 can be performed at high speed without accessing the disk device 10.

【0044】[0044]

【発明の効果】以上説明したように、本発明は、ファイ
ルの過去のアクセス特性に基づいて、該ファイルを構成
するブロックデータのディスクキャッシュ上における常
駐度を調整することにより、該ディスクキャッシュのヒ
ット率を向上させ、入出力処理時間を短縮することがで
きる効果を有している。
As described above, the present invention adjusts the resident level of the block data constituting a file on the disk cache based on the past access characteristics of the file, thereby achieving the hit of the disk cache. This has the effect of improving the rate and shortening the input / output processing time.

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

【図1】本発明の実施の形態を示すブロック図である。FIG. 1 is a block diagram showing an embodiment of the present invention.

【図2】本発明の実施例においてディスク装置上のファ
イルに対するデータ書き込み要求が発行された場合の処
理を説明するための図である。
FIG. 2 is a diagram for explaining processing when a data write request for a file on a disk device is issued in the embodiment of the present invention.

【図3】本発明の実施例においてディスク装置上のファ
イルに対するデータ読み出し要求が発行された場合の処
理を説明するための図である。
FIG. 3 is a diagram for explaining processing when a data read request for a file on a disk device is issued in the embodiment of the present invention.

【符号の説明】[Explanation of symbols]

1 ユーザプログラム 2 ユーザメモリ 3 入出力インタフェース 4 ファイル管理機能 5 キャッシュ制御機能 6 ファイル情報管理テーブル 7 ディスクキャッシュメモリ 8 キャッシュメモリ管理テーブル 9 ディスク装置制御機能 10 ディスク装置 DESCRIPTION OF SYMBOLS 1 User program 2 User memory 3 I / O interface 4 File management function 5 Cache control function 6 File information management table 7 Disk cache memory 8 Cache memory management table 9 Disk unit control function 10 Disk unit

Claims (8)

【特許請求の範囲】[Claims] 【請求項1】 ブロック単位でデータを入出力するファ
イルを格納するディスク装置と、 前記ファイルとの間で前記データを入出力するユーザプ
ログラム手段と、 前記ファイルと前記ユーザプログラム手段との間で入出
力される前記データを一時的に蓄積するディスクキャッ
シュメモリと、 前記ユーザプログラム手段が入力を要求する前記データ
が前記ディスクキャッシュメモリに格納されている場合
には、該データを該ディスクキャッシュメモリから読み
出して該ユーザプログラム手段に与え、前記データが前
記ディスクキャッシュメモリに格納されていない場合に
は、該データを前記ファイルから読み出して該ユーザプ
ログラム手段に与えるキャッシュ制御手段とを備えた計
算機システムにおいて、 前記ファイル中の前記データに対する過去の入出力履歴
情報を格納するファイル情報管理テーブルを備え、 前記キャッシュ制御手段が、さらに、 前記入出力履歴情報を参照して、前記ディスクキャッシ
ュメモリから読み出した前記データが再度入出力される
可能性が高いと判断した場合には、該データの前記ディ
スクキャッシュメモリ内における常駐度を高めることを
特徴とするディスクキャッシュ制御方式。
1. A disk device for storing a file for inputting / outputting data in block units, a user program unit for inputting / outputting the data to / from the file, and an input / output between the file and the user program unit. A disk cache memory for temporarily storing the data to be output, and, if the data requested by the user program means to be input is stored in the disk cache memory, read the data from the disk cache memory Wherein the data is not stored in the disk cache memory, the data is read from the file and the cache control means is provided to the user program means. For the data in the file A file information management table for storing past input / output history information, wherein the cache control unit can further input / output the data read from the disk cache memory with reference to the input / output history information A disk cache control method for increasing the degree of resident of the data in the disk cache memory when it is determined that the data is high.
【請求項2】 前記キャッシュ制御手段が、さらに、 前記入出力履歴情報を参照して、前記ファイルから読み
出した前記データが再度入出力される可能性が高いと判
断した場合には、該データを前記ディスクキャッシュメ
モリに格納することを特徴とする請求項1記載のディス
クキャッシュ制御方式。
2. When the cache control unit further determines that the data read from the file is highly likely to be input / output again with reference to the input / output history information, the cache control unit deletes the data. 2. The disk cache control method according to claim 1, wherein the data is stored in the disk cache memory.
【請求項3】 前記キャッシュ制御手段が、さらに、 前記入出力履歴情報を参照して、前記ディスクキャッシ
ュメモリから読み出した前記データが含まれるファイル
内の他のデータについても入出力される可能性が高いと
判断した場合には、該他のデータの前記ディスクキャッ
シュメモリ内における常駐度を高めることを特徴とする
請求項1または請求項2記載のディスクキャッシュ制御
方式。
3. The cache control unit may further refer to the input / output history information to input / output other data in a file including the data read from the disk cache memory. 3. The disk cache control method according to claim 1, wherein when it is determined to be high, the resident degree of the other data in the disk cache memory is increased.
【請求項4】 前記キャッシュ制御手段が、さらに、 前記入出力履歴情報を参照して、前記ファイルから読み
出した前記データが含まれるファイル内の他のデータに
ついても入出力される可能性が高いと判断した場合に
は、該他のデータを前記ディスクキャッシュメモリに格
納することを特徴とする請求項2または請求項3記載の
ディスクキャッシュ制御方式。
4. The method according to claim 1, wherein the cache control unit further refers to the input / output history information and has a high possibility of inputting / outputting other data in a file including the data read from the file. 4. The disk cache control method according to claim 2, wherein when the determination is made, the other data is stored in the disk cache memory.
【請求項5】 ブロック単位でデータを入出力するファ
イルを格納するディスク装置と、 前記ファイルとの間で前記データを入出力するユーザプ
ログラム手段と、 前記ファイルと前記ユーザプログラム手段との間で入出
力される前記データを一時的に蓄積するディスクキャッ
シュメモリと、 前記ユーザプログラム手段が出力要求した前記データに
より置換される前記ファイル上の元データが前記ディス
クキャッシュメモリにも格納されている場合には、前記
データにより前記ディスクキャッシュメモリおよび前記
ファイル上の前記元データを置換し、前記元データが前
記ディスクキャッシュメモリに格納されていない場合に
は、前記データにより前記ファイル上の前記元データを
置換するキャッシュ制御手段とを備えた計算機システム
において、 前記ファイル中の前記データに対する過去の入出力履歴
情報を格納するファイル情報管理テーブルを備え、 前記キャッシュ制御手段が、さらに、 前記入出力履歴情報を参照して、前記ディスクキャッシ
ュメモリ上の前記元データを置換した前記データが再度
入出力される可能性が高いと判断した場合には、該デー
タの前記ディスクキャッシュメモリ内における常駐度を
高めることを特徴とするディスクキャッシュ制御方式。
5. A disk device for storing a file for inputting / outputting data in block units, user program means for inputting / outputting the data to / from the file, and input / output between the file and the user program means. A disk cache memory for temporarily storing the output data; and a case where the original data on the file replaced by the data requested by the user program means is also stored in the disk cache memory. Replacing the original data on the disk cache memory and the file with the data, and replacing the original data on the file with the data if the original data is not stored in the disk cache memory. Computer system with cache control means A file information management table for storing past input / output history information for the data in the file, wherein the cache control unit further refers to the input / output history information, and A disk cache control method, wherein when it is determined that there is a high possibility that the data obtained by replacing the original data is input / output again, the resident degree of the data in the disk cache memory is increased.
【請求項6】 前記キャッシュ制御手段が、さらに、 前記入出力履歴情報を参照して、前記ファイル上の前記
元データのみを置換した前記データが再度入出力される
可能性が高いと判断した場合には、該データを前記ディ
スクキャッシュメモリに書き込むことを特徴とする請求
項5記載のディスクキャッシュ制御方式。
6. When the cache control unit further determines with reference to the input / output history information that the data obtained by replacing only the original data on the file is likely to be input / output again. 6. The disk cache control method according to claim 5, wherein said data is written to said disk cache memory.
【請求項7】 前記キャッシュ制御手段が、さらに、 前記入出力履歴情報を参照して、前記ディスクキャッシ
ュメモリ上の前記元データを置換した前記データが含ま
れるファイル内の他のデータについても入出力される可
能性が高いと判断した場合には、該他のデータの前記デ
ィスクキャッシュメモリ内における常駐度を高めること
を特徴とする請求項5または請求項6記載のディスクキ
ャッシュ制御方式。
7. The cache control unit further refers to the input / output history information to input / output other data in a file including the data obtained by replacing the original data on the disk cache memory. 7. The disk cache control method according to claim 5, wherein when it is determined that there is a high possibility that the data is deleted, the resident degree of the other data in the disk cache memory is increased.
【請求項8】 前記キャッシュ制御手段が、さらに、 前記入出力履歴情報を参照して、前記ファイル上の前記
元データのみを置換した前記データが含まれるファイル
内の他のデータについても入出力される可能性が高いと
判断した場合には、該他のデータを前記ディスクキャッ
シュメモリに格納することを特徴とする請求項6または
請求項7記載のディスクキャッシュ制御方式。
8. The cache control unit further refers to the input / output history information to input / output other data in a file including the data obtained by replacing only the original data in the file. 8. The disk cache control method according to claim 6, wherein the other data is stored in the disk cache memory when it is determined that there is a high possibility that the data is stored.
JP08319624A 1996-11-29 1996-11-29 Disk cache control method Expired - Fee Related JP3111912B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP08319624A JP3111912B2 (en) 1996-11-29 1996-11-29 Disk cache control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP08319624A JP3111912B2 (en) 1996-11-29 1996-11-29 Disk cache control method

Publications (2)

Publication Number Publication Date
JPH10161932A true JPH10161932A (en) 1998-06-19
JP3111912B2 JP3111912B2 (en) 2000-11-27

Family

ID=18112366

Family Applications (1)

Application Number Title Priority Date Filing Date
JP08319624A Expired - Fee Related JP3111912B2 (en) 1996-11-29 1996-11-29 Disk cache control method

Country Status (1)

Country Link
JP (1) JP3111912B2 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002056648A (en) * 1998-06-27 2002-02-22 Samsung Electronics Co Ltd Device and method for recording and reproducing optical disk
US6959359B1 (en) 1999-07-14 2005-10-25 Hitachi, Ltd. Software prefetch system and method for concurrently overriding data prefetched into multiple levels of cache
JP2006012126A (en) * 2004-06-10 2006-01-12 Marvell World Trade Ltd Adaptative storage system
US20140033311A1 (en) * 2012-07-19 2014-01-30 Tencent Technology (Shenzhen) Company Limited Method and apparatus for determining virus-infected files
WO2019123519A1 (en) * 2017-12-18 2019-06-27 三菱電機株式会社 Information processing device, information processing method, and information processing program

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002056648A (en) * 1998-06-27 2002-02-22 Samsung Electronics Co Ltd Device and method for recording and reproducing optical disk
US6959359B1 (en) 1999-07-14 2005-10-25 Hitachi, Ltd. Software prefetch system and method for concurrently overriding data prefetched into multiple levels of cache
JP2006012126A (en) * 2004-06-10 2006-01-12 Marvell World Trade Ltd Adaptative storage system
US20140033311A1 (en) * 2012-07-19 2014-01-30 Tencent Technology (Shenzhen) Company Limited Method and apparatus for determining virus-infected files
US9268939B2 (en) * 2012-07-19 2016-02-23 Tencent Technology (Shenzhen) Company Limited Method and apparatus for determining virus-infected files
WO2019123519A1 (en) * 2017-12-18 2019-06-27 三菱電機株式会社 Information processing device, information processing method, and information processing program

Also Published As

Publication number Publication date
JP3111912B2 (en) 2000-11-27

Similar Documents

Publication Publication Date Title
KR100951107B1 (en) Method for managing files for optimal performance
US7350017B2 (en) Magnetic disk unit, file management system, and file management method
RU2451993C2 (en) Prolonging service life of flash-memory
US5734861A (en) Log-structured disk array with garbage collection regrouping of tracks to preserve seek affinity
JP4988215B2 (en) Adaptive flash memory controller employing multiple mapping techniques and flash memory system including the same
KR101663667B1 (en) Method and apparatus for data management in flash memory by address mapping
US20030217080A1 (en) System and method for intelligent write management of disk pages in cache checkpoint operations
JPH09259033A (en) Buffer write method
JP2531907B2 (en) Buffer memory management method and device for permitting division
JPH0772989A (en) Method for cleaning-up of solid-state memory disk for storing of floating sector data
WO2005124530A2 (en) Method for controlling memory card and method for controlling nonvolatile semiconductor memory
US7032093B1 (en) On-demand allocation of physical storage for virtual volumes using a zero logical disk
JPH07334310A (en) Disk device and buffer storage control method for read data of the same
JP4461089B2 (en) Storage control apparatus and storage control method
JP3111912B2 (en) Disk cache control method
US6532513B1 (en) Information recording and reproduction apparatus
JPH08263380A (en) Disk cache control system
US6763446B1 (en) Systems and methods for handling storage access requests
JP3969809B2 (en) Data buffer management method in storage device
JPH11327802A (en) Disk system
JPH0934791A (en) Information storage device
KR100541642B1 (en) Data managing device and method thereof
JPS5918786B2 (en) Hierarchical memory system
US20060020751A1 (en) Medium storage device, cache segment switching method for medium storage device, and medium storage system
WO1984002016A1 (en) Dynamic addressing for variable track length cache memory

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20000822

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080922

Year of fee payment: 8

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080922

Year of fee payment: 8

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090922

Year of fee payment: 9

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090922

Year of fee payment: 9

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100922

Year of fee payment: 10

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110922

Year of fee payment: 11

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120922

Year of fee payment: 12

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130922

Year of fee payment: 13

LAPS Cancellation because of no payment of annual fees