JPH08263218A - Device and method for storing data - Google Patents

Device and method for storing data

Info

Publication number
JPH08263218A
JPH08263218A JP6387195A JP6387195A JPH08263218A JP H08263218 A JPH08263218 A JP H08263218A JP 6387195 A JP6387195 A JP 6387195A JP 6387195 A JP6387195 A JP 6387195A JP H08263218 A JPH08263218 A JP H08263218A
Authority
JP
Japan
Prior art keywords
data
block
stored
physical
compressed
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
JP6387195A
Other languages
Japanese (ja)
Inventor
Shiro Takagi
志郎 高木
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.)
Toshiba Corp
Original Assignee
Toshiba 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 Toshiba Corp filed Critical Toshiba Corp
Priority to JP6387195A priority Critical patent/JPH08263218A/en
Publication of JPH08263218A publication Critical patent/JPH08263218A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE: To reduce the number of times of access by reading compressed data corresponding to a designated physical block number while extending those data when storage in a memory is judged but reading data for the block unit of a logical block number when storage in a physical block is judged. CONSTITUTION: It is discriminated while using a logical block managing table whether the block data of the logical block number designated by a host processor are stored in a compressed data storage part or in a physical block storage part. When those data are recorded in the compressed data storage part, the read data are extended but when those data are stored in the physical block storage part, those data are read out as they are. Thus, the number of times of access to the physical block storage part is decreased and the access to the data storage device can be accelerated. Further, since the compressed data storage part stores data in a small compression size, storage capacity can be reduced.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、たとえば、複数の光デ
ィスク等の可換記録媒体に対して所定のブロック単位に
データの記憶、読出を行うデータ記憶装置およびデータ
記憶方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a data storage device and a data storage method for storing and reading data in a predetermined block unit on an exchangeable recording medium such as a plurality of optical disks.

【0002】[0002]

【従来の技術】近年、オフィス内で管理するデータ量が
増大しており、これらの大量のデータを管理するため
に、大容量のデータ記憶装置が多く提案されている。例
えば、特公平4−38004号公報は、大容量を実現す
るために、複数の可換記録媒体とこれらの格納部と、可
換記録媒体上に対しデータの記録および読出しを行なう
駆動装置部と、可換記録媒体を格納部と駆動装置間で交
換するアクセサ部からなるオートチェンジャーを用いた
データ記憶装置のデータアクセス方式を提案している。
2. Description of the Related Art In recent years, the amount of data managed in an office has increased, and many large-capacity data storage devices have been proposed to manage such a large amount of data. For example, Japanese Examined Patent Publication (Kokoku) No. 4-38004 discloses a plurality of exchangeable recording media, their storages, and a drive unit for recording and reading data on and from the exchangeable recording media in order to realize a large capacity. , A data access method for a data storage device using an autochanger including an accessor unit for exchanging a removable recording medium between a storage unit and a drive unit is proposed.

【0003】記憶装置を利用する外部装置であるホスト
処理装置から記憶装置上のデータをアクセスするインタ
ーフェースは、アクセス単位をブロック(512バイト
またはこの整数倍)とするものが多く、ホスト処理装置
は論理的なブロック番号をパラメータとして記憶装置に
対してデータ記録、読出しを要求している。
An interface for accessing data on a storage device from a host processing device, which is an external device using the storage device, often uses a block (512 bytes or an integral multiple thereof) as an access unit, and the host processing device is a logical device. Data recording and reading are requested to the storage device using the specific block number as a parameter.

【0004】また、特公平4−38004号公報では、
ホストが指定する論理ブロック番号から、その論理ブロ
ックのデータが記憶されている可換記録媒体の番号と、
可換記録媒体上の物理ブロック番号への変換方式と、論
理ブロックのデータが記憶されている可換記録媒体の自
動交換方式について説明している。これによると、ホス
ト処理装置側はデータがどの可換記録媒体上に記録され
ているかを全く意識せずにデータを特定することが可能
となり、データアクセス時の処理が軽減される。
In Japanese Patent Publication No. 4-38004,
From the logical block number specified by the host, the number of the removable recording medium in which the data of the logical block is stored,
The conversion method to the physical block number on the exchangeable recording medium and the automatic exchange method of the exchangeable recording medium in which the data of the logical block is stored are described. According to this, the host processing device side can specify the data without being aware of which exchangeable recording medium the data is recorded on, and the processing at the time of data access is reduced.

【0005】特公平4−38004号公報の例では、物
理ブロック番号は可換記録媒体番号とその可換記録媒体
内のトラック番号で表現されており、論理ブロック番号
から物理ブロック番号への変換は、次式のように固定的
に行われている。
In the example of Japanese Examined Patent Publication No. 4-38004, the physical block number is represented by the exchangeable recording medium number and the track number in the exchangeable recording medium, and the conversion from the logical block number to the physical block number is performed. , Is fixedly performed as in the following equation.

【0006】 (論理ブロック番号)/(媒体あたりのトラック数) ・・・(1) 可換記録媒体番号=(1)式の商 トラック番号=(1)式の剰余 次に、たとえば、複数の可換記録媒体に所定のブロック
単位にデータを記憶するデータ記憶装置における従来の
データ記憶方法について、図18を参照して説明する。
なお、ここでは可換記録媒体番号、トラック番号を省略
し、物理ブロック番号は物理ブロック記憶部で一括して
管理されているとする。
(Logical block number) / (number of tracks per medium) (1) exchangeable recording medium number = quotient of equation (1) track number = remainder of equation (1) Next, for example, a plurality of A conventional data storage method in a data storage device that stores data in predetermined blocks in an exchangeable recording medium will be described with reference to FIG.
It should be noted that the removable recording medium number and the track number are omitted here, and the physical block number is collectively managed in the physical block storage unit.

【0007】図18において、データ記憶装置は、ホス
ト処理装置から送信される所定のブロック単位のデータ
(ブロックデータ)を受信すると、そのブロックデータ
を一時格納するホストバッファと、ホスト処理装置から
指定される論理ブロック番号を物理ブロック番号に変換
するための論理ブロック管理テーブルと、ブロックデー
タを記憶するための複数の可換記録媒体から構成される
物理ブロック記憶部を具備している。物理ブロック記憶
部内の各物理ブロックは物理ブロック番号で指定され
る。また、ここではブロックサイズを1Kバイト(Kは
1024)、データ記憶装置が管理する論理ブロック数
を10M個(Mは1024K)、総容量を10Gバイト
(Gは1024M)とする。
In FIG. 18, when the data storage device receives data in a predetermined block unit (block data) transmitted from the host processing device, it is designated by the host processing device and a host buffer for temporarily storing the block data. A logical block management table for converting a logical block number into a physical block number, and a physical block storage unit composed of a plurality of exchangeable recording media for storing block data. Each physical block in the physical block storage unit is designated by a physical block number. Also, assume that the block size is 1 Kbyte (K is 1024), the number of logical blocks managed by the data storage device is 10 M (M is 1024 K), and the total capacity is 10 Gbytes (G is 1024 M).

【0008】ホスト処理装置から指定される論理ブロッ
ク番号のブロックデータを読み出す場合、データ記憶装
置は、まず、論理ブロック管理テーブルから指定された
論理ブロック番号に対応する物理ブロック番号を求め、
物理ブロック記憶部からそのブロック番号のブロックデ
ータを読出し、ホストバッファへ転送する処理を行って
いた。
When reading the block data of the specified logical block number from the host processing device, the data storage device first obtains the physical block number corresponding to the specified logical block number from the logical block management table,
The block data of the block number is read from the physical block storage unit and transferred to the host buffer.

【0009】ホスト処理装置から指定される論理ブロッ
ク番号にブロックデータを書込む場合、データ記憶装置
は、まず、論理ブロック管理テーブルから指定された論
理ブロック番号に対応する物理ブロック番号を求め、ホ
ストバッファ内のブロックデータを物理ブロック記憶部
へ転送して、そこで、その物理ブロック番号に対応させ
て記憶するようになっていた。
When writing block data to a logical block number designated by the host processing device, the data storage device first obtains a physical block number corresponding to the designated logical block number from the logical block management table, and then the host buffer The block data in the internal block is transferred to the physical block storage unit and stored therein in association with the physical block number.

【0010】[0010]

【発明が解決しようとする問題点】可換記録媒体とオー
トチェンジャーを用いて物理ブロック記憶部を構成した
場合、論理ブロックにアクセスする際に、可換記録媒体
を入れ替える処理が発生し、非常に性能が悪化する。一
般的なオートチェンジャーでは入れ替えに10秒程度か
かり、ハードディスクドライブや光ディスクドライブの
アクセスタイムと比較して3桁程度遅い。そのため、従
来キャッシュを用いたりすることで、物理ブロック記憶
部へのアクセス回数を減らす工夫を行っていたが、それ
だけでは十分な性能向上が得られなかった。
When a physical block storage unit is constructed using an exchangeable recording medium and an autochanger, a process of exchanging the exchangeable recording medium occurs when accessing a logical block, which results in extremely high performance. Becomes worse. A typical autochanger takes about 10 seconds to replace, which is about 3 digits slower than the access time of a hard disk drive or an optical disk drive. Therefore, a conventional cache has been used to reduce the number of accesses to the physical block storage unit, but it has not been sufficient to improve the performance.

【0011】また、従来では装置使用前に論理ブロック
数と同じ個数の物理ブロックが必要であり、特に物理ブ
ロック記憶部の記憶デバイスとして可換記憶媒体を用い
た場合、装置の論理ブロック数に等しい物理ブロック数
を含む新規の可換記録媒体を最初から準備する必要があ
った。
Further, conventionally, the same number of physical blocks as the number of logical blocks is required before using the apparatus, and particularly when an exchangeable storage medium is used as a storage device of the physical block storage unit, it is equal to the number of logical blocks of the apparatus. It was necessary to prepare a new removable recording medium including the number of physical blocks from the beginning.

【0012】そこで、本発明は、アクセスが低速な物理
ブロック記憶部へのアクセス回数の低減を図り、より高
速なデータの読出しが可能であるとともに、物理ブロッ
ク記憶部の記憶容量の低減が可能なデータ記憶装置およ
びデータ記憶方法を提供することを目的とする。
Therefore, according to the present invention, it is possible to reduce the number of times of access to the physical block storage unit having a low access speed, to read data at a higher speed, and to reduce the storage capacity of the physical block storage unit. An object of the present invention is to provide a data storage device and a data storage method.

【0013】[0013]

【問題を解決するための手段】本発明のデータ記憶装置
は、あらかじめ割当てられたブロック単位のデータを記
憶する物理ブロックにアクセスして前記データの記憶、
読出しを行うデータ記憶装置であって、前記ブロック単
位のデータを記憶する際、そのブロック単位のデータを
圧縮する圧縮手段と、この圧縮手段で圧縮された圧縮デ
ータのデータ長があらかじめ定められた値以下のとき、
前記圧縮データを高速なアクセスが可能なメモリに記憶
するよう制御を行う第1の制御手段と、前記圧縮手段で
圧縮された圧縮データのデータ長があらかじめ定められ
た値よりも大きいとき、前記ブロック単位のデータを前
記物理ブロックに記憶するよう制御を行う第2の制御手
段と、ブロック単位のデータを読出す際、指定された前
記ブロック単位のデータが前記メモリあるいは前記物理
ブロックのいずれに記憶されているかを判断する判断手
段と、この判断手段で前記メモリに記憶されていること
が判断されたとき、前記メモリに記憶されているブロッ
ク単位の圧縮データを伸張して読出すよう制御を行う第
3の制御手段と、前記判断手段で前記物理ブロックに記
憶されていることが判断されたとき、前記物理ブロック
から前記ブロック単位のデータを読出すよう制御を行う
第4の制御手段とを具備している。
A data storage device according to the present invention stores a data by accessing a physical block for storing data of a block unit which is assigned in advance.
A data storage device for reading, wherein when storing the data in block units, a compression unit for compressing the data in block units, and a data length of the compressed data compressed by the compression unit is a predetermined value. When
First control means for controlling the compressed data to be stored in a memory that can be accessed at high speed; and the block when the data length of the compressed data compressed by the compression means is larger than a predetermined value. Second control means for controlling to store the unit data in the physical block, and when the block unit data is read, the designated block unit data is stored in either the memory or the physical block. Determining means for determining whether the data is stored in the memory, and when the determination means determines that the data is stored in the memory, the compressed data in block units stored in the memory is decompressed and read. When it is determined by the control means of No. 3 and the determination means that the physical block is stored in the physical block, And it includes a fourth control means for controlling so read the position data.

【0014】また、本発明のデータ記憶装置は、所定の
ブロック単位のデータが連続した論理ブロック番号で管
理され、その論理ブロック番号に割当てられた前記ブロ
ック単位のデータを記憶する物理ブロックにアクセスし
て前記データの記憶、読出しを行うデータ記憶装置であ
って、指定された論理ブロック番号の前記ブロック単位
のデータを記憶する際、そのブロック単位のデータを圧
縮して圧縮データを求める圧縮手段と、この圧縮手段で
求められた圧縮データのデータ長があらかじめ定められ
た値以下のとき、前記圧縮データを前記指定された論理
ブロック番号に対応させて、高速なアクセスが可能なメ
モリに記憶するよう制御を行う第1の制御手段と、前記
圧縮手段で求められた圧縮データのデータ長があらかじ
め定められた値よりも大きいとき、前記指定された論理
ブロック番号に対して前記物理ブロックを割当てる割当
手段と、この割当手段で前記指定された論理ブロック番
号に対して割当てられた物理ブロックに前記ブロック単
位のデータを記憶するよう制御を行う第2の制御手段
と、指定された論理ブロック番号のブロック単位のデー
タを読出す際、前記指定された論理ブロック番号を基
に、前記ブロック単位のデータが前記メモリあるいは前
記物理ブロックのいずれに記憶されているかを判断する
判断手段と、この判断手段で前記メモリに記憶されてい
ることが判断されたとき、前記メモリから前記指定され
た物理ブロック番号に対応する圧縮データを伸張して読
出すよう制御を行う第3の制御手段と、前記判断手段で
前記物理ブロックに記憶されていることが判断されたと
き、前記指定された論理ブロック番号に対して割当てら
れた物理ブロックから前記ブロック単位のデータを読出
すよう制御を行う第4の制御手段とを具備している。
Further, the data storage device of the present invention manages data of a predetermined block unit by consecutive logical block numbers, and accesses a physical block storing the data of the block unit assigned to the logical block number. A data storage device for storing and reading the data, and compressing the block unit data to obtain compressed data when storing the block unit data of a specified logical block number; When the data length of the compressed data obtained by the compression means is equal to or less than a predetermined value, the compressed data is controlled to be stored in a memory that can be accessed at high speed in association with the designated logical block number. And the data length of the compressed data obtained by the compression means is a predetermined value. When it is also larger, the allocation unit that allocates the physical block to the specified logical block number, and the block unit data is stored in the physical block allocated to the specified logical block number by the allocation unit. And a second control means for performing control so as to read data in block units having a designated logical block number, based on the designated logical block number, the data in the block units is stored in the memory or the physical unit. Determining means for determining which of the blocks is stored, and when the determining means determines that the memory is stored in the memory, the compressed data corresponding to the specified physical block number is expanded from the memory. And a third control means for performing control so that the physical block is stored in the physical block. When it is determined, and a fourth control means for controlling so that reading data of the block unit from the physical block assigned to the designated logical block numbers.

【0015】また、本発明のデータ記憶方法は、所定の
ブロック単位のデータが連続した論理ブロック番号で管
理され、その論理ブロック番号に対してあらかじめ割当
てられた前記ブロック単位のデータを記憶する物理ブロ
ックにアクセスして前記データの記憶、読出を行うデー
タ記憶方法であって、指定された論理ブロック番号の前
記ブロック単位のデータを記憶する際、そのブロック単
位のデータを圧縮して圧縮データを求め、その圧縮デー
タのデータ長があらかじめ定められた値以下のとき、前
記圧縮データを前記指定された論理ブロック番号に対応
させて、高速なアクセスが可能なメモリに記憶し、前記
圧縮データのデータ長があらかじめ定められた値よりも
大きいとき、前記ブロック単位のデータを前記指定され
た論理ブロック番号に割当てられた物理ブロックに記憶
し、指定された論理ブロック番号のブロック単位のデー
タを読出す際、前記指定された論理ブロック番号を基
に、前記メモリあるいは前記物理ブロックのいずれに記
憶されているかを判断し、前記メモリに記憶されている
ことが判断されたとき、前記メモリから前記指定された
物理ブロック番号に対応する圧縮データを伸張して読出
し、前記物理ブロックに記憶されていることが判断され
たとき、前記指定された論理ブロック番号に割当てられ
た物理ブロックから前記ブロック単位のデータを読出す
ことを特徴とする。
Further, the data storage method of the present invention is a physical block in which data of a predetermined block unit is managed by a continuous logical block number, and the data of the block unit pre-assigned to the logical block number is stored. Is a data storage method for accessing and storing the data to read and write the data in the block unit of a designated logical block number, compressing the data in the block unit to obtain compressed data, When the data length of the compressed data is less than or equal to a predetermined value, the compressed data is stored in a memory that can be accessed at high speed in association with the designated logical block number, and the data length of the compressed data is When it is larger than a predetermined value, the data of the block unit is changed to the specified logical block number. When the data is stored in the physical block assigned to the block and the data in block units of the designated logical block number is read out, which of the memory and the physical block is stored based on the designated logical block number? When it is determined that the data is stored in the memory, the compressed data corresponding to the specified physical block number is decompressed and read from the memory, and it is determined that the data is stored in the physical block. Then, the data in the block unit is read from the physical block assigned to the designated logical block number.

【0016】また、本発明のデータ記憶方法は、所定の
ブロック単位のデータが連続した論理ブロック番号で管
理され、その論理ブロック番号に割当てられた前記ブロ
ック単位のデータを記憶する物理ブロックにアクセスし
て前記データの記憶、読出しを行うデータ記憶方法であ
って、指定された論理ブロック番号の前記ブロック単位
のデータを記憶する際、そのブロック単位のデータを圧
縮して圧縮データを求め、その圧縮データのデータ長が
あらかじめ定められた値以下のとき、前記圧縮データを
前記指定された論理ブロック番号に対応させて、高速な
アクセスが可能なメモリに記憶し、前記圧縮データのデ
ータ長があらかじめ定められた値よりも大きいとき、前
記指定された論理ブロック番号に対して前記物理ブロッ
クを割当て、その割当てられた物理ブロックに前記ブロ
ック単位のデータを記憶し、指定された論理ブロック番
号のブロック単位のデータを読出す際、前記指定された
論理ブロック番号を基に、前記ブロック単位のデータが
前記メモリあるいは前記物理ブロックのいずれに記憶さ
れているかを判断し、前記メモリに記憶されていること
が判断されたとき、前記メモリから前記指定された物理
ブロック番号に対応する圧縮データを伸張して読出し、
前記物理ブロックに記憶されていることが判断されたと
き、前記指定された論理ブロック番号に対して割当てら
れた物理ブロックから前記ブロック単位のデータを読出
すことを特徴とする。
Further, in the data storage method of the present invention, data in a predetermined block unit is managed by a continuous logical block number, and a physical block for storing the block unit data assigned to the logical block number is accessed. Is a data storage method of storing and reading the data, and storing the data in the block unit of a designated logical block number, compresses the data in the block unit to obtain compressed data, and the compressed data When the data length of the compressed data is less than or equal to a predetermined value, the compressed data is stored in a memory that can be accessed at high speed in association with the designated logical block number, and the data length of the compressed data is determined in advance. Is greater than the specified value, the physical block is assigned to the specified logical block number, When the data of the block unit is stored in the assigned physical block and the data of the block unit of the designated logical block number is read, the data of the block unit is stored in the memory based on the designated logical block number. Alternatively, it is determined in which of the physical blocks the data is stored, and when it is determined that the data is stored in the memory, the compressed data corresponding to the specified physical block number is decompressed and read from the memory,
When it is determined that the data is stored in the physical block, the data in the block unit is read from the physical block assigned to the designated logical block number.

【0017】また、本発明のデータ記憶方法は、所定の
ブロック単位のデータが連続した論理ブロック番号で管
理され、複数の可換記録媒体上の前記論理ブロック番号
に対してあらかじめ割当てられた物理ブロックにアクセ
スして前記データの記憶、読出を行うデータ記憶方法で
あって、指定された論理ブロック番号の前記ブロック単
位のデータを記憶する際、そのブロック単位のデータを
圧縮して圧縮データを求め、その圧縮データのデータ長
があらかじめ定められた値以下のとき、前記圧縮データ
を前記指定された論理ブロック番号に対応させて、高速
なアクセスが可能なメモリに記憶し、前記圧縮データの
データ長があらかじめ定められた値よりも大きいとき、
前記ブロック単位のデータを前記指定された論理ブロッ
ク番号に割当てられた物理ブロックに記憶し、指定され
た論理ブロック番号のブロック単位のデータを読出す
際、前記指定された論理ブロック番号を基に、前記メモ
リあるいは前記物理ブロックのいずれに記憶されている
かを判断し、前記メモリに記憶されていることが判断さ
れたとき、前記メモリから前記指定された物理ブロック
番号に対応する圧縮データを伸張して読出し、前記物理
ブロックに記憶されていることが判断されたとき、前記
指定された論理ブロック番号に割当てられた物理ブロッ
クから前記ブロック単位のデータを読出すことを特徴と
する。
Further, in the data storage method of the present invention, data in a predetermined block unit is managed by consecutive logical block numbers, and physical blocks pre-allocated to the logical block numbers on a plurality of exchangeable recording media. Is a data storage method for accessing and storing the data to read and write the data in the block unit of a designated logical block number, compressing the data in the block unit to obtain compressed data, When the data length of the compressed data is less than or equal to a predetermined value, the compressed data is stored in a memory that can be accessed at high speed in association with the designated logical block number, and the data length of the compressed data is When it is larger than the predetermined value,
When the data of the block unit is stored in the physical block assigned to the designated logical block number and the data of the block unit of the designated logical block number is read, based on the designated logical block number, It is determined whether the data is stored in the memory or the physical block, and when it is determined that the data is stored in the memory, the compressed data corresponding to the specified physical block number is decompressed from the memory. When it is determined that the data is read and stored in the physical block, the data in the block unit is read from the physical block assigned to the designated logical block number.

【0018】さらに、本発明のデータ記憶方法は、所定
のブロック単位のデータが連続した論理ブロック番号で
管理され、複数の可換記録媒体上の前記論理ブロック番
号に対して割当てられた物理ブロックにアクセスして前
記データの記憶、読出しを行うデータ記憶方法であっ
て、指定された論理ブロック番号の前記ブロック単位の
データを記憶する際、そのブロック単位のデータを圧縮
して圧縮データを求め、その圧縮データのデータ長があ
らかじめ定められた値以下のとき、前記圧縮データを前
記指定された論理ブロック番号に対応させて、高速なア
クセスが可能なメモリに記憶し、前記圧縮データのデー
タ長があらかじめ定められた値よりも大きいとき、前記
指定された論理ブロック番号に対して前記物理ブロック
を割当て、その割当てられた物理ブロックに前記ブロッ
ク単位のデータを記憶し、指定された論理ブロック番号
のブロック単位のデータを読出す際、前記指定された論
理ブロック番号を基に、前記ブロック単位のデータが前
記メモリあるいは前記物理ブロックのいずれに記憶され
ているかを判断し、前記メモリに記憶されていることが
判断されたとき、前記メモリから前記指定された物理ブ
ロック番号に対応する圧縮データを伸張して読出し、前
記物理ブロックに記憶されていることが判断されたと
き、前記指定された論理ブロック番号に対して割当てら
れた物理ブロックから前記ブロック単位のデータを読出
すことを特徴とする。
Further, according to the data storage method of the present invention, data in a predetermined block unit is managed by a continuous logical block number, and the physical block is assigned to the logical block number on a plurality of exchangeable recording media. A data storage method of accessing and storing and reading the data, wherein when storing the data in the block unit of a designated logical block number, the data in the block unit is compressed to obtain compressed data, and When the data length of the compressed data is less than or equal to a predetermined value, the compressed data is stored in a memory that can be accessed at high speed in association with the specified logical block number, and the data length of the compressed data is set in advance. When it is larger than a specified value, the physical block is allocated to the specified logical block number, and the allocation is performed. When the data of the block unit is stored in the designated physical block and the data of the block unit of the designated logical block number is read out, the data of the block unit is stored in the memory or the memory based on the designated logical block number. It is determined in which of the physical blocks the data is stored, and when it is determined that the data is stored in the memory, the compressed data corresponding to the specified physical block number is decompressed and read from the memory, and When it is determined that the data is stored in the physical block, the data in the block unit is read from the physical block assigned to the designated logical block number.

【0019】[0019]

【作用】指定された論理ブロック番号のブロック単位の
データを記憶する際、そのブロック単位のデータを圧縮
して圧縮データを求め、その圧縮データのデータ長があ
らかじめ定められた値以下のとき、前記圧縮データを前
記指定された論理ブロック番号に対応させて、高速なア
クセスが可能なメモリに記憶し、前記圧縮データのデー
タ長があらかじめ定められた値よりも大きいとき、前記
ブロック単位のデータを前記指定された論理ブロック番
号に割当てられた物理ブロックに記憶し、指定された論
理ブロック番号のブロック単位のデータを読出す際、前
記指定された論理ブロック番号を基に、前記メモリある
いは前記物理ブロックのいずれに記憶されているかを判
断し、前記メモリに記憶されていることが判断されたと
き、前記メモリから前記指定された物理ブロック番号に
対応する圧縮データを伸張して読出し、前記物理ブロッ
クに記憶されていることが判断されたとき、前記指定さ
れた論理ブロック番号に割当てられた物理ブロックから
前記ブロック単位のデータを読出すことにより、アクセ
スが低速な物理ブロックで構成される記憶部へのアクセ
ス回数の低減を図り、より高速なデータの読出しが可能
となる。
When storing the block unit data of the specified logical block number, the block unit data is compressed to obtain the compressed data, and when the data length of the compressed data is equal to or less than the predetermined value, The compressed data is stored in a memory that can be accessed at high speed in association with the specified logical block number, and when the data length of the compressed data is larger than a predetermined value, the data in block units is When the data is stored in the physical block assigned to the designated logical block number and the data in block units of the designated logical block number is read out, based on the designated logical block number, the memory or the physical block When it is determined that it is stored in the memory, it is determined whether the memory is stored in the memory. When the compressed data corresponding to the specified physical block number is decompressed and read and it is determined that the compressed data is stored in the physical block, the block unit is determined from the physical block assigned to the specified logical block number. By reading the data of 1, the number of times of access to the storage unit configured by the physical block whose access speed is low can be reduced, and the data can be read at higher speed.

【0020】また、指定された論理ブロック番号のブロ
ック単位のデータを記憶する際、そのブロック単位のデ
ータを圧縮して圧縮データを求め、その圧縮データのデ
ータ長があらかじめ定められた値よりも大きいとき、ま
ず、前記指定された論理ブロック番号に対して前記物理
ブロックを割当て、その割当てられた物理ブロックに前
記ブロック単位のデータを記憶することにより、前記論
理ブロック番号に対して割当てる物理ブロックは、実際
に必要なだけの記憶容量があればよく、従って、物理ブ
ロックで構成される記憶部の記憶容量の低減が可能とな
る。
Further, when storing the block unit data of the designated logical block number, the block unit data is compressed to obtain the compressed data, and the data length of the compressed data is larger than a predetermined value. At this time, first, by allocating the physical block to the specified logical block number and storing the data in block units in the allocated physical block, the physical block allocated to the logical block number is: It suffices if the storage capacity is actually required, and therefore the storage capacity of the storage unit composed of physical blocks can be reduced.

【0021】[0021]

【実施例】以下、本発明の実施例について図面を参照し
て説明する。まず、本発明の原理について説明する。図
1は、アクセスが低速な記憶デバイスで構成される物理
ブロック記憶部を具備したデータ記憶装置において、外
部のホスト処理装置から論理ブロック番号(アドレス)
を指定してアクセスされて、データの記憶、読出を行う
際、物理ブロック記憶部へのアクセス回数を減らし、ア
クセス処理の高速化を実現するための第1のデータ記憶
方法の原理を説明するためのものである。
Embodiments of the present invention will be described below with reference to the drawings. First, the principle of the present invention will be described. FIG. 1 shows a logical block number (address) from an external host processing device in a data storage device including a physical block storage unit configured by a storage device with low access speed.
To explain the principle of the first data storage method for reducing the number of times of access to the physical block storage unit and realizing high-speed access processing when data is stored and read by being specified. belongs to.

【0022】ここで、ブロックとは、所定のデータ長の
一単位のデータ量をいい、データは、このブロック単位
に物理ブロック記憶部に記憶されるものである。また、
物理ブロック記憶部内のブロック、すなわち、物理ブロ
ックは、物理ブロック番号により管理され、ホスト処理
装置から指定される連続する論理ブロックの番号のそれ
ぞれに対応するようになっている。すなわち、ホスト処
理装置側では、ブロックデータは、論理ブロックとし
て、連続した論理ブロック番号で管理され、ホスト処理
装置から指定される論理ブロック番号をデータ記憶装置
にて物理ブロック番号に変換してから対応する物理ブロ
ック記憶部の物理ブロックにアクセスするようになって
いる。
Here, the block means a data amount of one unit of a predetermined data length, and the data is stored in the physical block storage unit in this block unit. Also,
A block in the physical block storage unit, that is, a physical block is managed by a physical block number and corresponds to each number of consecutive logical blocks designated by the host processing device. That is, on the host processing device side, block data is managed as consecutive logical block numbers as logical blocks, and the logical block number designated by the host processing device is converted into a physical block number in the data storage device before it is handled. A physical block in the physical block storage unit is accessed.

【0023】さて、図1において、第1のデータ記憶方
法は、ホスト処理装置から論理ブロック番号が指定され
て送信されたブロック単位のデータ(以下、ブロックデ
ータと呼ぶ)をデータ記憶装置において記憶する際、ま
ず、そのブロックデータを圧縮し、圧縮後のデータのサ
イズがあらかじめ定められてサイズより小さいかどうか
を判定する。サイズが小さい場合には高速アクセス可能
な圧縮データ記憶部に圧縮データを記憶し、サイズが大
きい場合は従来と同じように物理ブロック記憶部に非圧
縮データを記憶するようにするものである。
In the first data storage method shown in FIG. 1, block-unit data (hereinafter referred to as block data) transmitted from the host processing device with a logical block number specified is stored in the data storage device. At this time, first, the block data is compressed, and it is determined whether or not the size of the compressed data is smaller than a predetermined size. When the size is small, the compressed data is stored in the compressed data storage unit that can be accessed at high speed, and when the size is large, the non-compressed data is stored in the physical block storage unit as in the conventional case.

【0024】圧縮データ記憶部と物理ブロック記憶部の
記憶デバイスはともに全ての論理ブロック(10M個)
を記憶できる容量を持っているものとする。論理ブロッ
ク管理テーブル上には各論理ブロックが圧縮データ記憶
部または物理ブロック記憶部のどちらに記憶されたかを
示すフラグ領域があり、論理ブロック書き込み時に設定
される。
The storage devices of the compressed data storage unit and the physical block storage unit are all logical blocks (10M).
Shall have the capacity to store. The logical block management table has a flag area indicating whether each logical block is stored in the compressed data storage unit or the physical block storage unit, and is set at the time of writing the logical block.

【0025】また、論理ブロック管理テーブル上の物理
ブロック番号は、論理ブロックに対応する物理ブロック
の番号で、フラグが非圧縮のときに参照される。圧縮デ
ータ番号は、論理ブロックに対応する圧縮データの番号
で、フラグが圧縮のときに参照される。
The physical block number on the logical block management table is the number of the physical block corresponding to the logical block and is referred to when the flag is uncompressed. The compressed data number is the number of compressed data corresponding to the logical block, and is referred to when the flag is compressed.

【0026】ホスト処理装置から指定された論理ブロッ
ク番号のブロックデータを読み出す際には、まず、指定
された論理ブロック番号のブロックデータが圧縮データ
記憶部か物理ブロック記憶部に記憶されているかを論理
ブロック管理テーブルを用いて判定し、圧縮データ記憶
部に記録されている場合には読み出したデータを伸張
し、物理ブロック記憶部に記録されている場合にはその
まま読み出すようにするものである。
When reading the block data of the specified logical block number from the host processing device, it is first determined whether the block data of the specified logical block number is stored in the compressed data storage unit or the physical block storage unit. The determination is made using the block management table, and the read data is decompressed when it is recorded in the compressed data storage unit, and is read as it is when it is recorded in the physical block storage unit.

【0027】このようにすることで物理ブロック記憶部
へのアクセス回数が減少し、データ記憶装置におけるア
クセスの高速化が可能となる。しかも圧縮データ記憶部
には圧縮サイズの小さいデータを記憶するため、記憶容
量を小さくすることも可能となる。
By doing so, the number of accesses to the physical block storage unit is reduced, and the access speed in the data storage device can be increased. Moreover, since the compressed data storage unit stores data having a small compressed size, the storage capacity can be reduced.

【0028】ここで採用するデータ圧縮・伸張方式は、
処理の高速なものを採用する。例えば、バイトまたはワ
ード単位のランレングス符号を採用することで、ブロッ
ク内の全てのデータが同じ場合の圧縮後のサイズを数バ
イトにすることが可能となる。ブロック単位にデータを
記憶するデータ記憶装置の使用開始時のフォーマット処
理では、ブロックを全て0でクリアする処理が多く、簡
単なバイト単位でのランレングス符号を用いても、物理
ブロック記憶部へのアクセス回数を減らし、性能を高め
ることが可能となる。
The data compression / expansion method adopted here is
Use a high-speed one. For example, by adopting a run length code in units of bytes or words, it is possible to reduce the size after compression when all the data in the block are the same. In the formatting process at the start of use of the data storage device that stores data in block units, there are many processes that clear all blocks by 0, and even if a simple byte unit run length code is used, It is possible to reduce the number of accesses and improve the performance.

【0029】図2は、ランレングス(Run Leng
th)符号を説明するためのものである。ランレングス
符号は同じ値が何個連続するかを基本にしたもので、図
2の例では、1バイトの値「00」が6個連続し、その
後、1バイトの値「33」が2個連続する8バイトから
なるデータである。データ圧縮は同じ値が連続する区間
毎に、連続する個数、値に変換され、最後にデータの終
了を示す符号「00」が付加される。
FIG. 2 shows the Run Length.
th) is for explaining the code. The run length code is based on the number of consecutive same values. In the example of FIG. 2, 6 1-byte values “00” are consecutive, and then 1-byte value “33” is 2 consecutive. This data consists of consecutive 8 bytes. In the data compression, the same value is converted into a continuous number and a value for each continuous section, and a code "00" indicating the end of the data is added at the end.

【0030】図2において、8バイトのデータが5バイ
トのデータに圧縮されている。同じ値が長く連続するほ
ど圧縮率が高くなる。次に、図3を参照して、第2のデ
ータ記憶方法の原理について説明する。
In FIG. 2, 8-byte data is compressed into 5-byte data. The longer the same value continues, the higher the compression rate. Next, the principle of the second data storage method will be described with reference to FIG.

【0031】この第2のデータ記憶方法は、前述の第1
のデータ記憶方法のように、物理ブロック記憶部の記憶
デバイスにあらかじめ全ての論理ブロック(10M個)
を記憶できる容量を割り当てるのでなく、物理ブロック
記憶部用の記憶デバイス容量を必要に応じて可変するこ
とが可能なものである。そのため、物理ブロック管理テ
ーブルと記憶デバイス割当解放部が追加されている。
This second data storage method is the same as the above first method.
Like all data storage methods, all the logical blocks (10M) are previously stored in the storage device of the physical block storage unit.
It is possible to change the storage device capacity for the physical block storage unit as needed, instead of allocating the capacity for storing the data. Therefore, a physical block management table and a storage device allocation releasing unit are added.

【0032】物理ブロック管理テーブルは、物理記憶部
内のどの物理ブロックに実際の記憶デバイスが割当てら
れ、さらに論理ブロックのデータを記憶しているかを管
理するものである。
The physical block management table manages which physical block in the physical storage unit the actual storage device is assigned to and further stores the data of the logical block.

【0033】記憶デバイス割当解放部は、物理ブロック
記憶部内の物理ブロックへの記憶デバイスの割当と、解
放を行うものである。図3において、物理ブロック記憶
部では、例えば、10M個の物理ブロックの内、前半の
5M個に記憶デバイスが割り当てられており、後半の5
M個には割り当てられていない。記憶デバイスの割り当
てられていない物理ブロックの物理ブロック管理テーブ
ル上のフラグは「未割当」と設定される。記憶デバイス
が割り当てられている物理ブロックの内、ブロックデー
タの非圧縮データが記憶されている物理ブロックのフラ
グは「使用」と設定され、ブロックデータ記憶用には使
用されていない物理ブロックのフラグは「未使用」と設
定される。
The storage device allocation release unit allocates and releases storage devices to physical blocks in the physical block storage unit. In FIG. 3, in the physical block storage unit, for example, of the 10M physical blocks, storage devices are allocated to the first 5M, and the latter 5M.
It is not assigned to M. The flag on the physical block management table of the physical block to which the storage device is not allocated is set to "unallocated". Of the physical blocks to which the storage device is assigned, the flag of the physical block that stores the uncompressed data of the block data is set to "Use", and the flag of the physical block that is not used for storing block data is It is set as "unused".

【0034】ホスト処理装置から論理ブロック番号が指
定されて送信されたブロックデータをデータ記憶装置に
おいて記憶する際、まず、そのブロックデータを圧縮
し、圧縮後のデータのサイズがあらかじめ定められたデ
ータのサイズより小さいかどうかを判定する。サイズが
小さい場合には高速アクセス可能な圧縮データ記憶部に
圧縮データを記憶し、以前のデータが物理ブロック記憶
部に記録されていた場合はその物理ブロック管理テーブ
ルのフラグを「使用」から「未使用」に変更する。圧縮
サイズが大きい場合は、物理ブロック管理テーブル内か
らフラグが「未使用」であるものを探し、その物理ブロ
ック(物理ブロック記憶部)へ非圧縮データを記録す
る。フラグが「未使用」である物理ブロックが無い場合
は、記憶デバイス割当解放部により物理ブロック記憶部
用の記憶デバイスを追加する処理を行う。またフラグが
「未使用」である物理ブロックが増加した場合は、記憶
デバイスを解放し、フラグを「未割当」とする。
When storing the block data transmitted from the host processing device by designating the logical block number in the data storage device, first, the block data is compressed, and the size of the compressed data is a predetermined data size. Determine if it is less than size. When the size is small, the compressed data is stored in the compressed data storage unit that can be accessed at high speed, and when the previous data is recorded in the physical block storage unit, the flag of the physical block management table is changed from "Use" to "Not used". Change to "Use". If the compressed size is large, the physical block management table is searched for a flag whose flag is "unused", and uncompressed data is recorded in the physical block (physical block storage unit). When there is no physical block whose flag is “unused”, the storage device allocation releasing unit performs a process of adding a storage device for the physical block storage unit. When the number of physical blocks whose flag is “unused” increases, the storage device is released and the flag is set to “unallocated”.

【0035】このように記憶デバイス割当解放部におい
て、必要に応じて物理ブロック記憶部用の記憶デバイス
を増やして割り当てたり、減らしたりして可換記録媒体
などの記憶デバイスを有効的に運用することが可能とな
る。
As described above, in the storage device allocation releasing unit, the storage devices such as the removable recording medium can be effectively operated by increasing or allocating the storage devices for the physical block storage unit as necessary. Is possible.

【0036】次に、図4を参照して、第1の実施例につ
いて説明する。図4は、前述の第1のデータ記憶方法を
採用したデータ記憶装置の構成を概略的に示したもので
ある。
Next, the first embodiment will be described with reference to FIG. FIG. 4 schematically shows the configuration of a data storage device that employs the above-described first data storage method.

【0037】なお、図4のデータ記憶装置は、例えば、
1Kバイト(1024バイト)単位のブロックデータを
10M(1024×1024)個のブロックデータを記
憶し、総容量は10G(10×1024×1024×1
024)バイトである。
The data storage device shown in FIG.
The block data of 1 Kbyte (1024 bytes) unit stores 10M (1024 × 1024) block data, and the total capacity is 10 G (10 × 1024 × 1024 × 1).
024) bytes.

【0038】図4において、データ記憶装置1は、LA
N等の通信回線11を介してホスト処理装置10と接続
されている。データ記憶装置1は、CPU2、HDD
3、メインメモリ4、通信制御部5、ホストバッファ
6、圧縮・伸長部7、第1の記憶部8、第2の記憶部9
がシステムバス12に互いに接続されて構成されてい
る。
In FIG. 4, the data storage device 1 is an LA
It is connected to the host processing apparatus 10 via a communication line 11 such as N. The data storage device 1 includes a CPU 2 and an HDD
3, main memory 4, communication control unit 5, host buffer 6, compression / decompression unit 7, first storage unit 8, second storage unit 9
Are connected to the system bus 12 with each other.

【0039】HDD(ハードディスクドライブ)3は、
磁気ディスク等から構成され、メインメモリ4は、RA
M等から構成され、データ記憶装置1全体の制御プログ
ラムおよび制御の際必要なデータを記憶するためのもの
である。
The HDD (hard disk drive) 3 is
The main memory 4 is a RA
It is composed of M and the like, and is for storing a control program of the entire data storage device 1 and data necessary for control.

【0040】CPU2はデータ記憶装置1全体の制御を
司るもので、動作開始時にHDD3に格納された制御プ
ログラムをメインメモリ4上に読出して、その制御プロ
グラムに従って動作するようになっている。
The CPU 2 controls the entire data storage device 1, and reads the control program stored in the HDD 3 onto the main memory 4 at the start of operation and operates according to the control program.

【0041】通信制御部5は通信回線11を介して接続
されたホスト処理装置10との通信を司どるもので、ホ
スト処理装置から送られてくるアクセスコマンド(例え
ば、読出コマンド、書込コマンド)、論理ブロック番
号、ブロックデータ等を受信し、処理結果をホスト処理
装置10に送信するものである。
The communication control unit 5 controls communication with the host processing unit 10 connected via the communication line 11, and an access command (for example, read command, write command) sent from the host processing unit. , The logical block number, the block data, etc., and the processing result is transmitted to the host processing apparatus 10.

【0042】ホストバッファ6は、ブロックデータを一
時的に記憶するものである。すなわち、読出コマンド時
は指定された論理ブロック番号のブロックデータをデー
タ記憶装置1(第1の記憶部8あるいは第2の記憶部
9)内から読み出して格納し、通信制御部5によりこの
データがホスト処理装置10に送信される。また、書込
コマンド時は、通信制御部5がホスト処理装置10から
受信した書込み用のブロックデータをホストバッファ6
に一時格納してから、データ記憶装置1(第1の記憶部
8あるいは第2の記憶部9)内に書き込むようになって
いる。
The host buffer 6 temporarily stores block data. That is, at the time of a read command, the block data of the specified logical block number is read from the data storage device 1 (first storage unit 8 or second storage unit 9) and stored, and this data is stored by the communication control unit 5. It is transmitted to the host processing device 10. Also, at the time of a write command, the communication control unit 5 sends the write block data received from the host processing device 10 to the host buffer 6.
The data is temporarily stored in the data storage device 1 and then written in the data storage device 1 (the first storage portion 8 or the second storage portion 9).

【0043】圧縮・伸張部7は、ブロックデータに対
し、圧縮および伸長するものである。圧縮方法として
は、例えば、バイト単位のランレングス符号による場合
等がある。
The compression / expansion unit 7 is for compressing and expanding the block data. As a compression method, for example, there is a case of using a run length code in units of bytes.

【0044】第1の記憶部8は、例えば、バッテリバッ
クアップ式のメモリで、論理ブロック管理テーブルを記
憶するようになっている。この論理ブロック管理テーブ
ル内には圧縮データ記憶部が含まれている。
The first storage unit 8 is, for example, a battery backup type memory, and is adapted to store a logical block management table. A compressed data storage unit is included in this logical block management table.

【0045】第2の記憶部9は、アクセスが低速な記憶
媒体で構成される物理ブロック記憶用の記憶デバイスで
ある。図5は、第1の記憶部8における論理ブロック管
理テーブルの記憶例を示したものである。
The second storage unit 9 is a storage device for physical block storage, which is composed of a storage medium with low access speed. FIG. 5 shows a storage example of the logical block management table in the first storage unit 8.

【0046】この第1の実施例では、論理ブロックが全
部で10M個あるので、物理ブロックも10M個のブロ
ックデータが記憶できるようあらかじめ固定的に設定さ
れている。
In this first embodiment, since there are a total of 10M logical blocks, the physical blocks are also fixedly set in advance so that 10M block data can be stored.

【0047】図5において、論理ブロック管理テーブル
は、連続した全ての論理ブロック番号について、それぞ
れ、フラグ、物理ブロック番号、圧縮データを記憶する
領域が割り当てられている。
In FIG. 5, in the logical block management table, a flag, a physical block number, and an area for storing compressed data are assigned to all consecutive logical block numbers.

【0048】フラグは、ブロックデータが第1の記憶部
8、第2の記憶部9のうちいずれに記憶されているかを
示すもので、指定された論理ブロック番号のフラグ欄が
「非圧縮」の場合は、そのブロックデータは圧縮されな
い状態(非圧縮データ)で第2の記憶部9に記憶されて
おり、「圧縮」の場合は、その指定された論理ブロック
番号のブロックデータは、圧縮された状態(圧縮デー
タ)でこの論理ブロック管理テーブルの圧縮データの記
憶領域に記憶されている。
The flag indicates which of the first storage unit 8 and the second storage unit 9 the block data is stored in, and the flag column of the designated logical block number is "uncompressed". In the case of, the block data is stored in the second storage unit 9 in a non-compressed state (non-compressed data), and in the case of “compression”, the block data of the designated logical block number is compressed. The state (compressed data) is stored in the compressed data storage area of the logical block management table.

【0049】ここでは、説明を簡単にするために、圧縮
データは1バイトからなり、この値が「n」の場合はブ
ロックデータの全てのバイトが「n」であることを示
す。例えば、ホスト処理装置から0でクリアされたブロ
ックデータが書き込まれた場合は、フラグは「圧縮」と
なり、圧縮データは「0」となる。
Here, in order to simplify the explanation, the compressed data consists of 1 byte, and when this value is "n", it indicates that all the bytes of the block data are "n". For example, when the block data cleared by 0 is written from the host processing device, the flag becomes “compressed” and the compressed data becomes “0”.

【0050】フラグが「非圧縮」の場合は、その物理ブ
ロック番号の欄に記憶された物理ブロック番号で示され
る第2の記憶部9内の物理ブロックに非圧縮データが記
憶されている。
When the flag is "non-compressed", the non-compressed data is stored in the physical block in the second storage section 9 indicated by the physical block number stored in the physical block number column.

【0051】図5では、論理ブロック番号が「0」のブ
ロックデータは「非圧縮」に設定され、第2の記憶部9
内の物理ブロック番号が「0」の物理ブロックに記憶さ
れていることになる。
In FIG. 5, the block data whose logical block number is “0” is set to “uncompressed”, and the second storage unit 9
It means that the physical block number of the inside is stored in the physical block of "0".

【0052】論理ブロック番号が「1」のブロックデー
タは「圧縮」に設定され、従って、第1の記憶部8の論
理ブロック管理テーブル内の圧縮データ記憶領域に圧縮
された状態で記憶されていることになる。なお、圧縮デ
ータの値は「0」である。
The block data whose logical block number is "1" is set to "compressed", and is therefore stored in a compressed data storage area in the logical block management table of the first storage section 8 in a compressed state. It will be. The value of the compressed data is "0".

【0053】なお、このような構成のデータ記憶装置1
では、よくアクセスされる論理ブロック番号のブロック
データを第2の記憶部9の特定領域に集めて、ヘッドの
シーク時間を短縮するために、論理ブロック番号と物理
ブロック番号の対応をアクセス頻度により変えて、最適
化することも可能である。
The data storage device 1 having such a configuration
Then, in order to collect block data of logical block numbers that are frequently accessed in a specific area of the second storage unit 9 and to shorten the seek time of the head, the correspondence between logical block numbers and physical block numbers is changed according to the access frequency. It is also possible to optimize it.

【0054】図6は、図4のデータ記憶装置1全体の処
理動作を説明するためのフローチャートである。まず、
ステップS1に進み、データ処理装置1の初期化処理を
行い、その後、ホスト処理装置10から送信されるアク
セスコマンドを通信制御部5により受信し、各コマンド
に従った処理を行う(ステップS2)。なお、以下の説
明において、論理ブロック番号をLBNと表している。
FIG. 6 is a flow chart for explaining the processing operation of the entire data storage device 1 of FIG. First,
The process proceeds to step S1, the initialization process of the data processing device 1 is performed, and thereafter, the access command transmitted from the host processing device 10 is received by the communication control unit 5, and the process according to each command is performed (step S2). In the following description, the logical block number is represented as LBN.

【0055】アクセスコマンドが「読出し」の場合には
(ステップS3)、ホスト処理装置10よりLBNで指
定されるブロックデータを読み出してホスト処理装置1
0に送信する「読み出し処理」を行い(ステップS
4)、コマンド受信処理へ戻る。
If the access command is "read" (step S3), the block data designated by the LBN is read from the host processing device 10 and the host processing device 1 is read.
Perform "reading process" to send to 0 (step S
4) Return to the command receiving process.

【0056】アクセスコマンドが「書き込み」の場合に
は(ステップS5)、ホスト処理装置10から受信した
ブロックデータを指定されたLBNに対応する物理ブロ
ックへ書き込む「書き込み処理」を行い(ステップS
6)、コマンド受信処理へ戻る。
When the access command is "write" (step S5), "write processing" is performed to write the block data received from the host processor 10 to the physical block corresponding to the designated LBN (step S5).
6) Return to the command receiving process.

【0057】アクセスコマンドが「運用管理」の場合に
は(ステップS7)、「運用管理処理」を行い(ステッ
プS8)、コマンド受信処理へ戻る。運用管理処理に
は、データ記憶装置1の状態の問い合わせ、フォーマッ
トなどがあるが、ここでは詳細に説明しない。
When the access command is "operation management" (step S7), "operation management processing" is performed (step S8), and the processing returns to the command reception processing. The operation management process includes an inquiry about the state of the data storage device 1, a format, and the like, which will not be described in detail here.

【0058】アクセスコマンドが「終了」の場合には、
データ記憶装置1全体の処理動作を終了する。次に、図
7に示すフローチャートを参照して図6のステップS4
における読出処理について説明する。
When the access command is "end",
The processing operation of the entire data storage device 1 is ended. Next, referring to the flowchart shown in FIG. 7, step S4 in FIG.
The reading process in step S1 will be described.

【0059】まず、ステップS10に進み、第1の記憶
部8に記憶されている論理ブロック管理テーブル内のL
BNに対応するフラグを参照する。フラグが「非圧縮」
の場合は、論理ブロック管理テーブル内のLBNに対応
する物理ブロック番号を取り出し(ステップS11)、
第2の記憶部9からそのブロック番号のブロックデータ
を読み出し、ホストバッファ6へ転送する(ステップS
12)。
First, in step S10, L in the logical block management table stored in the first memory 8 is stored.
Reference the flag corresponding to BN. Flag is "uncompressed"
In the case of, the physical block number corresponding to the LBN in the logical block management table is extracted (step S11),
The block data of that block number is read from the second storage unit 9 and transferred to the host buffer 6 (step S
12).

【0060】フラグが「圧縮」の場合は、第1の記憶部
8に記憶されている論理ブロック管理テーブル内のLB
Nに対応する圧縮データを取り出し(ステップS1
3)、圧縮・伸張部7により、その圧縮データを伸長し
てからホストバッファ6へ転送する(ステップS1
4)。
When the flag is "compression", the LB in the logical block management table stored in the first storage unit 8 is used.
Extract the compressed data corresponding to N (step S1
3) The compression / decompression unit 7 decompresses the compressed data and transfers it to the host buffer 6 (step S1).
4).

【0061】そして、通信制御部5で、ホスト処理装置
10にホストバッファ6内の論理ブロックデータを送信
し(ステップS15)、処理を主プログラム(図6のス
テップS2)に戻す(ステップS16)。
Then, the communication control section 5 transmits the logical block data in the host buffer 6 to the host processing apparatus 10 (step S15), and returns the processing to the main program (step S2 in FIG. 6) (step S16).

【0062】次に、図8に示すフローチャートを参照し
て図6のステップS6における書き込み処理について説
明する。まず、ステップS20に進み、通信制御部5で
受信したホスト処理装置10から転送されたブロックデ
ータをホストバッファ6へ転送し、圧縮・伸張部7によ
りデータ圧縮処理を行う(ステップS21)。
Next, the write processing in step S6 of FIG. 6 will be described with reference to the flowchart shown in FIG. First, in step S20, the block data transferred from the host processing device 10 and received by the communication control unit 5 is transferred to the host buffer 6, and the compression / expansion unit 7 performs data compression processing (step S21).

【0063】次にブロックデータ圧縮後の圧縮データの
サイズを判定し(ステップS22)、サイズが1バイト
より大きい場合は、第1の記憶部8に記憶されている論
理ブロック管理テーブル内のLBNに対応する物理ブロ
ック番号を求め(ステップS23)、第2の記憶部9の
その物理ブロック番号に対応する物理ブロックにホスト
バッファ6内のブロックデータ(非圧縮データ)を書き
込み(ステップS24)、論理ブロック管理テーブル内
のフラグに「非圧縮」を設定し(ステップS25)、通
信制御部5により書き込み終了ステータスをホスト処理
装置10に送信して(ステップS26)、処理を主プロ
グラム(図6のステップS2)に戻す(ステップS2
7)。
Next, the size of the compressed data after block data compression is determined (step S22). If the size is larger than 1 byte, the LBN in the logical block management table stored in the first storage unit 8 is set. The corresponding physical block number is obtained (step S23), the block data (uncompressed data) in the host buffer 6 is written to the physical block corresponding to that physical block number in the second storage unit 9 (step S24), and the logical block The flag in the management table is set to "non-compressed" (step S25), the communication control unit 5 transmits the write end status to the host processing device 10 (step S26), and the process is executed by the main program (step S2 in FIG. 6). ) (Step S2)
7).

【0064】一方、ステップS22で、データ圧縮後の
圧縮データのサイズが1バイトの場合は、第1の記憶部
8に記憶されている論理ブロック管理テーブル内のLB
Nに対応する圧縮データの記憶領域に、1バイトの圧縮
データを格納して(ステップS28)、フラグに「圧
縮」と設定し(ステップS29)、書き込み終了ステー
タスをホスト処理装置に送信して(ステップS26)、
処理を主プログラム(図6のステップS2)に戻す(ス
テップS27)。
On the other hand, in step S22, if the size of the compressed data after data compression is 1 byte, the LB in the logical block management table stored in the first storage unit 8 is used.
One byte of compressed data is stored in the compressed data storage area corresponding to N (step S28), the flag is set to "compressed" (step S29), and the write end status is transmitted to the host processing device ( Step S26),
The process is returned to the main program (step S2 in FIG. 6) (step S27).

【0065】次に、図9に示すフローチャートを参照し
て図8のステップS21のデータ圧縮処理について説明
する。なお、説明を簡単にするために、最も簡単なデー
タ圧縮処理について説明する。
Next, the data compression processing of step S21 of FIG. 8 will be described with reference to the flowchart shown in FIG. For the sake of simplicity, the simplest data compression processing will be described.

【0066】まず、ステップS30に進み、変数iに1
の値を設定し、ホストバッファ6内の先頭のバイトデー
タ(図9において、ホストバッファ[0]で表す)とi
番目のバイトデータを比較する(ステップS31)。
First, in step S30, the variable i is set to 1
Of the first byte data in host buffer 6 (represented by host buffer [0] in FIG. 9) and i
The th byte data is compared (step S31).

【0067】等しい場合は、変数iを1づつ増加させな
がら(ステップS32)、1024以上になるまで比較
を行う(ステップS33)。全てのバイトデータが先頭
バイトデータと等しい場合は、圧縮データを先頭バイト
データとし(ステップS34)、圧縮サイズを1バイト
として、処理を副プログラム(図8のステップS22)
に戻す(ステップS35)。
If they are equal, the variable i is incremented by 1 (step S32), and the comparison is performed until 1024 or more (step S33). If all the byte data are equal to the start byte data, the compressed data is set to the start byte data (step S34), the compression size is set to 1 byte, and the process is a subprogram (step S22 in FIG. 8).
(Step S35).

【0068】1バイトでも異なるバイトデータが存在す
る場合は(ステップS31)、圧縮サイズを1より大と
して、処理を副プログラム(図8のステップS22)に
戻す(ステップS36)。
If different byte data exists even for 1 byte (step S31), the compression size is made larger than 1 and the process is returned to the subprogram (step S22 in FIG. 8) (step S36).

【0069】以上説明したように、上記第1の実施例に
よれば、ホスト処理装置10から送信されたブロックデ
ータをデータ記憶装置1に記憶する際、まず、そのブロ
ックデータを圧縮して、その結果得られた圧縮データの
サイズがあらかじめ定められてたサイズ(ここでは、1
バイト)以下の場合は、第1の記憶部8上にその圧縮デ
ータを格納し、圧縮データのサイズが大きい場合は、第
2の記憶部9に格納することで、アクセスの遅い第2の
記憶部9へのアクセス回数を減少させることが可能とな
り、従って、より高速な読出動作が可能となる。
As described above, according to the first embodiment, when the block data transmitted from the host processing device 10 is stored in the data storage device 1, the block data is first compressed and then stored. The size of the resulting compressed data is a predetermined size (here, 1
Byte) or less, the compressed data is stored in the first storage unit 8, and when the size of the compressed data is large, the compressed data is stored in the second storage unit 9, so that the second storage unit with slow access can be stored. It is possible to reduce the number of times of access to the unit 9, and thus a faster read operation is possible.

【0070】次に、第2の実施例について説明する。図
10は、前述の第2のデータ記憶方法を採用したデータ
記憶装置の構成を概略的に示したものである。なお、図
4と同一部分には、同一の符号を付し、説明は省略す
る。
Next, the second embodiment will be described. FIG. 10 schematically shows the configuration of a data storage device that adopts the second data storage method described above. The same parts as those in FIG. 4 are designated by the same reference numerals and the description thereof will be omitted.

【0071】図10において、データ記憶装置1は、L
AN等の通信回線11を介してホスト処理装置10と接
続されている。データ記憶装置1は、CPU2、HDD
3、メインメモリ4、通信制御部5、ホストバッファ
6、圧縮・伸長部7、第1の記憶部20、アクセサ制御
部21、光ディスク制御部22がシステムバス12に互
いに接続されて構成されている。
In FIG. 10, the data storage device 1 is L
It is connected to the host processing device 10 via a communication line 11 such as an AN. The data storage device 1 includes a CPU 2 and an HDD
3, a main memory 4, a communication control unit 5, a host buffer 6, a compression / decompression unit 7, a first storage unit 20, an accessor control unit 21, and an optical disk control unit 22 are connected to the system bus 12 and are configured. .

【0072】データ記憶装置1は、10M個のブロック
データ(総容量が10Gバイト)を可換記録媒体である
例えば、複数の光ディスク24とオートチェンジャーを
用いてブロックデータを記憶する第2の記憶部を具備す
るものである。
The data storage device 1 is a removable storage medium for storing 10M block data (total capacity is 10 Gbytes), for example, a second storage unit for storing block data by using a plurality of optical disks 24 and an autochanger. It is equipped with.

【0073】光ディスク24は1枚で1M個のブロック
データの記憶が可能で、光磁気ディスクのように書き換
え可能なデバイスを使用している。オートチェンジャー
は10個の格納セル25と1個の光ディスクドライブ2
3とアクセサ26とから構成されている。格納セルは光
ディスクを格納するためのものである。格納セル25は
番号「0」から「10」まであり、番号「0」の格納セ
ルは外部と光ディスク24を出し入れするための窓であ
り、番号「1」から「10」の10個の格納セル25に
光ディスク24を格納することができる。
The optical disc 24 is capable of storing 1M block data by itself and uses a rewritable device such as a magneto-optical disc. The autochanger has 10 storage cells 25 and 1 optical disk drive 2
3 and an accessor 26. The storage cell is for storing an optical disc. The storage cells 25 are numbered “0” to “10”, the storage cells numbered “0” are windows for loading / unloading the optical disk 24 to / from the outside, and the 10 storage cells numbered “1” to “10”. The optical disc 24 can be stored in 25.

【0074】なお、以下の説明では、複数の光ディスク
で構成される記憶領域を概念上、第2の記憶部と称す
る。HDD3、メインメモリ4、CPU2、圧縮・伸張
部7、通信制御部5、ホストバッファ6は図4と同様で
ある。
In the following description, a storage area composed of a plurality of optical disks is conceptually called a second storage section. The HDD 3, main memory 4, CPU 2, compression / expansion unit 7, communication control unit 5, and host buffer 6 are the same as those in FIG.

【0075】第1の記憶部20は、例えば、バッテリバ
ックアップ式のメモリで、論理ブロック管理テーブル、
物理ブロック管理テーブルおよびその他の管理テーブル
を記憶するようになっている。図4と同様に、論理ブロ
ック管理テーブル内には、圧縮データ記憶部が含まれて
いる。
The first storage unit 20 is, for example, a battery backup type memory, and includes a logical block management table,
The physical block management table and other management tables are stored. Similar to FIG. 4, the logical block management table includes a compressed data storage unit.

【0076】光ディスクドライブ23は、光ディスク2
4への書き込みと読み出しを行うものであり、光ディス
クドライブ制御部22により光ディスクドライブ23が
制御されている。
The optical disk drive 23 is used for the optical disk 2
The optical disc drive control unit 22 controls the optical disc drive 23.

【0077】アクセサ26は、格納セル25と光ディス
クドライブ23間で光ディスク24を移動させるもので
あり、アクセサ制御部21により制御される。なお、図
10では、オートチェンジャー内には総論理ブロック数
の半分に相当する光ディスクが5枚しか投入されていな
い。この5枚の光ディスク24については、それぞれ、
光ディスク番号として「0」から「4」までが付されて
いる。
The accessor 26 moves the optical disk 24 between the storage cell 25 and the optical disk drive 23, and is controlled by the accessor controller 21. Incidentally, in FIG. 10, only five optical disks corresponding to half the total number of logical blocks are loaded in the autochanger. For each of the five optical disks 24,
"0" to "4" are added as optical disk numbers.

【0078】図11は、第1の記憶部8における論理ブ
ロック管理テーブルの記憶例を示したものである。図1
1において、論理ブロック管理テーブルは、連続した全
ての論理ブロック番号について、それぞれ、フラグ、物
理ブロック番号、圧縮データを記憶する領域が割り当て
られている。
FIG. 11 shows a storage example of the logical block management table in the first storage section 8. FIG.
1, in the logical block management table, areas for storing flags, physical block numbers, and compressed data are assigned to all consecutive logical block numbers.

【0079】フラグは、ブロックデータが第1の記憶部
8、第2の記憶部のうちいずれに記憶されているかを示
すもので、指定された論理ブロック番号のフラグ欄に
「圧縮」が記憶されている場合は、圧縮データがこのテ
ーブル内の圧縮データの欄に記憶されている。
The flag indicates whether the block data is stored in the first storage unit 8 or the second storage unit, and "compression" is stored in the flag column of the designated logical block number. If so, the compressed data is stored in the column of compressed data in this table.

【0080】圧縮データは1バイトからなり、この値が
「n」の場合、ブロックデータの全てのバイトが「n」
であることを示す。例えば、ホスト処理装置10から0
でクリアされたブロックデータが書き込まれた場合は、
フラグ欄には「圧縮」が記憶され、圧縮データは「0」
となる。
The compressed data consists of 1 byte. When this value is "n", all bytes of the block data are "n".
Is shown. For example, from the host processor 10 to 0
When the block data cleared by is written,
"Compressed" is stored in the flag field, and compressed data is "0".
Becomes

【0081】フラグが「非圧縮」の場合は、その物理ブ
ロック番号欄に示される第2の記憶部内の物理ブロック
に非圧縮データが記憶されている。物理ブロック番号か
ら光ディスク番号と各光ディスク内のブロック番号への
求め方は例えば、以下の通りである。
When the flag is "non-compressed", non-compressed data is stored in the physical block in the second storage section shown in the physical block number column. For example, the method for obtaining the optical disk number and the block number in each optical disk from the physical block number is as follows.

【0082】 (物理ブロック番号)/1M(光ディスク1枚当りの記憶容量)・・・(2) 光ディスク番号=(2)式の商 ブロック番号=(2)式の剰余 また、ブロックデータが圧縮されて記憶されている場合
は、論理ブロック管理テーブルの対応する物理ブロック
番号欄には「−1」が設定される。これは、この論理ブ
ロック番号には物理ブロックが割り当てられていないこ
とを示す。
(Physical block number) / 1M (storage capacity per optical disc) (2) Optical disc number = quotient of formula (2) Block number = remainder of formula (2) Further, block data is compressed. Stored in the logical block management table, "-1" is set in the corresponding physical block number column. This indicates that no physical block is assigned to this logical block number.

【0083】このように、第1の実施例では、全ての論
理ブロックに対して物理ブロックが割り当てられていた
が、この第2の実施例では必要に応じて第2の記憶部に
物理ブロックを割り当てることで、光ディスクの使用枚
数を節約している。
As described above, in the first embodiment, the physical blocks are assigned to all the logical blocks, but in the second embodiment, the physical blocks are allocated to the second storage section as needed. By allocating, the number of used optical disks is saved.

【0084】図12は、第1の記憶部8における物理ブ
ロック管理テーブルの記憶例を示したものである。この
テーブルは、各物理ブロックがどの光ディスク上のブロ
ックに割当てられているか、さらに、割当てられている
場合は、論理ブロックの非圧縮データが記録されている
かを示すものである。第2の実施例では、第2の記憶部
としてのオートチェンジャー内に光ディスクが5枚投入
されているため、論理ブロック数の計10M個の内、半
分の5M個分の物理ブロック(物理ブロック番号が0か
ら5M−1)に対して光ディスク上のブロックが割り当
てられている。
FIG. 12 shows an example of storage of the physical block management table in the first storage section 8. This table indicates on which optical disk each physical block is allocated, and if so, whether the non-compressed data of the logical block is recorded. In the second embodiment, since five optical disks are loaded in the autochanger as the second storage unit, half of 5M physical blocks (physical block number is 10M) out of the total 10M logical blocks. Blocks on the optical disk are allocated to 0 to 5M-1).

【0085】物理ブロック管理テーブルのフラグが「使
用」の物理ブロックは、その光ディスク上のブロックが
割当てられ、かつ、論理ブロックのブロックデータが記
録されていることを示す。例えば、図12において、物
理ブロック番号が「0」の物理ブロックには「0」番目
の光ディスクの0番目のブロックが割り当てられ、図1
1の論理ブロック管理テーブルからLBNが0の論理ブ
ロックのブロックデータが記憶されていることが分か
る。
A physical block whose flag in the physical block management table is "used" indicates that the block on the optical disk is allocated and the block data of the logical block is recorded. For example, in FIG. 12, the 0th block of the “0” th optical disc is allocated to the physical block having the physical block number “0”, and the physical block of FIG.
It can be seen from the logical block management table of 1 that the block data of the logical block of which LBN is 0 is stored.

【0086】フラグが「未使用」の物理ブロックは、光
ディスク上のブロックが割当てられているが、まだ論理
ブロックのブロックデータは記憶されていないことを示
す。フラグが「未割当」の物理ブロックは、光ディスク
上のブロックが割り当てられていないことを示す。
The physical block whose flag is "unused" indicates that the block on the optical disk is allocated, but the block data of the logical block is not stored yet. A physical block whose flag is "unallocated" indicates that the block on the optical disk is not allocated.

【0087】物理ブロック管理テーブルの物理ブロック
番号が5Mから10M−1の物理ブロックのフラグ欄に
は、光ディスク上のブロックが割り当てられていないこ
とを意味する「未割当」が記憶されている。
In the flag column of the physical blocks having physical block numbers 5M to 10M-1 in the physical block management table, "unallocated" which means that the block on the optical disk is not allocated is stored.

【0088】図13は、第1の記憶部8における光ディ
スク管理テーブルの記憶例を示したものである。このテ
ーブルは各光ディスク24に対応するオートチェンジャ
ー内の格納セル番号を管理するものである。第2の実施
例では5枚の光ディスク24のそれぞれの格納セル番号
が記憶されている。光ディスク24が光ディスクドライ
ブ23から外された時、この番号で示される格納セル2
5に格納される。格納セル番号が「−1」で示されると
ころは、光ディスク24がまだオートチェンジャーに投
入されていないことを示す。
FIG. 13 shows an example of storage of the optical disc management table in the first storage section 8. This table manages the storage cell number in the autochanger corresponding to each optical disk 24. In the second embodiment, the storage cell numbers of the five optical disks 24 are stored. When the optical disk 24 is removed from the optical disk drive 23, the storage cell 2 indicated by this number
Stored in 5. The storage cell number indicated by "-1" indicates that the optical disc 24 has not been inserted into the autochanger.

【0089】図14は、第1の記憶部8における光ディ
スクドライブ管理テーブルの記憶例で、光ディスクドラ
イブ23に装填されている光ディスクの番号を管理する
ものである。
FIG. 14 is a storage example of the optical disk drive management table in the first storage section 8 for managing the numbers of the optical disks loaded in the optical disk drive 23.

【0090】図10のデータ記憶装置1全体の処理動作
は、図6と同様である。次に、図15に示すフローチャ
ートを参照して、第2の実施例における図6のステップ
S4の読み出し処理について説明する。
The processing operation of the entire data storage device 1 of FIG. 10 is the same as that of FIG. Next, with reference to the flow chart shown in FIG. 15, the read processing of step S4 of FIG. 6 in the second embodiment will be described.

【0091】まず、ステップS40に進み、第1の記憶
部20に記憶されている論理ブロック管理テーブル内の
LBNに対応するフラグを参照する。フラグが「非圧
縮」の場合は、論理ブロック管理テーブル内のLBNに
対応する物理ブロック番号を取り出し、前述の式(2)
をもとに、物理ブロック番号から光ディスク番号とその
光ディスク内のブロック番号を求める(ステップS4
1)。
First, in step S40, the flag corresponding to the LBN in the logical block management table stored in the first storage unit 20 is referenced. If the flag is "non-compressed", the physical block number corresponding to the LBN in the logical block management table is extracted, and the above-mentioned formula (2) is used.
Based on the physical block number, the optical disc number and the block number within the optical disc are obtained (step S4).
1).

【0092】そして、第1の記憶部20に記憶されてい
る光ディスク管理テーブル、および光ディスクドライブ
管理テーブルを参照して、光ディスクドライブ23に該
当の番号の光ディスクが装填されていないときは、アク
セサ制御部21による制御のもとアクセサ26を駆動し
て該当の格納セル25から、該当の番号の光ディスク2
4を取り出して、光ディスクドライブ23にその光ディ
スク24を装填する(ステップS42)。
Then, referring to the optical disk management table and the optical disk drive management table stored in the first storage section 20, when the optical disk of the corresponding number is not loaded in the optical disk drive 23, the accessor control section The accessor 26 is driven under the control of the optical disc 21 and the optical disk 2 of the corresponding number is read from the corresponding storage cell 25.
4 is taken out and the optical disk 24 is loaded into the optical disk drive 23 (step S42).

【0093】そして、光ディスクドライブ制御部22の
制御のもと、光ディスクドライブ23を駆動して、該当
の光ディスク24から物理ブロック番号で示されるブロ
ックデータを読み出し、ホストバッファ6へ転送する
(ステップS43)。
Then, under the control of the optical disk drive controller 22, the optical disk drive 23 is driven to read the block data indicated by the physical block number from the corresponding optical disk 24, and the block data is transferred to the host buffer 6 (step S43). .

【0094】ステップS40で、フラグが「圧縮」の場
合は、論理ブロック管理テーブル内のLBNに対応する
圧縮データを取り出し(ステップS44)、圧縮・伸張
部7で伸長した後、ホストバッファ6にを転送する(ス
テップS45)。
If the flag is "compressed" in step S40, the compressed data corresponding to the LBN in the logical block management table is extracted (step S44), decompressed by the compression / decompression unit 7, and then stored in the host buffer 6. Transfer (step S45).

【0095】そして、通信制御部5によりホスト処理装
置10にホストバッファ6内のブロックデータを送信し
(ステップS46)、処理を主プログラム(図6のステ
ップS2)に戻す(ステップS47)。
Then, the block data in the host buffer 6 is transmitted to the host processor 10 by the communication controller 5 (step S46), and the process is returned to the main program (step S2 of FIG. 6) (step S47).

【0096】次に、図16に示すフローチャートを参照
して、第2の実施例における図6のステップS6の書き
込み処理について説明する。まず、ホスト処理装置から
送信されたブロックデータを通信制御部5で受信し、ホ
ストバッファ6へ転送し(ステップS50)、圧縮・伸
張部7でデータ圧縮処理を行う(ステップS51)。こ
のときのデータ圧縮処理は、例えば、図9に示したもの
である。その後、データ圧縮後の圧縮データのサイズを
判定する(ステップS52)。
Next, the write processing of step S6 of FIG. 6 in the second embodiment will be described with reference to the flow chart shown in FIG. First, the block data transmitted from the host processing device is received by the communication control unit 5, transferred to the host buffer 6 (step S50), and the compression / expansion unit 7 performs data compression processing (step S51). The data compression processing at this time is, for example, that shown in FIG. Then, the size of the compressed data after data compression is determined (step S52).

【0097】サイズが1バイトより大きい場合は、既に
LBNで示される論理ブロック番号に対応して物理ブロ
ックが割り当てられているかを調べるために、第1の記
憶部20に記憶されている論理ブロック管理テーブル上
のLBNに対応する物理ブロック番号を得る(ステップ
S53)。
If the size is larger than 1 byte, the logical block management stored in the first storage unit 20 is checked in order to check whether the physical block is already allocated corresponding to the logical block number indicated by LBN. The physical block number corresponding to the LBN on the table is obtained (step S53).

【0098】その際、物理ブロック番号の記憶領域の値
が「−1」ならば(ステップS54)、物理ブロックが
割り当てられていないので、物理ブロック割当処理を行
い(ステップS55)、その後、論理ブロック管理テー
ブル上のLBNに対応する物理ブロック番号に割り当て
られた物理ブロック番号を設定し(ステップS56)、
物理ブロック管理テーブル上の物理ブロック番号に対応
するフラグに「使用」を設定する(ステップS57)。
At this time, if the value of the storage area of the physical block number is "-1" (step S54), the physical block is not allocated, so the physical block allocation processing is performed (step S55), and then the logical block is allocated. The physical block number assigned to the physical block number corresponding to the LBN on the management table is set (step S56),
"Use" is set to the flag corresponding to the physical block number on the physical block management table (step S57).

【0099】ステップS54で、物理ブロック番号の記
憶領域の値が「−1」でないならば、すでに物理ブロッ
クが割当済みであるので、ステップS55の物理ブロッ
ク割当処理をスキップしてステップS58に進む。
If the value of the storage area of the physical block number is not "-1" in step S54, the physical block has already been allocated, so the physical block allocation process of step S55 is skipped and the process proceeds to step S58.

【0100】次に、前述の式(2)を基に、物理ブロッ
ク番号から光ディスク番号とこの光ディスク内のブロッ
ク番号を求め(ステップS58)、この光ディスクが装
填されていなければ、装填を行う(ステップS59)。
そして、光ディスクドライブ23を駆動して、ブロック
番号で示されるブロックへホストバッファ6内の非圧縮
データを書き込む(ステップS60)。その後、論理ブ
ロック管理テーブル上のLBNに対応するフラグに「非
圧縮」を設定し(ステップS61)、通信制御部5によ
り、書き込み終了ステータスをホスト処理装置10へ送
信して(ステップS62)、主プログラム(図6のステ
ップS2)に戻す(ステップS63)。
Next, based on the equation (2), the optical disk number and the block number in this optical disk are obtained from the physical block number (step S58), and if this optical disk is not loaded, it is loaded (step S58). S59).
Then, the optical disk drive 23 is driven to write the uncompressed data in the host buffer 6 to the block indicated by the block number (step S60). After that, the flag corresponding to the LBN on the logical block management table is set to "non-compressed" (step S61), and the communication control unit 5 transmits the write end status to the host processing device 10 (step S62). It returns to the program (step S2 of FIG. 6) (step S63).

【0101】ステップS52で、データ圧縮後の圧縮デ
ータのサイズが1バイトの場合は、既にLBNで示され
るブロックデータに物理ブロックが割り当てられている
かを調べるために、論理ブロック管理テーブル上のLB
Nに対応する物理ブロック番号を得る(ステップS6
4)。物理ブロック番号の記憶領域の値が「−1」以外
ならば(ステップS65)、物理ブロックが割り当てら
れているので物理ブロックを解放するために、論理ブロ
ック管理テーブル上のLBNに対応する物理ブロック番
号に「−1」を設定し(ステップS66)、物理ブロッ
ク管理テーブル上の物理ブロック番号に対応するフラグ
に「未使用」を設定する(ステップS67)。その後、
論理ブロック管理テーブル内のLBNに対応する圧縮デ
ータの記憶領域に1バイトの圧縮データを設定し(ステ
ップS68)、フラグに「圧縮」と設定し(ステップS
69)、書き込み終了ステータスをホスト処理装置に送
信して、(ステップS62)、処理を主プログラム(図
6のステップS2)に戻す(ステップS63)。
In step S52, if the size of the compressed data after data compression is 1 byte, the LB on the logical block management table is checked to see if a physical block has already been allocated to the block data indicated by LBN.
Obtain the physical block number corresponding to N (step S6)
4). If the value of the storage area of the physical block number is other than "-1" (step S65), since the physical block is allocated, the physical block number corresponding to the LBN on the logical block management table is released to release the physical block. Is set to "-1" (step S66), and "unused" is set to the flag corresponding to the physical block number on the physical block management table (step S67). afterwards,
One byte of compressed data is set in the compressed data storage area corresponding to the LBN in the logical block management table (step S68), and the flag is set to "compressed" (step S68).
69), the write end status is transmitted to the host processing device (step S62), and the process is returned to the main program (step S2 in FIG. 6) (step S63).

【0102】次に、図17に示すフローチャートを参照
して図16のステップS55における物理ブロック割当
処理について説明する。まず、第1の記憶部20に記憶
されている物理ブロック管理テーブル内からフラグが
「未使用」である物理ブロックを探す(ステップS7
0)。見つかった場合は(ステップS71)、その割当
物理ブロックの番号を物理ブロック番号として(ステッ
プS76)、副プログラム(図16のステップS56)
に戻す(ステップS76)。
Next, the physical block allocation processing in step S55 of FIG. 16 will be described with reference to the flowchart shown in FIG. First, the physical block management table stored in the first storage unit 20 is searched for a physical block whose flag is "unused" (step S7).
0). If found (step S71), the assigned physical block number is used as the physical block number (step S76), and the subprogram (step S56 in FIG. 16) is executed.
(Step S76).

【0103】ステップS71で見つからなかった場合
は、運用管理者に新規の光ディスクをオートチェンジャ
ーに投入するように指示し、オートチェンジャーの出入
口からに投入してもらう(ステップS72)。そして、
第1の記憶部20に記憶されている光ディスク管理テー
ブル上の格納セル番号が「−1」である行を選択し、そ
の格納セル番号に対応する光ディスク番号の欄に光ディ
スク番号を設定し、オートチェンジャーの出入口にある
新規の光ディスクをその格納セル番号で示される格納セ
ル25に移動する(ステップS73)。これで光ディス
ク1枚分の物理ブロック用の記憶デバイスが追加された
ので、物理ブロック管理テーブル上のフラグが「未割
当」である最上行から光デバイス1枚分の容量である1
M分の物理ブロックを割り当てて、そのフラグに「未使
用」を設定し(ステップS74)、フラグが「未使用」
である物理ブロックの番号を副プログラム(図16のス
テップS56)に戻す(ステップS75、S76)。
If the optical disc is not found in step S71, the operation manager is instructed to insert a new optical disk into the autochanger, and the operator is asked to insert the optical disk from the entrance / exit of the autochanger (step S72). And
The row having the storage cell number “−1” on the optical disc management table stored in the first storage unit 20 is selected, and the optical disc number is set in the optical disc number column corresponding to the storage cell number. The new optical disk at the entrance / exit is moved to the storage cell 25 indicated by the storage cell number (step S73). Since a storage device for physical blocks for one optical disk has been added, the capacity for one optical device from the top row where the flag on the physical block management table is "unallocated" is 1
Allocating physical blocks for M and setting the flag to "unused" (step S74), the flag is set to "unused".
The number of the physical block is returned to the subprogram (step S56 in FIG. 16) (steps S75 and S76).

【0104】以上説明したように、上記第2の実施例に
よれば、ホスト処理装置10から送信されたブロックデ
ータをデータ記憶装置1に記憶する際、まず、そのブロ
ックデータを圧縮して、その結果得られた圧縮データの
サイズがあらかじめ定められてたサイズ(ここでは、1
バイト)よりも大きい場合のみ、第2の記憶部としての
光ディスク20上に物理ブロックを割り当てるようにす
ることで、使用する光ディスクを節約することが可能で
ある。特に、データ記憶装置1の運用開始時に、装填す
べき光ディスクが10枚なくても運用を開始することが
可能となる。
As described above, according to the second embodiment, when the block data transmitted from the host processing device 10 is stored in the data storage device 1, the block data is first compressed and then stored. The size of the resulting compressed data is a predetermined size (here, 1
It is possible to save the optical disk to be used by allocating the physical block on the optical disk 20 as the second storage unit only when the physical block is larger than the (byte). In particular, when the operation of the data storage device 1 is started, the operation can be started even if there are not 10 optical disks to be loaded.

【0105】尚、データ圧縮処理は、図9を参照して説
明したように、ブロックデータ内の全てのデータが同じ
値の場合、圧縮後のサイズを数バイトにすることが可能
となるものを用いているが、これに限らず、バイトまた
はワード単位のランレングス符号を採用しても、また、
他の圧縮方法を採用しても有効である。しかし、できる
だけ高速なデータ圧縮・伸張方式は採用することが望ま
しい。特に、前述の第1、第2の実施例のように、ブロ
ック単位にデータの記憶、読出を行うデータ記憶装置に
おいては、装置運用開始時のフォーマット処理では、ブ
ロックを全て0でクリアする処理が多く、簡単なバイト
単位でのランレングス符号を用いても、物理ブロック記
憶部へのアクセス回数を減らし、性能を高めることが可
能となる。
As described with reference to FIG. 9, in the data compression processing, if all the data in the block data have the same value, it is possible to reduce the size after compression to several bytes. Although it is used, not limited to this, even if a run length code of byte or word is adopted,
It is effective to adopt other compression methods. However, it is desirable to adopt the fastest possible data compression / decompression method. Particularly, in the data storage device that stores and reads data in block units as in the first and second embodiments described above, in the formatting process at the start of device operation, the process of clearing all blocks to 0 is required. Even with many simple byte-length run length codes, it is possible to reduce the number of accesses to the physical block storage unit and improve the performance.

【0106】また、ブロックデータの書き込み処理にお
いて、圧縮サイズを比較する際、上記第1、第2の実施
例では、基準となるデータサイズを1バイトと定義した
が、この場合に限らず、ブロックデータのサイズ、ある
いは、データ圧縮処理に応じて、適宜定義できるもので
ある。
In the block data writing process, when the compressed sizes are compared, the reference data size is defined as 1 byte in the first and second embodiments, but the present invention is not limited to this case. It can be appropriately defined according to the size of the data or the data compression processing.

【0107】[0107]

【発明の効果】以上、説明したように本発明によれば、
アクセスが低速な物理ブロック記憶部へのアクセス回数
の低減を図り、より高速なデータの読出しと、物理ブロ
ック記憶部の記憶容量の低減が可能なデータ記憶装置お
よびデータ記憶方法を提供できる。
As described above, according to the present invention,
It is possible to provide a data storage device and a data storage method capable of reducing the number of times of access to a physical block storage unit having a low access speed, reading data at a higher speed, and reducing the storage capacity of the physical block storage unit.

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

【図1】本発明の第1のデータ記憶方法の原理を説明す
るための図。
FIG. 1 is a diagram for explaining the principle of a first data storage method of the present invention.

【図2】ランレングス符号を説明するための図。FIG. 2 is a diagram for explaining a run length code.

【図3】本発明の第2のデータ記憶方法の原理を説明す
るための図。
FIG. 3 is a diagram for explaining the principle of the second data storage method of the present invention.

【図4】本発明の第1の実施例に係るデータ記憶装置の
構成を概略的に示した図。
FIG. 4 is a diagram schematically showing a configuration of a data storage device according to a first embodiment of the present invention.

【図5】論理ブロック管理テーブルの記憶例を示した
図。
FIG. 5 is a diagram showing an example of storage of a logical block management table.

【図6】図4のデータ記憶装置の全体の処理動作を説明
するためのフローチャート。
FIG. 6 is a flowchart for explaining the overall processing operation of the data storage device of FIG.

【図7】読出処理について説明するためのフローチャー
ト。
FIG. 7 is a flowchart illustrating a read process.

【図8】書込処理について説明するためのフローチャー
ト。
FIG. 8 is a flowchart for explaining a writing process.

【図9】データ圧縮処理について説明するためのフロー
チャート。
FIG. 9 is a flowchart illustrating a data compression process.

【図10】本発明の第2の実施例に係るデータ記憶装置
の構成を概略的に示した図。
FIG. 10 is a diagram schematically showing a configuration of a data storage device according to a second embodiment of the present invention.

【図11】論理ブロック管理テーブルの記憶例を示した
図。
FIG. 11 is a diagram showing a storage example of a logical block management table.

【図12】物理ブロック管理テーブルの記憶例を示した
図。
FIG. 12 is a diagram showing a storage example of a physical block management table.

【図13】光ディスク管理テーブルの記憶例を示した
図。
FIG. 13 is a diagram showing a storage example of an optical disc management table.

【図14】光ディスクドライブ管理テーブルの記憶例を
示した図。
FIG. 14 is a diagram showing a storage example of an optical disc drive management table.

【図15】読出処理について説明するためのフローチャ
ート。
FIG. 15 is a flowchart illustrating a read process.

【図16】書込処理について説明するためのフローチャ
ート。
FIG. 16 is a flowchart for explaining a writing process.

【図17】物理ブロック割当処理について説明するため
のフローチャート。
FIG. 17 is a flowchart illustrating a physical block allocation process.

【図18】従来のデータ記憶方法の原理について説明す
るための図。
FIG. 18 is a diagram for explaining the principle of a conventional data storage method.

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

1…データ記憶装置、2…CPU、3…ハードディスク
ドライブ(HDD)、4…メインメモリ、5…通信制御
部、6…ホストバッファ、7…圧縮・伸長部、8…第1
の記憶部、9…第2の記憶部、10…ホスト処理装置、
11…通信回線、12…システムバス。
1 ... Data storage device, 2 ... CPU, 3 ... Hard disk drive (HDD), 4 ... Main memory, 5 ... Communication control unit, 6 ... Host buffer, 7 ... Compression / decompression unit, 8 ... First
Storage unit, 9 ... second storage unit, 10 ... host processing device,
11 ... communication line, 12 ... system bus.

Claims (6)

【特許請求の範囲】[Claims] 【請求項1】 あらかじめ割当てられたブロック単位の
データを記憶する物理ブロックにアクセスして前記デー
タの記憶、読出しを行うデータ記憶装置であって、 前記ブロック単位のデータを記憶する際、そのブロック
単位のデータを圧縮する圧縮手段と、 この圧縮手段で圧縮された圧縮データのデータ長があら
かじめ定められた値以下のとき、前記圧縮データを高速
なアクセスが可能なメモリに記憶するよう制御を行う第
1の制御手段と、 前記圧縮手段で圧縮された圧縮データのデータ長があら
かじめ定められた値よりも大きいとき、前記ブロック単
位のデータを前記物理ブロックに記憶するよう制御を行
う第2の制御手段と、 ブロック単位のデータを読出す際、指定された前記ブロ
ック単位のデータが前記メモリあるいは前記物理ブロッ
クのいずれに記憶されているかを判断する判断手段と、 この判断手段で前記メモリに記憶されていることが判断
されたとき、前記メモリに記憶されているブロック単位
の圧縮データを伸張して読出すよう制御を行う第3の制
御手段と、 前記判断手段で前記物理ブロックに記憶されていること
が判断されたとき、前記物理ブロックから前記ブロック
単位のデータを読出すよう制御を行う第4の制御手段
と、 を具備したことを特徴とするデータ記憶装置。
1. A data storage device that stores and reads the data by accessing a physical block that stores data of a block unit allocated in advance, wherein the block unit is stored when the data of the block unit is stored. And a compression means for compressing the data, and performing control to store the compressed data in a memory that can be accessed at high speed when the data length of the compressed data compressed by the compression means is equal to or less than a predetermined value. No. 1 control means, and second control means for performing control so as to store the data in block units in the physical block when the data length of the compressed data compressed by the compression means is larger than a predetermined value. When reading data in block units, the specified data in block units is stored in the memory or the physical block. And a determination means for determining which of the stored data is stored in the memory, and when the determination means determines that the data is stored in the memory, the compressed data in block units stored in the memory is expanded and read. A third control means for controlling to output the data, and a fourth control means for controlling to read the data in block units from the physical block when the determination means determines that the data is stored in the physical block. A data storage device comprising: a control unit.
【請求項2】 所定のブロック単位のデータが連続した
論理ブロック番号で管理され、その論理ブロック番号に
割当てられた前記ブロック単位のデータを記憶する物理
ブロックにアクセスして前記データの記憶、読出しを行
うデータ記憶装置であって、 指定された論理ブロック番号の前記ブロック単位のデー
タを記憶する際、そのブロック単位のデータを圧縮して
圧縮データを求める圧縮手段と、 この圧縮手段で求められた圧縮データのデータ長があら
かじめ定められた値以下のとき、前記圧縮データを前記
指定された論理ブロック番号に対応させて、高速なアク
セスが可能なメモリに記憶するよう制御を行う第1の制
御手段と、 前記圧縮手段で求められた圧縮データのデータ長があら
かじめ定められた値よりも大きいとき、前記指定された
論理ブロック番号に対して前記物理ブロックを割当てる
割当手段と、 この割当手段で前記指定された論理ブロック番号に対し
て割当てられた物理ブロックに前記ブロック単位のデー
タを記憶するよう制御を行う第2の制御手段と、 指定された論理ブロック番号のブロック単位のデータを
読出す際、前記指定された論理ブロック番号を基に、前
記ブロック単位のデータが前記メモリあるいは前記物理
ブロックのいずれに記憶されているかを判断する判断手
段と、 この判断手段で前記メモリに記憶されていることが判断
されたとき、前記メモリから前記指定された物理ブロッ
ク番号に対応する圧縮データを伸張して読出すよう制御
を行う第3の制御手段と、 前記判断手段で前記物理ブロックに記憶されていること
が判断されたとき、前記指定された論理ブロック番号に
対して割当てられた物理ブロックから前記ブロック単位
のデータを読出すよう制御を行う第4の制御手段と、 を具備したことを特徴とするデータ記憶装置。
2. Data of a predetermined block unit is managed by consecutive logical block numbers, and a physical block for storing the data of the block unit allocated to the logical block number is accessed to store and read the data. A data storage device for performing, when storing data of the block unit having a designated logical block number, compressing the data of the block unit to obtain compressed data, and a compression unit obtained by the compression unit. When the data length of the data is equal to or less than a predetermined value, the compressed data is associated with the designated logical block number and is controlled to be stored in a memory that can be accessed at high speed. When the data length of the compressed data obtained by the compression means is larger than a predetermined value, the specified Allocation means for allocating the physical block to the logical block number, and second control for storing the data in block units in the physical block allocated to the specified logical block number by the allocation means When the control unit and the data in the block unit of the designated logical block number is read, whether the data in the block unit is stored in the memory or the physical block based on the designated logical block number. And a control means for decompressing and reading compressed data corresponding to the specified physical block number from the memory when the determination means determines that the data is stored in the memory. When the third control means and the determination means determine that the data is stored in the physical block, the specified A fourth control means for performing control so as to read the data in block units from the physical block assigned to the assigned logical block number, the data storage device.
【請求項3】 所定のブロック単位のデータが連続した
論理ブロック番号で管理され、その論理ブロック番号に
対してあらかじめ割当てられた前記ブロック単位のデー
タを記憶する物理ブロックにアクセスして前記データの
記憶、読出を行うデータ記憶方法であって、 指定された論理ブロック番号の前記ブロック単位のデー
タを記憶する際、そのブロック単位のデータを圧縮して
圧縮データを求め、その圧縮データのデータ長があらか
じめ定められた値以下のとき、前記圧縮データを前記指
定された論理ブロック番号に対応させて、高速なアクセ
スが可能なメモリに記憶し、前記圧縮データのデータ長
があらかじめ定められた値よりも大きいとき、前記ブロ
ック単位のデータを前記指定された論理ブロック番号に
割当てられた物理ブロックに記憶し、指定された論理ブ
ロック番号のブロック単位のデータを読出す際、前記指
定された論理ブロック番号を基に、前記メモリあるいは
前記物理ブロックのいずれに記憶されているかを判断
し、前記メモリに記憶されていることが判断されたと
き、前記メモリから前記指定された物理ブロック番号に
対応する圧縮データを伸張して読出し、前記物理ブロッ
クに記憶されていることが判断されたとき、前記指定さ
れた論理ブロック番号に割当てられた物理ブロックから
前記ブロック単位のデータを読出すことを特徴とするデ
ータ記憶方法。
3. Data of a predetermined block unit is managed by consecutive logical block numbers, and a physical block for storing the data of the block unit pre-allocated to the logical block number is accessed to store the data. , A data storage method for reading, wherein when storing the data in block units of a specified logical block number, the data in block units is compressed to obtain compressed data, and the data length of the compressed data is set in advance. When the value is less than or equal to a predetermined value, the compressed data is stored in a memory that can be accessed at high speed in association with the specified logical block number, and the data length of the compressed data is larger than a predetermined value. At this time, the data of the block unit is transferred to the physical block assigned to the specified logical block number. When reading the data of the block unit of the designated logical block number, it is determined whether the memory is stored in the memory or the physical block based on the designated logical block number, and the data is stored in the memory. When it is determined that it is stored, the compressed data corresponding to the specified physical block number is decompressed and read from the memory, and when it is determined that it is stored in the physical block, the specified data is stored. A data storage method comprising reading the data in block units from a physical block assigned to the logical block number.
【請求項4】 所定のブロック単位のデータが連続した
論理ブロック番号で管理され、その論理ブロック番号に
割当てられた前記ブロック単位のデータを記憶する物理
ブロックにアクセスして前記データの記憶、読出しを行
うデータ記憶方法であって、 指定された論理ブロック番号の前記ブロック単位のデー
タを記憶する際、そのブロック単位のデータを圧縮して
圧縮データを求め、その圧縮データのデータ長があらか
じめ定められた値以下のとき、前記圧縮データを前記指
定された論理ブロック番号に対応させて、高速なアクセ
スが可能なメモリに記憶し、前記圧縮データのデータ長
があらかじめ定められた値よりも大きいとき、前記指定
された論理ブロック番号に対して前記物理ブロックを割
当て、その割当てられた物理ブロックに前記ブロック単
位のデータを記憶し、指定された論理ブロック番号のブ
ロック単位のデータを読出す際、前記指定された論理ブ
ロック番号を基に、前記ブロック単位のデータが前記メ
モリあるいは前記物理ブロックのいずれに記憶されてい
るかを判断し、前記メモリに記憶されていることが判断
されたとき、前記メモリから前記指定された物理ブロッ
ク番号に対応する圧縮データを伸張して読出し、前記物
理ブロックに記憶されていることが判断されたとき、前
記指定された論理ブロック番号に対して割当てられた物
理ブロックから前記ブロック単位のデータを読出すこと
を特徴とするデータ記憶方法。
4. Data of a predetermined block unit is managed by consecutive logical block numbers, and a physical block for storing the data of the block unit allocated to the logical block number is accessed to store and read the data. A method of storing data, wherein when storing the data in block units of a designated logical block number, the data in block units is compressed to obtain compressed data, and the data length of the compressed data is predetermined. When the value is less than or equal to a value, the compressed data is stored in a memory that can be accessed at high speed in association with the designated logical block number, and when the data length of the compressed data is larger than a predetermined value, the The physical block is assigned to a specified logical block number, and the assigned physical block is assigned to the physical block. When storing the data of the lock unit and reading the data of the block of the designated logical block number, the data of the block unit is stored in either the memory or the physical block based on the designated logical block number. When it is determined that it is stored in the memory, the compressed data corresponding to the specified physical block number is decompressed and read from the memory and stored in the physical block. When it is determined that the data is stored, the data in block units is read from the physical block assigned to the designated logical block number.
【請求項5】 所定のブロック単位のデータが連続した
論理ブロック番号で管理され、複数の可換記録媒体上の
前記論理ブロック番号に対してあらかじめ割当てられた
物理ブロックにアクセスして前記データの記憶、読出を
行うデータ記憶方法であって、 指定された論理ブロック番号の前記ブロック単位のデー
タを記憶する際、そのブロック単位のデータを圧縮して
圧縮データを求め、その圧縮データのデータ長があらか
じめ定められた値以下のとき、前記圧縮データを前記指
定された論理ブロック番号に対応させて、高速なアクセ
スが可能なメモリに記憶し、前記圧縮データのデータ長
があらかじめ定められた値よりも大きいとき、前記ブロ
ック単位のデータを前記指定された論理ブロック番号に
割当てられた物理ブロックに記憶し、指定された論理ブ
ロック番号のブロック単位のデータを読出す際、前記指
定された論理ブロック番号を基に、前記メモリあるいは
前記物理ブロックのいずれに記憶されているかを判断
し、前記メモリに記憶されていることが判断されたと
き、前記メモリから前記指定された物理ブロック番号に
対応する圧縮データを伸張して読出し、前記物理ブロッ
クに記憶されていることが判断されたとき、前記指定さ
れた論理ブロック番号に割当てられた物理ブロックから
前記ブロック単位のデータを読出すことを特徴とするデ
ータ記憶方法。
5. Data of a predetermined block unit is managed by consecutive logical block numbers, and physical blocks previously assigned to the logical block numbers on a plurality of exchangeable recording media are accessed to store the data. , A data storage method for reading, wherein when storing the data in block units of a specified logical block number, the data in block units is compressed to obtain compressed data, and the data length of the compressed data is set in advance. When the value is less than or equal to a predetermined value, the compressed data is stored in a memory that can be accessed at high speed in association with the specified logical block number, and the data length of the compressed data is larger than a predetermined value. At this time, the data of the block unit is stored in the physical block assigned to the designated logical block number, and designated. When reading the data in block units of the specified logical block number, it is determined whether the data is stored in the memory or the physical block based on the specified logical block number, and the data is stored in the memory. When it is determined that the compressed data corresponding to the specified physical block number is decompressed and read from the memory, and when it is determined that the compressed data is stored in the physical block, the specified logical block number A data storage method comprising reading the data in block units from a physical block assigned to the block.
【請求項6】 所定のブロック単位のデータが連続した
論理ブロック番号で管理され、複数の可換記録媒体上の
前記論理ブロック番号に対して割当てられた物理ブロッ
クにアクセスして前記データの記憶、読出しを行うデー
タ記憶方法であって、 指定された論理ブロック番号の前記ブロック単位のデー
タを記憶する際、そのブロック単位のデータを圧縮して
圧縮データを求め、その圧縮データのデータ長があらか
じめ定められた値以下のとき、前記圧縮データを前記指
定された論理ブロック番号に対応させて、高速なアクセ
スが可能なメモリに記憶し、前記圧縮データのデータ長
があらかじめ定められた値よりも大きいとき、前記指定
された論理ブロック番号に対して前記物理ブロックを割
当て、その割当てられた物理ブロックに前記ブロック単
位のデータを記憶し、指定された論理ブロック番号のブ
ロック単位のデータを読出す際、前記指定された論理ブ
ロック番号を基に、前記ブロック単位のデータが前記メ
モリあるいは前記物理ブロックのいずれに記憶されてい
るかを判断し、前記メモリに記憶されていることが判断
されたとき、前記メモリから前記指定された物理ブロッ
ク番号に対応する圧縮データを伸張して読出し、前記物
理ブロックに記憶されていることが判断されたとき、前
記指定された論理ブロック番号に対して割当てられた物
理ブロックから前記ブロック単位のデータを読出すこと
を特徴とするデータ記憶方法。
6. Data of a predetermined block unit is managed by consecutive logical block numbers, and physical blocks allocated to the logical block numbers on a plurality of exchangeable recording media are accessed to store the data, A data storage method for reading, wherein when storing data in the block unit of a specified logical block number, the data in the block unit is compressed to obtain compressed data, and the data length of the compressed data is predetermined. When the compressed data is equal to or smaller than a predetermined value, the compressed data is stored in a memory that can be accessed at high speed in association with the specified logical block number, and the data length of the compressed data is larger than a predetermined value. , Assigning the physical block to the specified logical block number, and assigning the block to the assigned physical block. When storing the data of a unit and reading the data of the block of the specified logical block number, the data of the block unit is stored in either the memory or the physical block based on the specified logical block number. If it is stored in the memory, the compressed data corresponding to the designated physical block number is decompressed and read from the memory and stored in the physical block. When it is determined that the data is stored in block units, the data is read from the physical block allocated to the designated logical block number.
JP6387195A 1995-03-23 1995-03-23 Device and method for storing data Pending JPH08263218A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP6387195A JPH08263218A (en) 1995-03-23 1995-03-23 Device and method for storing data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP6387195A JPH08263218A (en) 1995-03-23 1995-03-23 Device and method for storing data

Publications (1)

Publication Number Publication Date
JPH08263218A true JPH08263218A (en) 1996-10-11

Family

ID=13241801

Family Applications (1)

Application Number Title Priority Date Filing Date
JP6387195A Pending JPH08263218A (en) 1995-03-23 1995-03-23 Device and method for storing data

Country Status (1)

Country Link
JP (1) JPH08263218A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012133731A (en) * 2010-12-24 2012-07-12 Fujitsu Ltd Data processing apparatus and data recording method
JP2014010812A (en) * 2012-07-03 2014-01-20 Toshiba Corp Information processor, information providing apparatus, information system, and information processing program

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012133731A (en) * 2010-12-24 2012-07-12 Fujitsu Ltd Data processing apparatus and data recording method
JP2014010812A (en) * 2012-07-03 2014-01-20 Toshiba Corp Information processor, information providing apparatus, information system, and information processing program

Similar Documents

Publication Publication Date Title
US5875454A (en) Compressed data cache storage system
US5819290A (en) Data recording and management system and method for detecting data file division based on quantitative number of blocks
US6115787A (en) Disc storage system having cache memory which stores compressed data
US6785078B2 (en) Concurrent read and write access to simulated sequential data of a removable random access data storage medium
US6587919B2 (en) System and method for disk mapping and data retrieval
US5526335A (en) Information reproducing method comprising the step of preparing a defect bit map and a defect index table
JP2525666B2 (en) Image filing method
JPH10289537A (en) Digital data recording method and digital data recording medium
JP5106377B2 (en) Apparatus and method for migrating data recorded on a recording medium
WO1993000635A1 (en) Data storage management systems
JPH0830397A (en) Information storage device
JPH096678A (en) Hierarchical storage
JP4401132B2 (en) Circulation recorder
JPH08263218A (en) Device and method for storing data
EP0936561A2 (en) Data transfer method and apparatus on an SCSI bus
JP3969809B2 (en) Data buffer management method in storage device
US7649822B2 (en) Recording and reproducing apparatus and recording method
WO1984002016A1 (en) Dynamic addressing for variable track length cache memory
JP2956757B2 (en) Optical disk drive
JP3030949B2 (en) Digital data recording / reproducing device
JP3419475B2 (en) Magnetic disk drive
JP3539802B2 (en) Information storage device
JP3477800B2 (en) Disk drive device
JPH09265719A (en) Autochanger storage device
JPH0869400A (en) Recording method for compressed data