JPH0498542A - File control system - Google Patents

File control system

Info

Publication number
JPH0498542A
JPH0498542A JP2216663A JP21666390A JPH0498542A JP H0498542 A JPH0498542 A JP H0498542A JP 2216663 A JP2216663 A JP 2216663A JP 21666390 A JP21666390 A JP 21666390A JP H0498542 A JPH0498542 A JP H0498542A
Authority
JP
Japan
Prior art keywords
area
file
total value
requested
free space
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2216663A
Other languages
Japanese (ja)
Inventor
Hiroya Kawada
川田 裕哉
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 JP2216663A priority Critical patent/JPH0498542A/en
Publication of JPH0498542A publication Critical patent/JPH0498542A/en
Pending legal-status Critical Current

Links

Landscapes

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

Abstract

PURPOSE:To secure an area covering plural idle areas without performing the rearrangement of these areas by securing a file area with an area securing means when the total value of idle areas is equal to or larger than the size of a requested file. CONSTITUTION:A comparison means 13 compares the total value calculated by a total value calculation means 12 with the size of a requested file and decides whether the total value of idle areas is larger than the file size or not. If so, a continuity deciding means 14 decides whether the requested file size is secured in the continuous areas or not. If so, an area securing means 15 secures an area out of one of cointinuous idle areas in the same system as the conventional one to complete a processing.

Description

【発明の詳細な説明】 〔産業上の利用分野] 本発明は電子計算機システムにおけるファイル管理方式
に関するものである。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a file management method in a computer system.

〔従来の技術〕[Conventional technology]

ハードディスクやフロンビイディスク等の記憶媒体上の
記憶領域にファイルを作成する場合、従来は次のように
して領域の確保が行われていた。
When creating a file in a storage area on a storage medium such as a hard disk or a Freonbi disk, the area has conventionally been secured in the following manner.

■確保要求のあったファイルサイズと等しいか大きい連
続した空領域が存在するか否かをチエツクする。
■Check whether there is a continuous empty area that is equal to or larger than the requested file size.

■存在する場合はその空領域の先頭から確保要求のあっ
たファイルサイズ分だけ領域を確保する。
■If it exists, allocate an area corresponding to the requested file size from the beginning of the empty area.

■連続した空領域が存在しない場合であって、飛び飛び
の空領域の合計が確保要求のあったファイルサイズと等
しいか大きい場合には、記憶領域の再配置(ファイルの
格納位置をずらして複数の空領域を1つにまとめる処理
)を行い、上記の■の処理を再び行う。
■If there is no contiguous free space and the total free space at random is equal to or larger than the requested file size, relocation of the storage area (shifting the storage location of the file to create multiple Then, the above process (2) is performed again.

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

上述したように、従来は確保要求のあったファイルサイ
ズと等しいか大きい連続した空領域が存在しない場合に
は記憶領域の再配置が必要となり、記憶媒体の記憶容量
が大きい場合には再配置の処理に時間がかかり、ファイ
ル作成が円滑に行えないという欠点があった。なお、フ
ァイル領域の確保・開放を繰り返すことにより飛び飛び
の空領域が発生することは避けることができず、再配置
を行う頻度も高いことから、その対策は重要な課題であ
る。
As mentioned above, in the past, if there was no contiguous free space equal to or larger than the requested file size, it was necessary to relocate the storage area, and if the storage capacity of the storage medium was large, relocation was required. The drawback is that processing takes time and file creation cannot be performed smoothly. Note that it is unavoidable that empty areas will occur at random due to repeated allocation and release of file areas, and relocation is frequently performed, so countermeasures are an important issue.

本発明は上記の点に鑑み提案されたものであり、その目
的とするところは、再配置を行うことなく複数の空領域
にまたがって領域を確保することのできるファイル管理
方式を提供することにある。
The present invention has been proposed in view of the above points, and its purpose is to provide a file management method that can secure an area across multiple empty areas without relocation. be.

[課題を解決するための手段〕 本発明は上記の目的を達成するため、記憶領域に散在す
る空領域を調査する空領域調査手段と、調査した空領域
の合計値を計算する合計値計算手段と、 計算した合計値と確保要求のあったファイルサイズとを
比較する比較手段と、 空領域の合計値が確保要求のあったファイルサイズと等
しいか大きい場合にファイル領域を確保する領域確保手
段とを備えるようにしている。
[Means for Solving the Problems] In order to achieve the above object, the present invention provides empty area investigating means for investigating empty areas scattered in a storage area, and total value calculation means for calculating the total value of the investigated empty areas. , a comparison means for comparing the calculated total value and the file size requested to be allocated, and an area reservation means for allocating the file area when the total value of free space is equal to or larger than the file size requested to be allocated. I am trying to prepare for this.

〔作用] 本発明のファイル管理方式にあっては、空領域調査手段
が記憶領域に散在する空領域を調査し、調査した空領域
の合計値を合計値計算手段が計算し、計算した合計値と
確保要求のあったファイルサイズとを比較手段が比較し
、空領域の合計値が確保要求のあったファイルサイズと
等しいか大きい場合に領域確保手段がファイル領域を確
保する。
[Operation] In the file management method of the present invention, the empty area investigating means investigates the empty areas scattered in the storage area, the total value calculating means calculates the total value of the investigated empty areas, and the calculated total value is calculated. The comparison means compares the file size for which the reservation request has been made, and if the total value of the free space is equal to or larger than the file size for which the reservation request has been made, the area reservation means secures the file area.

〔実施例] 以下、本発明の実施例につき図面を参照して説明する。〔Example] Embodiments of the present invention will be described below with reference to the drawings.

第1図は本発明のファイル管理方式を適用したファイル
管理システムの一実施例を示す構成図である。
FIG. 1 is a block diagram showing an embodiment of a file management system to which the file management method of the present invention is applied.

第1図において、ファイル管理ンステム1は、記憶領域
に散在する空領域を調査する空領域調査手段11と、調
査した空領域の合計値を計算する合計値計算手段12と
、計算した合計値と確保要求のあったファイルサイズと
を比較する比較手段13と、空領域の合計値が確保要求
のあったファイルサイズと等しいか大きい場合に空領域
が確保要求のあったファイルサイズ分だけ連続している
か否かを判別する連続性判別手段14と、空領域の合計
値が確保要求のあったファイルサイズと等しいか大きい
場合であって、連続している場合には連続した1つの空
領域内で領域を確保し、連続していない場合には複数の
空領域にまたがって領域を確保する領域確保手段15と
を含んでいる。
In FIG. 1, the file management system 1 includes an empty area investigating means 11 that investigates empty areas scattered in a storage area, a total value calculating means 12 that calculates the total value of the investigated empty areas, and a calculated total value. Comparison means 13 that compares the size of the file requested to be allocated, and if the total value of free space is equal to or larger than the file size requested to be allocated, the free space is continuously equal to the size of the file requested to be allocated. If the total value of the free space is equal to or larger than the file size requested to be secured, and if the total value of the free space is equal to or larger than the file size requested to be secured, and if the file size is continuous, the continuous free space is It includes an area securing means 15 that secures an area and, if the area is not continuous, secures the area across a plurality of empty areas.

第2図は第1図に示した実施例の処理を示すフローチャ
ートであり、以下、第1図および第2図に沿って実施例
の動作を説明する。
FIG. 2 is a flowchart showing the processing of the embodiment shown in FIG. 1, and the operation of the embodiment will be explained below with reference to FIGS. 1 and 2.

第2図において、ファイル作成のために領域の確保要求
が行われると処理が開始する。
In FIG. 2, processing begins when a request to secure an area for file creation is made.

先ず、空領域調査手段11は媒体内すべての空領域を調
査する(ステップSl)。具体的には記憶媒体毎に設け
られたファイル管理領域を参照して調査を行う。
First, the empty area investigating means 11 investigates all empty areas within the medium (step Sl). Specifically, the investigation is performed by referring to the file management area provided for each storage medium.

次いで、合計値計算手段12はすべての空領域の合計値
を計算する(ステップS2)。
Next, the total value calculation means 12 calculates the total value of all empty areas (step S2).

次いで、比較手段13は合計値計算手段12で計算され
た合計値と確保要求されたファイルサイズとを比較し、
空領域の合計値が確保要求されたファイルサイズ以上で
あるか否かを判断する(ステップS3)、ここで、空領
域の合計値が確保要求されたファイルサイズ未満の場合
(ステップS3のNo)には、領域の確保は不可能であ
るとして処理を終了する。
Next, the comparison means 13 compares the total value calculated by the total value calculation means 12 and the file size requested to be secured,
Determine whether the total value of free space is greater than or equal to the file size requested to be secured (step S3); here, if the total value of free space is less than the file size requested to be secured (No in step S3) In this case, it is assumed that it is impossible to secure the area, and the process is terminated.

一方、空領域の合計値が確保要求されたファイルサイズ
以上である場合(ステップS3のYES)には、連続性
判別手段14は連続した領域で要求されたファイルサイ
ズが確保できるか否かを判別する(ステップS4)。
On the other hand, if the total value of free space is greater than or equal to the requested file size (YES in step S3), the continuity determining means 14 determines whether the requested file size can be secured in a continuous area or not. (Step S4).

連続している場合(ステップS4のYES)には、領域
確保手段15はその連続した1つの空領域内で従来と同
様の方式〇こより領域を確保しくステップS6)、処理
を終了する。
If they are continuous (YES in step S4), the area securing means 15 secures the area in the same continuous empty area in the same manner as the conventional method (step S6), and ends the process.

また、領域が連続していない場合(ステップS4のNo
)には、複数の空領域にまたがって1つのファイルとし
て領域を確保しくステップS5)、処理を終了する。
Also, if the areas are not continuous (No in step S4),
), an area is secured as one file across a plurality of empty areas. At step S5), the process ends.

次に、第3図および第4図は領域の確保の手法を具体的
に示したものであり、2はハードディスクやフロッピィ
ディスク等の記憶媒体上の記憶領域、21は記憶領域2
の先頭部分に媒体毎に設けられたファイル管理領域であ
る。
Next, FIGS. 3 and 4 specifically show the method of securing an area, where 2 is a storage area on a storage medium such as a hard disk or floppy disk, and 21 is a storage area 2.
This is a file management area provided for each medium at the beginning of the file.

第3図において、記憶領域2には、物理アドレス1〜3
までにファイルA1物理アドレス6〜7までにファイル
B、物理アドレス9〜9にファイルCがそれぞれ格納さ
れ、他の部分(ファイル管理領域21を除く)は空領域
a、b、cであり、この場合、ファイル管理領域21に
はファイル名毎に各領域の開始位置と終了位置の物理ア
ドレスが登録されるようになっている。なお、開始位置
および終了位置は複数登録可能となっており、°“0゛
はこれ以上分割されていないことを示している。
In FIG. 3, storage area 2 contains physical addresses 1 to 3.
Until now, file B has been stored in file A1 physical addresses 6 to 7, and file C has been stored in physical addresses 9 to 9, and the other parts (excluding the file management area 21) are empty areas a, b, and c. In this case, the physical addresses of the start and end positions of each area are registered in the file management area 21 for each file name. Note that a plurality of start positions and end positions can be registered, and ``0'' indicates that there is no further division.

今、第3図の状態でファイルサイズが“′3゛の新たな
ファイルDの領域の確保が要求されると、空領域調査手
段11(第1図参照)はファイル管理領域21の情報か
ら空領域a、b、cを認識し、合計値計算手段12は記
憶領域2の全体のサイズ“10”を考慮して空領域a、
b、cの合計値“′4”を算出する。
Now, in the state shown in FIG. 3, when a request is made to secure an area for a new file D with a file size of The total value calculation means 12 recognizes the areas a, b, and c, and calculates the empty areas a, taking into account the entire size of the storage area 2 "10".
The total value of b and c is calculated as "'4".

従って、比較手段13が合計値計算手段12で計算され
た合計値“′4”と確保要求されたファイルサイズ“3
”とを比較すると空領域の合計値の方が大きいため、領
域確保可能と判断する。
Therefore, the comparison means 13 compares the total value "'4" calculated by the total value calculation means 12 with the requested file size "3".
”, the total value of empty space is larger, so it is determined that the space can be secured.

更に、連続性判別手段14は空領域a、b、cが確保要
求されたファイルサイズ°°3゛にわたって連続してい
るか否かを調べるが、連続しているのは空領域aの′2
”が最大であるため、連続していないと判断する。
Furthermore, the continuity determining means 14 checks whether empty areas a, b, and c are continuous over the requested file size °°3, but only empty area '2' of empty area a is continuous.
” is the maximum, so it is determined that they are not consecutive.

従って、領域確保手段15は空領域a、bをファイルD
に割り当てるものとし、空領域aの先頭の物理アドレス
“4“をファイルDの第1分割部分の開始位置、空領域
aの後尾の物理アドレス“′5“をファイルDの第1分
割部分の終了位置、空領域すの先頭の物理アドレス゛8
”をファイルDの第2分割部分の開始位1、空領域すの
後尾の物理アドレス“8”をファイルDの第2分割部分
の終了位1として、第4図に示すように、ファイル管理
領域21に登録する。
Therefore, the area securing means 15 stores the empty areas a and b in the file D.
The physical address "4" at the beginning of empty area a is the start position of the first divided part of file D, and the physical address "'5" at the end of empty area a is the end position of the first divided part of file D. Position, physical address of the beginning of the empty area ゛8
” is the start position 1 of the second divided part of the file D, and the physical address "8" at the end of the empty area is the end position 1 of the second divided part of the file D, as shown in FIG. 4, the file management area is Register on 21.

実際に記憶領域2にアクセスする手段(図示せず)はフ
ァイル管理領域21の情報に従い、分割されたファイル
Dに対して連続した領域と同様にアクセスを行う。
A means (not shown) for actually accessing the storage area 2 accesses the divided file D in the same way as a continuous area, according to the information in the file management area 21.

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

以上説明したように、本発明のファイル管理方式にあっ
ては、連続した空領域が存在しない場合でも、飛び飛び
の空領域の合計が確保要求のあったファイルサイズと等
しいか大きい場合にけ、再配置を行うことなく領域を確
保できるため、処理時間を大幅に短縮することができ、
処理効率を高めることができる効果がある。
As explained above, in the file management method of the present invention, even if there is no contiguous empty area, if the total of discrete empty areas is equal to or larger than the file size requested to be allocated, replay is performed. Since the area can be secured without any placement, processing time can be significantly reduced.
This has the effect of increasing processing efficiency.

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

第1図は本発明のファイル管理方式を適用したファイル
管理システムの一実施例を示す構成図、第2図は実施例
の処理を示すフローチャート、第3図および第4図は記
憶領域の説明図である。 図において、 1・・・・・・・・・ファイル管理システム11・・・
・・・空領域調査手段 12・・・・・・合計値計算手段 I3・・・・・・比較手段 14・・・・・・連続性判別手段 15・・・・・・領域確保手段 2・・・・・・・・・記憶領域 21・・・・・・ファイル管理領域 笑施伊1の構19.図 処理のフロー子マート
FIG. 1 is a block diagram showing an embodiment of a file management system to which the file management method of the present invention is applied, FIG. 2 is a flowchart showing the processing of the embodiment, and FIGS. 3 and 4 are explanatory diagrams of storage areas. It is. In the figure, 1... File management system 11...
... Sky area investigation means 12 ... Total value calculation means I3 ... Comparison means 14 ... Continuity determination means 15 ... Area securing means 2. ......Storage area 21...File management area 1 structure 19. Diagram processing flow child mart

Claims (3)

【特許請求の範囲】[Claims] (1)記憶領域に散在する空領域を調査する空領域調査
手段と、 調査した空領域の合計値を計算する合計値計算手段と、 計算した合計値と確保要求のあったファイルサイズとを
比較する比較手段と、 空領域の合計値が確保要求のあったファイルサイズと等
しいか大きい場合にファイル領域を確保する領域確保手
段とを備えたことを特徴とするファイル管理方式。
(1) Compare the free space investigation means that investigates the free space scattered in the storage area, the total value calculation means that calculates the total value of the investigated free space, and the calculated total value and the file size that was requested to be secured. A file management method characterized by comprising a comparison means for determining the file size, and an area reservation means for securing the file area when the total value of free space is equal to or larger than the file size requested to be secured.
(2)空領域の合計値が確保要求のあったファイルサイ
ズと等しいか大きい場合に、空領域が確保要求のあった
ファイルサイズ分だけ連続しているか否かを判別し、連
続している場合には連続した1つの空領域内で領域を確
保し、連続していない場合には複数の空領域にまたがっ
て領域を確保することを特徴とする請求項1記載のファ
イル管理方式。
(2) If the total value of free space is equal to or larger than the file size requested to be allocated, determine whether the free space is continuous by the size of the file requested to be allocated, and if it is continuous. 2. The file management system according to claim 1, wherein the area is secured within one continuous empty area, and when the area is not continuous, the area is secured across a plurality of empty areas.
(3)ファイル管理領域に、ファイル毎に分割された部
分の開始位置および終了位置を登録することにより領域
の確保を行うことを特徴とした請求項1または2記載の
ファイル管理方式。
(3) The file management method according to claim 1 or 2, wherein the area is secured by registering in the file management area the start and end positions of the parts divided for each file.
JP2216663A 1990-08-17 1990-08-17 File control system Pending JPH0498542A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2216663A JPH0498542A (en) 1990-08-17 1990-08-17 File control system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2216663A JPH0498542A (en) 1990-08-17 1990-08-17 File control system

Publications (1)

Publication Number Publication Date
JPH0498542A true JPH0498542A (en) 1992-03-31

Family

ID=16691980

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2216663A Pending JPH0498542A (en) 1990-08-17 1990-08-17 File control system

Country Status (1)

Country Link
JP (1) JPH0498542A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07334398A (en) * 1994-06-14 1995-12-22 Nippon Denki Joho Service Kk Method and device for automatically extending file
JP2013210749A (en) * 2012-03-30 2013-10-10 Fujitsu Ltd Program, control method, storage device, and system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07334398A (en) * 1994-06-14 1995-12-22 Nippon Denki Joho Service Kk Method and device for automatically extending file
JP2013210749A (en) * 2012-03-30 2013-10-10 Fujitsu Ltd Program, control method, storage device, and system

Similar Documents

Publication Publication Date Title
US8443163B1 (en) Methods, systems, and computer readable medium for tier-based data storage resource allocation and data relocation in a data storage array
US6760826B2 (en) Store data in the system memory of a computing device
JP3708195B2 (en) How to avoid over-allocation of virtual capacity in data storage systems
EP0703526A2 (en) Storage management system for concurrent generation and fair allocation of disk space
US20150347321A1 (en) Parallel block allocation for declustered logical disks
JPH0498542A (en) File control system
US5918243A (en) Computer mechanism for reducing DASD arm contention during parallel processing
JPH09223049A (en) Disk array system
Estivill-Castro et al. Foundations for faster external sorting
US20090327640A1 (en) Method for expanding logical volume storage space
US20110283080A1 (en) Apparatus and method for managing memory
US11599391B2 (en) Memory transaction request management for an ordered unit of data items
JP3468181B2 (en) Distributed data processing apparatus, data storage method, load distribution method, and recording medium
JPH07120250B2 (en) Allocation method of parallel disk control buffer
JP2833814B2 (en) I / O buffer allocation method
JPS6079448A (en) Control system for external page allocation
JPH10326222A (en) Space allocation control method for external storage device
JPH03127137A (en) File area allocating system
JPH06161836A (en) Area managing system for storage medium
JPH11154109A (en) System for dividing index storage area
CN112306901A (en) Disk refreshing method and device based on layered storage system, electronic equipment and medium
Lee et al. An efficient multi-sampling strategy for interactive display in a video-on-demand server
JPH01181121A (en) Memory area allocating system
JP2019160117A (en) Arrangement controller of logical storage area, arrangement control system of logical storage area, arrangement control method of logical storage area, and arrangement control program of logical storage area
JPH05225054A (en) Physical memory page allocating system