JP2017212009A - Storage device, method of writing file, and program - Google Patents

Storage device, method of writing file, and program Download PDF

Info

Publication number
JP2017212009A
JP2017212009A JP2017159250A JP2017159250A JP2017212009A JP 2017212009 A JP2017212009 A JP 2017212009A JP 2017159250 A JP2017159250 A JP 2017159250A JP 2017159250 A JP2017159250 A JP 2017159250A JP 2017212009 A JP2017212009 A JP 2017212009A
Authority
JP
Japan
Prior art keywords
directory
file
storage
server
directory name
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2017159250A
Other languages
Japanese (ja)
Other versions
JP6720120B2 (en
JP2017212009A5 (en
Inventor
泰陽 後藤
Yasuharu Goto
泰陽 後藤
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.)
Yahoo Japan Corp
Original Assignee
Yahoo Japan 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 Yahoo Japan Corp filed Critical Yahoo Japan Corp
Priority to JP2017159250A priority Critical patent/JP6720120B2/en
Publication of JP2017212009A publication Critical patent/JP2017212009A/en
Publication of JP2017212009A5 publication Critical patent/JP2017212009A5/ja
Application granted granted Critical
Publication of JP6720120B2 publication Critical patent/JP6720120B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

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

Abstract

PROBLEM TO BE SOLVED: To improve file processing performance.SOLUTION: A storage device comprises: an acceptance unit configured to accept a request to write a file with a specified directory name; and a controller configured to respond to the write request accepted by the acceptance unit within a range below an upper limit of the number of files that can be written to a storage device in association with each directory and write the file to the storage device in association with the directory of the specified directory name.SELECTED DRAWING: Figure 1

Description

本発明は、ストレージ装置、ファイル書き込み方法、およびプログラムに関する。   The present invention relates to a storage device, a file writing method, and a program.

従来、複数のファイルサーバにより分散してファイルを管理する技術が知られている(特許文献1参照)。この種の技術において、ファイルサーバには、予め複数のディレクトリが作成され、各ディレクトリに対応付けて複数のファイルが保存される場合がある。   2. Description of the Related Art Conventionally, a technique for managing files in a distributed manner by a plurality of file servers is known (see Patent Document 1). In this type of technology, a plurality of directories may be created in advance in the file server, and a plurality of files may be stored in association with each directory.

特開2004−139200号公報JP 2004-139200 A

しかしながら、ファイルサーバに作成するディレクトリ数が少ない場合、各ディレクトリに対応付けて保存されるファイル数が膨大となるため、ディレクトリとファイルとの関係を表すディレクトリ情報が膨大となり、ファイルの書き込み性能が次第に劣化するという問題がある。一方、ファイルサーバに作成するディレクトリ数を多くした場合、ファイルが多くのディレクトリに分散されるため、ファイルの書き込み位置が過度に分散する場合があった。   However, when the number of directories created on the file server is small, the number of files stored in association with each directory becomes enormous, so the directory information indicating the relationship between the directories becomes enormous and the file writing performance gradually increases. There is a problem of deterioration. On the other hand, when the number of directories created on the file server is increased, the file is distributed over many directories, and thus the file writing position may be excessively distributed.

本発明は、このような事情を考慮してなされたものであり、ファイルの処理性能を向上させることができるストレージ装置、ファイル書き込み方法、およびプログラムを提供することを目的の一つとする。   The present invention has been made in view of such circumstances, and an object of the present invention is to provide a storage device, a file writing method, and a program capable of improving file processing performance.

本発明の一態様は、ディレクトリ名を指定したファイルの書き込み要求を受け付ける受付部と、各ディレクトリに対応して記憶装置に書き込まれるファイル数に設けられる上限の範囲内で、前記受付部により受け付けられた書き込み要求に応答して、指定された前記ディレクトリ名のディレクトリに対応付けて前記ファイルを前記記憶装置に書き込む制御部とを備えるストレージ装置である。   According to one aspect of the present invention, a reception unit that receives a write request for a file that specifies a directory name, and an upper limit that is provided for the number of files that are written to a storage device corresponding to each directory are received by the reception unit. And a control unit that writes the file to the storage device in association with the directory having the designated directory name in response to the write request.

本発明の一態様によれば、ファイルの処理性能を向上させることができる。   According to one embodiment of the present invention, file processing performance can be improved.

第1実施形態に係るストレージ装置を含むストレージシステム1の一例を示す図である。1 is a diagram illustrating an example of a storage system 1 including a storage device according to a first embodiment. フロントサーバ100の一例を示す図である。It is a figure which shows an example of the front server. ディレクトリ情報136Aの一例を示す図である。It is a figure which shows an example of the directory information 136A. メタデータ310の一例を示す図である。It is a figure which shows an example of the metadata 310. FIG. ストレージサーバ200の一例を示す図である。2 is a diagram illustrating an example of a storage server 200. FIG. 論物変換テーブル242Aの一例を示す図である。It is a figure which shows an example of the logical-physical conversion table 242A. カウンタテーブル244Aの一例を示す図である。It is a figure which shows an example of the counter table 244A. ハードディスク装置210Aの一例を示す図である。It is a diagram showing an example of a hard disk device 210A. ユーザ端末400、フロントサーバ100、およびストレージサーバ200による処理の流れの一例を示す図である。It is a figure which shows an example of the flow of a process by the user terminal 400, the front server, and the storage server. フロントサーバ100における処理の流れの一例を示す図である。It is a figure which shows an example of the flow of a process in the front server. ストレージサーバ200における第1書き込み処理の流れの一例を示す図である。6 is a diagram illustrating an example of a flow of first write processing in the storage server 200. FIG. 各ディレクトリとファイルとの関係を示す図である。It is a figure which shows the relationship between each directory and a file. 書き込み要求を受け付けた時刻と、ディレクトリごとの書き込み処理との関係を示す図である。It is a figure which shows the relationship between the time which received the write request, and the write process for every directory. ストレージサーバ200における第2書き込み処理の流れの一例を示す図である。6 is a diagram illustrating an example of a flow of second write processing in the storage server 200. FIG. ユーザ端末400、フロントサーバ100、およびストレージサーバ200による処理の流れの一例を示す図である。It is a figure which shows an example of the flow of a process by the user terminal 400, the front server, and the storage server. ストレージサーバ200における第3書き込み処理の流れの一例を示す図である。FIG. 10 is a diagram showing an example of the flow of third write processing in the storage server 200. カレントディレクトリに対応付けて書き込んだファイル数と、秒単位の書き込みリクエストの処理数との関係を示す図である。It is a figure which shows the relationship between the number of files written in association with the current directory, and the number of write requests processed per second. 比較例1のディスクオフセット、シーク回数、およびスループットを表す図である。It is a figure showing the disk offset of the comparative example 1, the frequency | count of a seek, and a throughput. 実施例のディスクオフセット、シーク回数、およびスループットを表す図である。It is a figure showing the disk offset of an Example, the frequency | count of a seek, and a throughput. 磁気ディスク221上に書き込まれたファイルの物理位置の時間的な変化を示す図である。FIG. 6 is a diagram showing a temporal change in the physical position of a file written on a magnetic disk 221. ユーザ端末400、フロントサーバ100、ストレージサーバ200、およびメタデータデータベースサーバ300のハードウェア構成の一例を示す図である。2 is a diagram illustrating an example of a hardware configuration of a user terminal 400, a front server 100, a storage server 200, and a metadata database server 300. FIG.

以下、図面を参照し、本発明のストレージ装置、ファイル書き込み方法、およびプログラムの実施形態について説明する。   Hereinafter, embodiments of a storage device, a file writing method, and a program according to the present invention will be described with reference to the drawings.

<第1実施形態>
[ストレージシステム1の全体構成]
図1は、第1実施形態に係るストレージシステム1の一例を示す図である。ストレージシステム1は、例えば、複数のユーザ端末からのアップロード要求に従ってファイルをストレージサーバに蓄積すると共に、ユーザ端末からの閲覧要求またはダウンロード要求に従って、蓄積しているファイルをユーザ端末に閲覧またはダウンロードさせるストレージサービスを提供するものである。
<First Embodiment>
[Entire configuration of storage system 1]
FIG. 1 is a diagram illustrating an example of a storage system 1 according to the first embodiment. The storage system 1 stores, for example, files in a storage server according to upload requests from a plurality of user terminals, and allows the user terminals to browse or download the stored files according to browsing requests or download requests from the user terminals. It provides services.

ストレージシステム1は、例えば、フロントサーバ100と、ストレージサーバ200と、メタデータデータベースサーバ300と、ユーザ端末400−1、・・・400−M(Mは2以上の自然数)とを含む。なお、ストレージシステム1において、複数のユーザ端末400とフロントサーバ100とがネットワークNWを介して情報を通信する。ネットワークNWは、例えば、無線基地局、Wi−Fiアクセスポイント、通信回線、プロバイダ、インターネットなどを含む。なお、以下の説明において、ユーザ端末を他のユーザ端末と区別しない場合には「ユーザ端末400」と記載する。   The storage system 1 includes, for example, a front server 100, a storage server 200, a metadata database server 300, and user terminals 400-1, ... 400-M (M is a natural number of 2 or more). In the storage system 1, a plurality of user terminals 400 and the front server 100 communicate information via the network NW. The network NW includes, for example, a wireless base station, a Wi-Fi access point, a communication line, a provider, the Internet, and the like. In the following description, the user terminal is described as “user terminal 400” when it is not distinguished from other user terminals.

また、ストレージシステム1において、フロントサーバ100とストレージサーバ200、およびフロントサーバ100とメタデータデータベースサーバ300とは、ネットワークNWとは異なるネットワークを介して通信接続されている。なお、図1に示したフロントサーバ100、ストレージサーバ200、およびメタデータデータベースサーバ300は、単一のサーバ装置により実現してよく、それぞれ複数のサーバ装置を含んでいてよい。   In the storage system 1, the front server 100 and the storage server 200, and the front server 100 and the metadata database server 300 are communicatively connected via a network different from the network NW. The front server 100, the storage server 200, and the metadata database server 300 illustrated in FIG. 1 may be realized by a single server device, and may include a plurality of server devices.

[フロントサーバ100の構成]
図2は、フロントサーバ100の一例を示す図である。フロントサーバ100は、例えば、ユーザ側通信部110と、サーバ側通信部120と、フロント制御部130と、を含む。
[Configuration of Front Server 100]
FIG. 2 is a diagram illustrating an example of the front server 100. The front server 100 includes, for example, a user side communication unit 110, a server side communication unit 120, and a front control unit 130.

ユーザ側通信部110およびサーバ側通信部120は、例えばNIC(Network Interface Card)を含む。ユーザ側通信部110は、ネットワークNWを介してユーザの使用するユーザ端末400との間で通信を行う。サーバ側通信部120は、他のネットワーク介してストレージサーバ200およびメタデータデータベースサーバ300との間で通信を行う。   The user side communication unit 110 and the server side communication unit 120 include, for example, a NIC (Network Interface Card). The user side communication unit 110 communicates with the user terminal 400 used by the user via the network NW. The server-side communication unit 120 communicates with the storage server 200 and the metadata database server 300 via another network.

フロント制御部130は、例えば、アプリケーション処理部132と、ファイル管理部134とを含む。アプリケーション処理部132は、例えばCPU(Central Processing Unit)などのプロセッサがプログラムメモリに格納されたアプリケーションプログラムを実行することにより実現される。ファイル管理部134は、例えばCPUなどのプロセッサがプログラムメモリに格納されたOS(Operating System)プログラムを実行することにより実現される。アプリケーション処理部132およびファイル管理部134を含む機能部のうち一部または全部は、LSI(Large Scale Integration)、ASIC(Application Specific Integrated Circuit)、またはFPGA(Field-Programmable Gate Array)などのハードウェアにより実現されてもよい。   The front control unit 130 includes, for example, an application processing unit 132 and a file management unit 134. The application processing unit 132 is realized by a processor such as a CPU (Central Processing Unit) executing an application program stored in a program memory. The file management unit 134 is realized, for example, when a processor such as a CPU executes an OS (Operating System) program stored in a program memory. Some or all of the functional units including the application processing unit 132 and the file management unit 134 are implemented by hardware such as LSI (Large Scale Integration), ASIC (Application Specific Integrated Circuit), or FPGA (Field-Programmable Gate Array). It may be realized.

アプリケーション処理部132は、ユーザ側通信部110を用いてユーザ端末400から送信されたファイルのアップロード要求を受け付ける(受付部)。ファイルのアップロード要求は、ディレクトリを指定したファイルの書き込み要求である。アプリケーション処理部132は、ファイルのアップロード要求に応答した書き込み要求をストレージサーバ200に送信する。   The application processing unit 132 receives a file upload request transmitted from the user terminal 400 using the user-side communication unit 110 (accepting unit). The file upload request is a file write request specifying a directory. The application processing unit 132 transmits a write request in response to the file upload request to the storage server 200.

ファイル管理部134は、アップロード要求によりストレージサーバ200に書き込まれているファイルに関連するディレクトリ情報をキャッシュメモリ136に書き込む。ディレクトリ情報は、ディレクトリを管理する管理情報である。図3は、ディレクトリ情報136Aの一例を示す図である。ディレクトリ情報は、例えば、各ディレクトリ名と、所定の上限数の範囲内でディレクトリ名に対応付けられるファイル名とを対応付けている。ディレクトリ名は、ファイルのアップロード要求により指定されたディレクトリ名である。ファイル名は、アップロード要求により書き込まれるファイルのファイル名である。なお、ディレクトリ名には、追加時刻などその他の情報も対応付けられてよい。また、ファイル名には、ファイル管理部134においてファイル名に対応したファイルを特定するinode番号が対応付けられてよいが、これに限定されず、アップロード時刻などその他の情報も対応付けられてよい。   The file management unit 134 writes the directory information related to the file written in the storage server 200 by the upload request to the cache memory 136. Directory information is management information for managing a directory. FIG. 3 is a diagram illustrating an example of the directory information 136A. In the directory information, for example, each directory name is associated with a file name associated with the directory name within a predetermined upper limit number. The directory name is a directory name specified by a file upload request. The file name is the file name of the file written by the upload request. The directory name may be associated with other information such as an additional time. In addition, the file name may be associated with an inode number that identifies the file corresponding to the file name in the file management unit 134, but is not limited thereto, and other information such as upload time may also be associated.

また、ファイル管理部134は、ファイルがストレージサーバ200に書き込まれた場合に、メタデータデータベースサーバ300にメタデータを書き込む。図4は、メタデータ310の一例を示す図である。メタデータ310には、例えば、グループidと、HDDidと、ディレクトリ名と、ファイル名と、LBA(Logical Block Address)とが含まれている。グループidは、ファイルストレージ部210全体の記憶容量を所定の記憶容量に区分した一つのグループを特定する識別情報である。各グループは、一又は複数のハードディスク装置210Aを含む。各グループは、他のグループと並行してファイルが書き込まれる。なお、「メモリ」の一例は、キャッシュメモリ136、またはメタデータデータベースサーバ300である。キャッシュメモリ136に代えて外部メモリを用いてもよい。   Further, the file management unit 134 writes metadata to the metadata database server 300 when a file is written to the storage server 200. FIG. 4 is a diagram illustrating an example of the metadata 310. The metadata 310 includes, for example, a group id, an HDD id, a directory name, a file name, and an LBA (Logical Block Address). The group id is identification information that identifies one group obtained by dividing the storage capacity of the entire file storage unit 210 into a predetermined storage capacity. Each group includes one or a plurality of hard disk devices 210A. In each group, files are written in parallel with other groups. An example of “memory” is the cache memory 136 or the metadata database server 300. An external memory may be used instead of the cache memory 136.

[メタデータデータベースサーバ300の構成]
ストレージサーバ200に先だってメタデータデータベースサーバ300について説明する。メタデータデータベースサーバ300は、例えば、通信部とメタデータ310を記憶する記憶装置とを含む。メタデータデータベースサーバ300は、通信部を用いてメタデータ310を受信した場合に、記憶部にメタデータ310を書き込む。メタデータデータベースサーバ300は、フロントサーバ100の要求に従って、メタデータ310を読み出して、読み出したメタデータ310をフロントサーバ100に送信する。
[Configuration of Metadata Database Server 300]
Prior to the storage server 200, the metadata database server 300 will be described. The metadata database server 300 includes, for example, a communication unit and a storage device that stores the metadata 310. When the metadata database server 300 receives the metadata 310 using the communication unit, the metadata database server 300 writes the metadata 310 in the storage unit. The metadata database server 300 reads the metadata 310 in accordance with a request from the front server 100 and transmits the read metadata 310 to the front server 100.

[ストレージサーバ200の構成]
図5は、ストレージサーバ200の一例を示す図である。ストレージサーバ200は、例えば、ファイルストレージ部210−1、・・・210−N(Nは2以上の自然数)と、サーバ側通信部220と、ストレージ制御部230と、情報記憶部240とを含む。なお、以下の説明において、ファイルストレージ部を他のファイルストレージ部と区別しない場合には「ファイルストレージ部210」と記載する。
[Configuration of Storage Server 200]
FIG. 5 is a diagram illustrating an example of the storage server 200. The storage server 200 includes, for example, file storage units 210-1,... 210-N (N is a natural number of 2 or more), a server-side communication unit 220, a storage control unit 230, and an information storage unit 240. . In the following description, the file storage unit is described as “file storage unit 210” when it is not distinguished from other file storage units.

各ファイルストレージ部210は、一又は複数のハードディスク装置210Aを含む。ハードディスク装置210Aは、ファイルの書き込み、読み出し、および削除を実行する。   Each file storage unit 210 includes one or a plurality of hard disk devices 210A. The hard disk device 210A executes file writing, reading, and deletion.

ファイルストレージ部210は、ストレージ制御部230からライトコマンドが供給された場合、ライトコマンドに含まれるファイルをハードディスク装置210Aに書き込む。ファイルストレージ部210は、ストレージ制御部230からリードコマンドが供給された場合、リードコマンドにより指定されたファイルをハードディスク装置210Aから読み出し、読み出したファイルをストレージ制御部230に出力する。ファイルストレージ部210は、ストレージ制御部230から削除コマンドが供給された場合、リードコマンドにより指定されたファイルをハードディスク装置210Aから削除する。   When the write command is supplied from the storage control unit 230, the file storage unit 210 writes the file included in the write command to the hard disk device 210A. When the read command is supplied from the storage control unit 230, the file storage unit 210 reads the file specified by the read command from the hard disk device 210 </ b> A, and outputs the read file to the storage control unit 230. When the delete command is supplied from the storage control unit 230, the file storage unit 210 deletes the file specified by the read command from the hard disk device 210A.

サーバ側通信部220は、例えばNICを含む。サーバ側通信部220は、ネットワークNWとは他のネットワーク介してストレージサーバ200との間で通信を行う。   The server side communication unit 220 includes, for example, a NIC. The server side communication unit 220 communicates with the storage server 200 via a network other than the network NW.

ストレージ制御部230は、例えば、記憶制御部232と、ファイルカウンタ部234とを含む。記憶制御部232およびファイルカウンタ部234は、例えばCPUなどのプロセッサがプログラムメモリに格納されたサーバプログラムを実行することにより実現される。記憶制御部232およびファイルカウンタ部234を含む機能部のうち一部または全部は、LSI、ASIC、またはFPGAなどのハードウェアにより実現されてもよい。   The storage control unit 230 includes, for example, a storage control unit 232 and a file counter unit 234. The storage control unit 232 and the file counter unit 234 are realized when a processor such as a CPU executes a server program stored in a program memory, for example. Some or all of the functional units including the storage control unit 232 and the file counter unit 234 may be realized by hardware such as an LSI, an ASIC, or an FPGA.

情報記憶部240は、例えば、論物変換テーブル記憶部242と、ファイル数記憶部244とを含む。情報記憶部240は、HDD(Hard Disc Drive)、フラッシュメモリ、EEPROM(Electrically Erasable Programmable Read Only Memory)、ROM(Read Only Memory)、またはRAM(Random Access Memory)等により実現される。情報記憶部240には、サーバプログラム等の各種プログラム、各種の処理結果などが記憶される。   The information storage unit 240 includes, for example, a logical-physical conversion table storage unit 242 and a file number storage unit 244. The information storage unit 240 is realized by an HDD (Hard Disc Drive), a flash memory, an EEPROM (Electrically Erasable Programmable Read Only Memory), a ROM (Read Only Memory), a RAM (Random Access Memory), or the like. The information storage unit 240 stores various programs such as a server program, various processing results, and the like.

記憶制御部232は、サーバ側通信部220を用いてフロントサーバ100から受信した書き込み要求に応答して、ファイルをハードディスク装置210Aに書き込む。記憶制御部232は、書き込み要求を受信した場合に、書き込み要求により指定されたディレクトリに対応付けてファイルをハードディスク装置210Aに書き込む。このとき、記憶制御部232は、論物変換テーブル記憶部242に記憶された論物変換テーブル242Aを参照して、書き込み要求に含まれるLBAをPBAに変換し、変換したPBAに対応する位置にファイルを書き込む。記憶制御部232は、例えば、複数回ファイルの書き込みを行う場合、ファイルのLBAを連番に設定し、LBAが近いファイルをハードディスク装置210Aにおける近くのPBAに書き込む。図6は、論物変換テーブル242Aの一例を示す図である。論物変換テーブル記憶部242におけるデータ有無は、例えば、PBAにより特定される物理ブロック内にデータが書き込まれているか否かを示すデータ有無フラグである。   In response to the write request received from the front server 100 using the server side communication unit 220, the storage control unit 232 writes the file to the hard disk device 210A. When the storage control unit 232 receives a write request, the storage control unit 232 writes the file in the hard disk device 210A in association with the directory specified by the write request. At this time, the storage control unit 232 refers to the logical-physical conversion table 242A stored in the logical-physical conversion table storage unit 242, converts the LBA included in the write request into PBA, and sets the position corresponding to the converted PBA. Write the file. For example, when writing a file a plurality of times, the storage control unit 232 sets the LBA of the file as a serial number, and writes a file with a similar LBA to a nearby PBA in the hard disk device 210A. FIG. 6 is a diagram illustrating an example of the logical-physical conversion table 242A. The presence / absence of data in the logical-physical conversion table storage unit 242 is, for example, a data presence / absence flag indicating whether data is written in a physical block specified by the PBA.

ファイルカウンタ部234は、各ディレクトリに対応付けられて書き込まれたファイル数をカウントする。ファイルカウンタ部234は、カウントした結果をカウンタテーブル244Aに記憶する。カウンタテーブル244Aは、ディレクトリに対応付けて書き込まれたファイル数を管理する管理情報である。図7は、カウンタテーブル244Aの一例を示す図である。カウンタテーブル244Aにおけるディレクトリ名には、例えば、カウントした結果としてのファイル数と、上限値とが対応付けられている。   The file counter unit 234 counts the number of files written in association with each directory. The file counter unit 234 stores the counted result in the counter table 244A. The counter table 244A is management information for managing the number of files written in association with the directory. FIG. 7 is a diagram illustrating an example of the counter table 244A. For example, the directory name in the counter table 244A is associated with the number of files as a result of counting and an upper limit value.

(ハードディスク装置210Aの構成)
図8は、ハードディスク装置210Aの一例を示す図である。ハードディスク装置210Aは、例えば、磁気ディスク211と、ヘッドスタックアッセンブリ(Head Stack Assembly;HSA)212と、駆動回路223と、HDDコントローラ224と、インターフェース225とを含む。
(Configuration of hard disk device 210A)
FIG. 8 is a diagram illustrating an example of the hard disk device 210A. The hard disk device 210A includes, for example, a magnetic disk 211, a head stack assembly (HSA) 212, a drive circuit 223, an HDD controller 224, and an interface 225.

磁気ディスク211は、アルミニウムやガラス等の基板の表裏面に磁気記録層が形成された円盤(プラッタ)である。磁気ディスク211は、単一の円盤により構成されてもよいし、円盤の厚み方向に対して複数枚の円盤が積み重ねられて構成されてもよい。   The magnetic disk 211 is a disk (platter) in which magnetic recording layers are formed on the front and back surfaces of a substrate such as aluminum or glass. The magnetic disk 211 may be configured by a single disk, or may be configured by stacking a plurality of disks in the thickness direction of the disk.

ヘッドスタックアッセンブリ212は、記録再生ヘッド212aと、ヘッドアンプIC212bと、ボイスコイルモータ212cと、スピンドルモータ212dとを含む。   The head stack assembly 212 includes a recording / reproducing head 212a, a head amplifier IC 212b, a voice coil motor 212c, and a spindle motor 212d.

記録再生ヘッド212aは、ヘッドアーム上に搭載され、ボイスコイルモータ212cからの駆動力によって磁気ディスク211上をシークしながら、磁気ディスク211に対して相対的に移動する。記録再生ヘッド212aは、記録および再生兼用の磁性体コアを用いた薄膜ヘッドであってよいが、これに限定されない。   The recording / reproducing head 212a is mounted on the head arm and moves relative to the magnetic disk 211 while seeking on the magnetic disk 211 by the driving force from the voice coil motor 212c. The recording / reproducing head 212a may be a thin film head using a magnetic core for both recording and reproduction, but is not limited thereto.

記録再生ヘッド212aは、ファイルを書き込む場合、ヘッドアンプIC212bにより供給された電気信号に基づく磁界を発生させることで、磁気ディスク221の磁気記録層の磁化方向を変化させる。これによって、記録再生ヘッド212aは、ファイルを磁気ディスク221に書き込む。記録再生ヘッド212aは、ファイルを読み出す場合、磁気ディスク211上を移動しながら、磁気ディスク211の磁気記録層の磁化方向に対応した電気信号を生成する。記録再生ヘッド212aは、生成した電気信号を、ヘッドアンプIC212bを介して駆動回路223に供給する。   When writing a file, the recording / reproducing head 212a changes the magnetization direction of the magnetic recording layer of the magnetic disk 221 by generating a magnetic field based on the electric signal supplied by the head amplifier IC 212b. As a result, the recording / reproducing head 212 a writes the file to the magnetic disk 221. When the file is read, the recording / reproducing head 212 a generates an electrical signal corresponding to the magnetization direction of the magnetic recording layer of the magnetic disk 211 while moving on the magnetic disk 211. The recording / reproducing head 212a supplies the generated electric signal to the drive circuit 223 via the head amplifier IC 212b.

ヘッドアンプIC212bは、記録再生ヘッド212aにより供給された電気信号の信号強度を増幅する。また、ヘッドアンプIC212bは、駆動回路223により供給されたユーザデータを電気信号に変換し、記録再生ヘッド212aに供給する。   The head amplifier IC 212b amplifies the signal intensity of the electric signal supplied from the recording / reproducing head 212a. The head amplifier IC 212b converts the user data supplied from the drive circuit 223 into an electric signal and supplies it to the recording / reproducing head 212a.

ボイスコイルモータ212cは、駆動回路223により供給された駆動電流に応じて、ヘッドスタックアッセンブリ222を駆動する。これにより、ボイスコイルモータ212cは、記録再生ヘッド212aを、磁気ディスク211の径方向に沿って(あるいは径方向に対して角度を有する斜めの方向に沿って)外側または内側に移動させ、トラック間を移動させる。径方向とは、磁気ディスクの中心を通る方向である。スピンドルモータ212dは、駆動回路223により供給された駆動電流に応じて、磁気ディスク211を回転させる。スピンドルモータ212dは、例えば、DCブラシレスモータである。   The voice coil motor 212 c drives the head stack assembly 222 according to the drive current supplied by the drive circuit 223. As a result, the voice coil motor 212c moves the recording / reproducing head 212a outward or inward along the radial direction of the magnetic disk 211 (or along an oblique direction having an angle with respect to the radial direction). Move. The radial direction is a direction passing through the center of the magnetic disk. The spindle motor 212d rotates the magnetic disk 211 according to the drive current supplied by the drive circuit 223. The spindle motor 212d is, for example, a DC brushless motor.

駆動回路223は、ヘッドアンプICとの間で信号を授受すると共に、ボイスコイルモータ212cおよびスピンドルモータ212dを駆動する。これにより、駆動回路223は、コマンドに含まれるPBAに対応する位置に記録再生ヘッド212aをシークさせてファイルを書き込む。   The drive circuit 223 exchanges signals with the head amplifier IC and drives the voice coil motor 212c and the spindle motor 212d. As a result, the drive circuit 223 causes the recording / reproducing head 212a to seek at a position corresponding to the PBA included in the command and writes the file.

HDDコントローラ224は、インターフェース225を用いて、フロントサーバ100から送信されたリードコマンド、ライトコマンド、および削除コマンドを受信する。HDDコントローラ224は、各コマンドに応じて、磁気ディスク211に情報を書き込んだり、磁気ディスク211に書き込まれた情報を読み出したりする。   The HDD controller 224 receives a read command, a write command, and a delete command transmitted from the front server 100 using the interface 225. The HDD controller 224 writes information on the magnetic disk 211 or reads information written on the magnetic disk 211 in accordance with each command.

[ストレージシステム1の全体処理]
以下、フロントサーバ100がディレクトリ名を指定したファイルの書き込み要求を受け付けた場合に、ファイルをハードディスク装置210Aに書き込む処理について説明する。図9は、ユーザ端末400、フロントサーバ100、およびストレージサーバ200による処理の流れの一例を示す図である。
[Entire processing of storage system 1]
Hereinafter, a process of writing a file to the hard disk device 210A when the front server 100 receives a write request for a file with a directory name specified will be described. FIG. 9 is a diagram illustrating an example of a flow of processing by the user terminal 400, the front server 100, and the storage server 200.

ユーザ端末400は、ファイルをアップロードする際に、ユーザの操作に従ってファイルをアップロードするアプリケーションプログラムに対してAPI(Application Program Interface)コールを供給する。これにより、ユーザ端末400のアプリケーションプログラムは、フロントサーバ100に、アプリケーション処理部132を呼び出す処理リクエストS1を送信する。なお、処理リクエストS1は、ユーザ端末400におけるアプリケーションまたはブラウザなどのUA(User Agent)により生成されたHTTP(Hypertext Transfer Protocol)リクエストに埋め込まれた情報である。   When uploading a file, the user terminal 400 supplies an API (Application Program Interface) call to an application program that uploads the file in accordance with a user operation. Accordingly, the application program of the user terminal 400 transmits a processing request S1 for calling the application processing unit 132 to the front server 100. The processing request S1 is information embedded in an HTTP (Hypertext Transfer Protocol) request generated by an UA (User Agent) such as an application in the user terminal 400 or a browser.

フロントサーバ100は、処理リクエストS1を受信した場合に、カレントディレクトリのディレクトリ名を要求するディレクトリ名リクエストS2をストレージサーバ200に送信する。ストレージサーバ200は、ディレクトリ名リクエストS2を受信した場合、カレントディレクトリに対応するファイル数をカウントアップする(ステップS10)。ストレージサーバ200は、カレントディレクトリのディレクトリ名S3をフロントサーバ100に送信する。フロントサーバ100は、カレントディレクトリのディレクトリ名S3を受信した場合、ディレクトリ名S3をファイル書き込み先のディレクトリ名S4としてユーザ端末400に送信する。   When the front server 100 receives the processing request S1, the front server 100 transmits a directory name request S2 for requesting the directory name of the current directory to the storage server 200. When receiving the directory name request S2, the storage server 200 counts up the number of files corresponding to the current directory (step S10). The storage server 200 transmits the directory name S3 of the current directory to the front server 100. When the front server 100 receives the directory name S3 of the current directory, the front server 100 transmits the directory name S3 to the user terminal 400 as the directory name S4 of the file write destination.

ユーザ端末400は、ディレクトリ名S4を指定したアップロード要求S5を含むHTTPリクエストをフロントサーバ100に送信する。フロントサーバ100は、アップロード要求S5を受信した場合、ストレージサーバ200に、ディレクトリ名を指定したファイルの書き込み要求S6を送信する。   The user terminal 400 transmits an HTTP request including an upload request S5 specifying the directory name S4 to the front server 100. When the front server 100 receives the upload request S <b> 5, the front server 100 transmits a file write request S <b> 6 specifying a directory name to the storage server 200.

ストレージサーバ200は、フロントサーバ100により送信された書き込み要求S6を受信した場合、受信した書き込み要求S6により指定されたディレクトリ名のディレクトリに対応付けてファイルをハードディスク装置210Aに書き込む(ステップS11)。ストレージサーバ200は、ファイルの書き込みが完了した場合、レスポンスS7をフロントサーバ100に送信する。   When the storage server 200 receives the write request S6 transmitted by the front server 100, the storage server 200 writes the file in the hard disk device 210A in association with the directory having the directory name specified by the received write request S6 (step S11). When the file writing is completed, the storage server 200 transmits a response S7 to the front server 100.

フロントサーバ100は、レスポンスS7を受信した場合、ハードディスク装置210Aに書き込まれたファイルのファイル名に関連するメタデータ310を更新する(ステップS21)。次にフロントサーバ100は、ファイルのアップロードが完了したことを通知する完了通知S8をユーザ端末400に送信する。   When the front server 100 receives the response S7, the front server 100 updates the metadata 310 related to the file name of the file written in the hard disk device 210A (step S21). Next, the front server 100 transmits a completion notification S8 for notifying that the file upload has been completed to the user terminal 400.

[フロントサーバ100の動作]
図10は、フロントサーバ100における処理の流れの一例を示す図である。図10に示した処理は、アプリケーション処理部132により所定期間毎に繰り返して実行される。
[Operation of Front Server 100]
FIG. 10 is a diagram illustrating an example of a process flow in the front server 100. The processing illustrated in FIG. 10 is repeatedly executed by the application processing unit 132 at predetermined intervals.

まず、アプリケーション処理部132は、処理リクエストS1を受け付けたか否かを判定する(ステップS100)。アプリケーション処理部132は、処理リクエストS1を受け付けた場合、ストレージサーバ200にディレクトリ名リクエストS2を送信する(ステップS102)。   First, the application processing unit 132 determines whether or not the processing request S1 has been received (step S100). When receiving the processing request S1, the application processing unit 132 transmits a directory name request S2 to the storage server 200 (step S102).

次にアプリケーション処理部132は、ストレージサーバ200からディレクトリ名S3を受信したか否かを判定する(ステップS104)。アプリケーション処理部132は、ディレクトリ名S3を受信した場合、ユーザ端末400にディレクトリ名S4を送信する(ステップS106)。   Next, the application processing unit 132 determines whether the directory name S3 is received from the storage server 200 (step S104). When receiving the directory name S3, the application processing unit 132 transmits the directory name S4 to the user terminal 400 (step S106).

次にアプリケーション処理部132は、ユーザ端末400からディレクトリ名S4を指定したアップロード要求S5を受信したか否かを判定する(ステップS110)。アプリケーション処理部132は、アップロード要求S5を受信した場合、ディレクトリ名S4を含む書き込み要求S6をストレージサーバ200に送信する(ステップS112)。このとき、アプリケーション処理部132は、書き込み対象のファイルのファイル名をディレクトリ情報136Aにキャッシュする。   Next, the application processing unit 132 determines whether or not the upload request S5 specifying the directory name S4 is received from the user terminal 400 (step S110). When receiving the upload request S5, the application processing unit 132 transmits a write request S6 including the directory name S4 to the storage server 200 (step S112). At this time, the application processing unit 132 caches the file name of the file to be written in the directory information 136A.

次に、アプリケーション処理部132は、ストレージサーバ200からレスポンスS7を受信したか否かを判定する(ステップS114)。アプリケーション処理部132は、レスポンスS7を受信した場合、ディレクトリ情報136Aおよびメタデータ310を更新する(ステップS116)。このとき、アプリケーション処理部132は、ハードディスク装置210Aに書き込まれたファイルのファイル名を、指定されたディレクトリ名に対応付けてディレクトリ情報136Aに追加する。また、アプリケーション処理部132は、ハードディスク装置210Aに書き込まれたファイルのファイル名などの情報をメタデータデータベースサーバ300に送信する。次に、アプリケーション処理部132は、完了通知S8をユーザ端末400に送信する(ステップS118)。   Next, the application processing unit 132 determines whether or not the response S7 has been received from the storage server 200 (step S114). When receiving the response S7, the application processing unit 132 updates the directory information 136A and the metadata 310 (step S116). At this time, the application processing unit 132 adds the file name of the file written in the hard disk device 210A to the directory information 136A in association with the designated directory name. In addition, the application processing unit 132 transmits information such as the file name of the file written in the hard disk device 210 </ b> A to the metadata database server 300. Next, the application processing unit 132 transmits a completion notification S8 to the user terminal 400 (step S118).

なお、処理リクエストを受信しない場合、およびアップロード要求を受信しない場合、フロントサーバ100は、本フローチャートの処理を終了する。   Note that the front server 100 ends the process of this flowchart when the process request is not received and when the upload request is not received.

また、フロントサーバ100は、ストレージサーバ200により通知されたディレクトリ名S3をユーザ端末400に送信してよいが、これに限定されず、ディレクトリ名S3をフロントサーバ100のAPI内で処理をするのみであってよい。フロントサーバ100は、ストレージサーバ200からディレクトリ名S3を受信した場合、ディレクトリ名S3をユーザ端末400に送信することなしに、メモリに記憶する。フロントサーバ100は、ユーザ端末400からアップロード要求S5を受信した場合、記憶しておいたディレクトリ名S3を読み出し、読み出したディレクトリ名S3および書き込み要求S6をストレージサーバ200に送信する。これにより、フロントサーバ100とユーザ端末400との間の通信回数を削減することができる。   The front server 100 may transmit the directory name S3 notified by the storage server 200 to the user terminal 400, but the present invention is not limited to this, and only the directory name S3 is processed within the API of the front server 100. It may be. When the front server 100 receives the directory name S3 from the storage server 200, the front server 100 stores the directory name S3 in the memory without transmitting it to the user terminal 400. When receiving the upload request S5 from the user terminal 400, the front server 100 reads the stored directory name S3 and transmits the read directory name S3 and write request S6 to the storage server 200. Thereby, the frequency | count of communication between the front server 100 and the user terminal 400 can be reduced.

[ストレージサーバ200の動作]
図11は、ストレージサーバ200における第1書き込み処理の流れの一例を示す図である。図11に示した処理は、ストレージ制御部230により所定期間毎に繰り返して実行される。
[Operation of Storage Server 200]
FIG. 11 is a diagram illustrating an example of the flow of the first write process in the storage server 200. The processing shown in FIG. 11 is repeatedly executed by the storage control unit 230 every predetermined period.

まず、記憶制御部232は、ディレクトリ名リクエストS2を受け付けたか否かを判定する(ステップS200)。ファイルカウンタ部234は、ディレクトリ名リクエストS2を受け付けた場合、カレントディレクトリのファイル数をカウントアップする(ステップS202)。   First, the storage control unit 232 determines whether or not the directory name request S2 has been received (step S200). When the file counter unit 234 receives the directory name request S2, the file counter unit 234 counts up the number of files in the current directory (step S202).

次に記憶制御部232は、ファイルカウンタ部234によりカウントアップされた結果としてのカレントディレクトリのファイル数が上限値以下であるか否かを判定する(ステップS204)。記憶制御部232は、カレントディレクトリのファイル数が上限値以下である場合、カレントディレクトリのディレクトリ名をフロントサーバ100に送信する(ステップS208)。記憶制御部232は、カレントディレクトリのファイル数が上限値を超えた場合、新たなディレクトリ名をカレントディレクトリのディレクトリ名として決定する(ステップS206)。記憶制御部232は、決定した新たなカレントディレクトリのディレクトリ名をフロントサーバ100に返信する(ステップS208)。   Next, the storage control unit 232 determines whether or not the number of files in the current directory as a result of being counted up by the file counter unit 234 is less than or equal to the upper limit value (step S204). If the number of files in the current directory is less than or equal to the upper limit value, the storage control unit 232 transmits the directory name of the current directory to the front server 100 (step S208). If the number of files in the current directory exceeds the upper limit value, the storage control unit 232 determines a new directory name as the directory name of the current directory (step S206). The storage control unit 232 returns the determined directory name of the new current directory to the front server 100 (step S208).

次に、記憶制御部232は、フロントサーバ100から書き込み要求S6を受信したか否かを判定する(ステップS210)。記憶制御部232は、書き込み要求S6を受信した場合、指定されたディレクトリ名のディレクトリが存在しているか否かを判定する(ステップS212)。記憶制御部232は、指定されたディレクトリ名のディレクトリがカウンタテーブル244Aに存在している場合、当該ディレクトリに対応付けてファイルを書き込む(ステップS216)。   Next, the storage control unit 232 determines whether or not a write request S6 has been received from the front server 100 (step S210). When the storage control unit 232 receives the write request S6, the storage control unit 232 determines whether a directory having the designated directory name exists (step S212). If a directory with the specified directory name exists in the counter table 244A, the storage control unit 232 writes a file in association with the directory (step S216).

記憶制御部232は、指定されたディレクトリ名のディレクトリがカウンタテーブル244Aに存在しない場合、決定したカレントディレクトリのディレクトリ名に対応したディレクトリの管理情報をカウンタテーブル244Aに書き込むことで、新たなディレクトリ名のディレクトリを追加する(ステップS214)。記憶制御部232は、追加したディレクトリに対応付けてファイルを書き込む(ステップS216)。   When the directory having the designated directory name does not exist in the counter table 244A, the storage control unit 232 writes the management information of the directory corresponding to the determined directory name of the current directory in the counter table 244A, thereby creating a new directory name. A directory is added (step S214). The storage control unit 232 writes a file in association with the added directory (step S216).

なお、ディレクトリ名リクエストを受信していない場合、および書き込み要求を受信しない場合、ストレージサーバ200は、本フローチャートの処理を終了する。   Note that when the directory name request has not been received and when the write request has not been received, the storage server 200 ends the processing of this flowchart.

[書き込み処理におけるディレクトリとファイルとの関係]
以下、上述したストレージサーバ200において、各ディレクトリに対応付けてファイルを書き込む様子について説明する。図12は、各ディレクトリとファイルとの関係を示す図である。
[Relationship between directory and file in writing process]
Hereinafter, how the storage server 200 described above writes a file in association with each directory will be described. FIG. 12 is a diagram showing the relationship between each directory and file.

図12を参照した説明において、ファイル数の上限としての上限値は「1000」であるものとする。記憶制御部232は、図12(a)に示すように、グループidが「001」に対してディレクトリ名が「001」のディレクトリの情報をカウンタテーブル244Aに追加し、990個のファイルの書き込み要求をフロントサーバ100から受信するものとする。この場合、記憶制御部232は、990個のファイルを1つのカレントディレクトリに対応付けて連続的に書き込む。   In the description with reference to FIG. 12, it is assumed that the upper limit value as the upper limit of the number of files is “1000”. As shown in FIG. 12A, the storage control unit 232 adds information on the directory having the group ID “001” and the directory name “001” to the counter table 244A, and requests for writing 990 files. Is received from the front server 100. In this case, the storage control unit 232 continuously writes 990 files in association with one current directory.

記憶制御部232は、ディレクトリ名が「001」のディレクトリに対応付けて1000個のファイルを書き込んだ場合において、1001個目のファイルを書き込む場合、ディレクトリ名が「002」の新たなディレクトリを追加する。記憶制御部232は、追加した新たなディレクトリとしてのカレントディレクトリに対応付けて1001個目のファイルを書き込む。すなわち、記憶制御部232は、新たなディレクトリを追加した場合に、ファイル数が上限値を超えたディレクトリに対応付けてファイルを書き込むことなしに、新たなディレクトリに対応付けてファイルを書き込む。このような動作は、各ディレクトリに対応付けて書き込まれたファイル数をカウントし、カウントしたファイル数が上限値を超えた場合に、ディレクトリに対応付けてファイルを書き込むことを制限する、と記載することもできる。   When the 1000th file is written in association with the directory whose directory name is “001” and the 1001st file is written, the storage control unit 232 adds a new directory whose directory name is “002”. . The storage control unit 232 writes the 1001st file in association with the current directory as the added new directory. That is, when a new directory is added, the storage control unit 232 writes the file in association with the new directory without writing the file in association with the directory whose number of files exceeds the upper limit. It is stated that such an operation counts the number of files written in association with each directory, and restricts writing of files in association with the directory when the counted number of files exceeds the upper limit. You can also

[ファイルの書き込み要求と書き込み処理の遷移状態との関係]
図13は、書き込み要求を受け付けた時刻と、ディレクトリごとの書き込み処理との関係を示す図である。記憶制御部232は、ディレクトリ名が「001」のディレクトリdir001に対応付けて書き込んだファイル数が上限値以下である場合、ディレクトリdir001に対応したファイルの書き込み処理を行う。ディレクトリdir001に対応したファイルの書き込み処理は、ディレクトリdir001以外のディレクトリに対応付けて書き込むことなしに、ディレクトリdir001にのみ対応付けてファイルを書き込む処理である。記憶制御部232は、ディレクトリdir001に対応したファイルの書き込み処理を実行している期間において時刻tにファイル(file(t))の書き込み要求を受信した場合には当該ファイルをディレクトリdir001に対応付けて書き込み、時刻t+T1にファイル(file(t+T1))の書き込み要求を受信した場合には当該ファイルをディレクトリdir001に対応付けて書き込む。
[Relationship between file write request and transition status of write processing]
FIG. 13 is a diagram illustrating the relationship between the time when a write request is received and the write processing for each directory. When the number of files written in association with the directory dir001 having the directory name “001” is equal to or less than the upper limit value, the storage control unit 232 performs a process of writing a file corresponding to the directory dir001. The file writing process corresponding to the directory dir001 is a process of writing a file in association with only the directory dir001 without writing in association with a directory other than the directory dir001. When the storage control unit 232 receives a write request for a file (file (t)) at time t during a period in which a file write process corresponding to the directory dir001 is being executed, the storage control unit 232 associates the file with the directory dir001. When a write request for writing a file (file (t + T1)) is received at time t + T1, the file is written in association with the directory dir001.

記憶制御部232は、ファイル(file(t+T1))をディレクトリdir001に対応付けて書き込むことでディレクトリdir001に書き込んだファイル数が上限値を超えた場合、ディレクトリdir002に対応したファイルの書き込み処理に遷移する。ディレクトリdir002に対応したファイルの書き込み処理は、ディレクトリdir002以外のディレクトリに対応付けてファイルを書き込むことなしに、ディレクトリdir002にのみ対応付けてファイルを書き込む処理である。これにより、記憶制御部232は、ディレクトリdir002に対応したファイルの書き込み処理を実行している期間において時刻t+T2にファイル(file(t+T2))の書き込み要求を受信した場合には当該ファイルをディレクトリdir002に対応付けて書き込む。   When the number of files written in the directory dir001 exceeds the upper limit by writing the file (file (t + T1)) in association with the directory dir001, the storage control unit 232 performs a file writing process corresponding to the directory dir002. Transition. The process of writing a file corresponding to the directory dir002 is a process of writing a file in association with only the directory dir002 without writing a file in association with a directory other than the directory dir002. As a result, if the storage control unit 232 receives a write request for the file (file (t + T2)) at time t + T2 during the period in which the file write process corresponding to the directory dir002 is being executed, the storage control unit 232 stores the file in the directory Write in association with dir002.

ストレージサーバ200は、図11に示す処理に代えて、以下の処理を行ってもよい。図14は、ストレージサーバ200における書き込み処理の流れの他の一例を示す図である。図14に示した書き込み処理は、ストレージ制御部230により所定期間毎に繰り返して実行される。   The storage server 200 may perform the following process instead of the process shown in FIG. FIG. 14 is a diagram illustrating another example of the flow of write processing in the storage server 200. The write processing shown in FIG. 14 is repeatedly executed by the storage control unit 230 every predetermined period.

まず、記憶制御部232は、ディレクトリ名リクエストS2を受け付けたか否かを判定する(ステップS300)。ファイルカウンタ部234は、ディレクトリ名リクエストS2を受け付けた場合、カレントディレクトリのファイル数をカウントアップする(ステップS302)。   First, the storage control unit 232 determines whether or not the directory name request S2 has been received (step S300). When the file counter unit 234 receives the directory name request S2, the file counter unit 234 counts up the number of files in the current directory (step S302).

次に記憶制御部232は、ファイルカウンタ部234によりカウントアップされた結果としてのカレントディレクトリのファイル数が上限値以下であるか否かを判定する(ステップS304)。記憶制御部232は、カレントディレクトリのファイル数が上限値以下である場合、カレントディレクトリのディレクトリ名をフロントサーバ100に送信する(ステップS310)。   Next, the storage control unit 232 determines whether or not the number of files in the current directory as a result of being counted up by the file counter unit 234 is less than or equal to the upper limit value (step S304). If the number of files in the current directory is less than or equal to the upper limit value, the storage control unit 232 transmits the directory name of the current directory to the front server 100 (step S310).

記憶制御部232は、カレントディレクトリのファイル数が上限値を超えた場合、新たなディレクトリ名をカレントディレクトリのディレクトリ名として決定する(ステップS306)。次に、記憶制御部232は、決定したカレントディレクトリのディレクトリ名に対応したディレクトリの管理情報をカウンタテーブル244Aに書き込むことで、ディレクトリを追加する(ステップS308)。次に、記憶制御部232は、追加したカレントディレクトリのディレクトリ名をフロントサーバ100に送信する(ステップS310)。   If the number of files in the current directory exceeds the upper limit value, the storage control unit 232 determines a new directory name as the directory name of the current directory (step S306). Next, the storage control unit 232 adds the directory by writing the management information of the directory corresponding to the determined directory name of the current directory in the counter table 244A (step S308). Next, the storage control unit 232 transmits the directory name of the added current directory to the front server 100 (step S310).

次に、記憶制御部232は、フロントサーバ100から書き込み要求S6を受信したか否かを判定する(ステップS312)。記憶制御部232は、書き込み要求S6を受信した場合、追加したディレクトリにファイルを書き込む(ステップS314)。   Next, the storage control unit 232 determines whether or not a write request S6 has been received from the front server 100 (step S312). When the storage control unit 232 receives the write request S6, the storage control unit 232 writes the file in the added directory (step S314).

なお、ディレクトリ名リクエストを受信していない場合、および書き込み要求を受信しない場合、ストレージサーバ200は、本フローチャートの処理を終了する。以上が、第2書き込み処理の説明である。   Note that when the directory name request has not been received and when the write request has not been received, the storage server 200 ends the processing of this flowchart. The above is the description of the second writing process.

ストレージサーバ200は、以上の動作により、各ディレクトリに対応して書き込まれるファイル数に設けられる上限の範囲内で、ファイルをハードディスク装置210Aに書き込む。なお、フロントサーバ100およびストレージサーバ200は、図10と、図11または図14とに示した処理を行うことで、ストレージ装置として機能する。   Through the above operation, the storage server 200 writes the file to the hard disk device 210A within the upper limit set for the number of files written corresponding to each directory. The front server 100 and the storage server 200 function as a storage device by performing the processing shown in FIG. 10, FIG. 11, or FIG.

[第1実施形態の効果]
以上説明した第1実施形態のストレージシステム1によれば、各ディレクトリに対応してハードディスク装置210Aに書き込まれるファイル数に設けられる上限の範囲内で、フロントサーバ100により受け付けられた書き込み要求に応答して、指定されたディレクトリ名に対応付けてファイルを書き込むので、ディレクトリに対応付けられるファイル数を制限することができる。これにより、ストレージシステム1によれば、ディレクトリ情報136Aが肥大化することを抑制することができる。この結果、ストレージシステム1によれば、ディレクトリ名をシークする時間を抑制することができることで、ファイルの書き込み時間を短縮することができる。
[Effect of the first embodiment]
According to the storage system 1 of the first embodiment described above, it responds to the write request accepted by the front server 100 within the upper limit set for the number of files written to the hard disk device 210A corresponding to each directory. Since the file is written in association with the designated directory name, the number of files associated with the directory can be limited. Thereby, according to the storage system 1, it can suppress that the directory information 136A enlarges. As a result, according to the storage system 1, the time for seeking the directory name can be suppressed, so that the file writing time can be shortened.

また、第1実施形態のストレージシステム1によれば、ディレクトリに対応付けられるファイル数が上限値に達するまで1つのディレクトリに連続的にファイルを書き込むので、連続的に書き込むファイルを複数のディレクトリに分散させることがない。連続的に書き込まれたファイルは、略同時期に書き込まれたファイルとも言うことができる。これにより、ストレージシステム1によれば、略同時期に書き込まれるファイルにおける磁気ディスク221上の位置を近くに配置することができる。この結果、ストレージシステム1によれば、略同時期に書き込まれた複数のファイルを読み出す際のリード時間を短縮することができる。   Further, according to the storage system 1 of the first embodiment, since files are continuously written to one directory until the number of files associated with the directory reaches the upper limit value, the files to be continuously written are distributed to a plurality of directories. I will not let you. A file written continuously can be said to be a file written at substantially the same time. Thereby, according to the storage system 1, the position on the magnetic disk 221 in the file written at substantially the same time can be arranged nearby. As a result, according to the storage system 1, it is possible to shorten the read time when reading a plurality of files written at substantially the same time.

<第2実施形態>
以下、第2実施形態について説明する。第2実施形態のストレージサーバ200は、カレントディレクトリのディレクトリ名に書き込んだファイル数が上限値を超えた場合に、ディレクトリ名をフロントサーバ100にプッシュ通知する点で、第1実施形態のストレージシステム1とは異なる。以下、この点を中心に説明する。
Second Embodiment
Hereinafter, a second embodiment will be described. The storage server 200 of the second embodiment pushes the directory name to the front server 100 when the number of files written to the directory name of the current directory exceeds the upper limit, so that the storage system 1 of the first embodiment Is different. Hereinafter, this point will be mainly described.

[第2実施形態の全体処理]
図15は、ユーザ端末400、フロントサーバ100、およびストレージサーバ200による処理の流れの一例を示す図である。
[Overall Processing of Second Embodiment]
FIG. 15 is a diagram illustrating an example of a flow of processing by the user terminal 400, the front server 100, and the storage server 200.

まず、フロントサーバ100は、通知リクエストS20をストレージサーバ200に送信する。通知リクエストS20は、ストレージサーバ200におけるカレントディレクトリを新たに設定したタイミングでカレントディレクトリのディレクトリ名をフロントサーバ100に通知するメッセージをプッシュ通知することを要求するメッセージである。フロントサーバ100は、例えば、フロントサーバ100の電源が投入してアプリケーションプログラムの起動が完了したタイミング、またはフロントサーバ100が起動している最中における定期的に、通知リクエストS20をストレージサーバ200に送信する。通知リクエストS20は、ディレクトリを新たに追加したタイミングでプッシュ通知することに限定されず、図14に示したように新たなディレクトリ名を決定した後に新たなディレクトリを追加する場合において、新たなディレクトリを追加したタイミングであってよい。   First, the front server 100 transmits a notification request S20 to the storage server 200. The notification request S20 is a message for requesting push notification of a message for notifying the front server 100 of the directory name of the current directory at the timing when the current directory in the storage server 200 is newly set. For example, the front server 100 transmits the notification request S20 to the storage server 200 at the timing when the front server 100 is turned on and the activation of the application program is completed, or periodically while the front server 100 is running. To do. The notification request S20 is not limited to push notification at the timing when a directory is newly added, and when adding a new directory after determining a new directory name as shown in FIG. It may be the added timing.

フロントサーバ100は、処理リクエストS21を受信した場合に、既にストレージサーバ200からプッシュ通知されているカレントディレクトリのディレクトリ名S22をユーザ端末400に送信する。フロントサーバ100は、アップロード要求S23を受信した場合、ストレージサーバ200に、ディレクトリ名を指定したファイルの書き込み要求S24を送信する。   When the front server 100 receives the processing request S21, the front server 100 transmits to the user terminal 400 the directory name S22 of the current directory that has already been pushed from the storage server 200. When the front server 100 receives the upload request S <b> 23, the front server 100 transmits a file write request S <b> 24 specifying a directory name to the storage server 200.

ストレージサーバ200は、フロントサーバ100により送信された書き込み要求S24を受信した場合、受信した書き込み要求S24により指定されたディレクトリ名に対応付けてファイルをハードディスク装置210Aに書き込む(ステップS30)。ストレージサーバ200は、ファイルの書き込みが完了した場合、レスポンスS25をフロントサーバ100に送信する。これにより、ストレージサーバ200は、フロントサーバ100からユーザ端末400に完了通知S26を送信させる。   When the storage server 200 receives the write request S24 transmitted by the front server 100, the storage server 200 writes a file in the hard disk device 210A in association with the directory name specified by the received write request S24 (step S30). When the file writing is completed, the storage server 200 transmits a response S25 to the front server 100. As a result, the storage server 200 causes the front server 100 to transmit a completion notification S26 to the user terminal 400.

次にストレージサーバ200は、カレントディレクトリに対応するファイル数をカウントアップする(ステップS31)。ストレージサーバ200は、ファイルの書き込みを実行する度に、カレントディレクトリのディレクトリ名に対するファイル数が上限値を超えたか否かを判定する。ストレージサーバ200は、カレントディレクトリのディレクトリ名に対するファイル数が上限値以下である場合、プッシュ通知を実行しない(ステップS32)。ストレージサーバ200は、カレントディレクトリのディレクトリ名に対するファイル数が上限値を超えた場合に、新たなカレントディレクトリのディレクトリ名を決定する。ストレージサーバ200は、決定した新たなカレントディレクトリのディレクトリ名S27をフロントサーバ100にプッシュ通知する(ステップS33)。   Next, the storage server 200 counts up the number of files corresponding to the current directory (step S31). The storage server 200 determines whether or not the number of files for the directory name of the current directory has exceeded the upper limit value each time file writing is executed. When the number of files for the directory name of the current directory is equal to or less than the upper limit value, the storage server 200 does not execute push notification (step S32). The storage server 200 determines the directory name of the new current directory when the number of files for the directory name of the current directory exceeds the upper limit value. The storage server 200 pushes the front server 100 with the directory name S27 of the determined new current directory (step S33).

なお、フロントサーバ100は、ディレクトリ名S27を受信した場合に、通知リクエストをストレージサーバ200に送信してよい。これにより、フロントサーバ100は、以降に追加されるディレクトリのディレクトリ名をストレージサーバ200にプッシュ通知させることができる。   Note that the front server 100 may transmit a notification request to the storage server 200 when receiving the directory name S27. Thereby, the front server 100 can notify the storage server 200 of a directory name of a directory to be added later.

なお、フロントサーバ100は、ストレージサーバ200により通知されたディレクトリ名S3をユーザ端末400に送信してよいが、これに限定されず、ディレクトリ名S3をフロントサーバ100のAPI内で処理をするのみであってよい。フロントサーバ100は、ストレージサーバ200からディレクトリ名S3を受信した場合、ディレクトリ名S3をユーザ端末400に送信することなしに、メモリに記憶する。フロントサーバ100は、ユーザ端末400からアップロード要求S5を受信した場合、記憶しておいたディレクトリ名S3を読み出し、読み出したディレクトリ名S3および書き込み要求S6をストレージサーバ200に送信する。これにより、フロントサーバ100とユーザ端末400との間の通信回数を削減することができる。   The front server 100 may transmit the directory name S3 notified by the storage server 200 to the user terminal 400, but is not limited to this, and only processes the directory name S3 within the API of the front server 100. It may be. When the front server 100 receives the directory name S3 from the storage server 200, the front server 100 stores the directory name S3 in the memory without transmitting it to the user terminal 400. When receiving the upload request S5 from the user terminal 400, the front server 100 reads the stored directory name S3 and transmits the read directory name S3 and write request S6 to the storage server 200. Thereby, the frequency | count of communication between the front server 100 and the user terminal 400 can be reduced.

[第2実施形態の効果]
第2実施形態のストレージシステム1によれば、フロントサーバ100により処理リクエストを受信する度に、ストレージサーバ200からフロントサーバ100にディレクトリ名を通知する必要がない。これにより、ストレージシステム1によれば、ストレージサーバ200の処理負荷を抑制することができる。また、ストレージシステム1によれば、フロントサーバ100およびストレージサーバ200の通信回数を抑制することができる。
[Effects of Second Embodiment]
According to the storage system 1 of the second embodiment, there is no need to notify the directory name from the storage server 200 to the front server 100 each time a processing request is received by the front server 100. Thereby, according to the storage system 1, the processing load of the storage server 200 can be suppressed. Further, according to the storage system 1, the number of communications between the front server 100 and the storage server 200 can be suppressed.

<第3実施形態>
以下、第3実施形態について説明する。第3実施形態のストレージサーバ200は、ファイルの書き込み時間が所定時間を超える場合に、カレントディレクトリのディレクトリのファイル数の上限値を減少させる点で、上述した第1実施形態および第2実施形態とは異なる。以下、この点を中心に説明する。
<Third Embodiment>
Hereinafter, the third embodiment will be described. The storage server 200 of the third embodiment is different from the first embodiment and the second embodiment described above in that the upper limit value of the number of files in the directory of the current directory is reduced when the file writing time exceeds a predetermined time. Is different. Hereinafter, this point will be mainly described.

[ストレージサーバ200における書き込み処理]
図16は、ストレージサーバ200における第3書き込み処理の流れの一例を示す図である。図16に示した処理は、ストレージ制御部230により所定期間毎に繰り返して実行される。
[Write processing in storage server 200]
FIG. 16 is a diagram illustrating an example of the flow of the third write process in the storage server 200. The process shown in FIG. 16 is repeatedly executed by the storage control unit 230 every predetermined period.

まず、記憶制御部232は、リクエストを受け付けたか否かを判定する(ステップS400)。ファイルカウンタ部234は、リクエストを受け付けた場合、カレントディレクトリのファイル数をカウントアップする(ステップS402)。   First, the storage control unit 232 determines whether a request has been received (step S400). When receiving the request, the file counter unit 234 counts up the number of files in the current directory (step S402).

次に記憶制御部232は、カウントアップされた結果としてのカレントディレクトリのファイル数が上限値以下であるか否かを判定する(ステップS404)。記憶制御部232は、カレントディレクトリのファイル数が上限値以下である場合、カレントディレクトリのディレクトリ名をフロントサーバ100に送信する(ステップS408)。記憶制御部232は、カレントディレクトリのファイル数が上限値を超えた場合、新たなディレクトリ名をカレントディレクトリのディレクトリ名として決定する(ステップS406)。記憶制御部232は、設定した新たなカレントディレクトリのディレクトリ名をフロントサーバ100に返信する(ステップS408)。   Next, the storage control unit 232 determines whether or not the number of files in the current directory as a result of counting up is equal to or less than the upper limit value (step S404). If the number of files in the current directory is less than or equal to the upper limit value, the storage control unit 232 transmits the directory name of the current directory to the front server 100 (step S408). If the number of files in the current directory exceeds the upper limit value, the storage control unit 232 determines a new directory name as the directory name of the current directory (step S406). The storage control unit 232 returns the set directory name of the new current directory to the front server 100 (step S408).

次に、記憶制御部232は、フロントサーバ100から書き込み要求を受信したか否かを判定する(ステップS410)。記憶制御部232は、書き込み要求を受信した場合、指定されたディレクトリ名が設定されたディレクトリが存在しているか否かを判定する(ステップS412)。記憶制御部232は、指定されたディレクトリ名が設定されたディレクトリが存在している場合、当該ディレクトリにファイルを書き込む(ステップS416)。記憶制御部232は、指定されたディレクトリ名が設定されたディレクトリが存在しない場合、決定したカレントディレクトリのディレクトリ名に対応したディレクトリの管理情報をカウンタテーブル244Aに書き込むことで、ディレクトリを追加する(ステップS414)。   Next, the storage control unit 232 determines whether or not a write request has been received from the front server 100 (step S410). When the storage control unit 232 receives a write request, the storage control unit 232 determines whether there is a directory in which the designated directory name is set (step S412). If there is a directory in which the designated directory name is set, the storage control unit 232 writes the file in the directory (step S416). If there is no directory in which the designated directory name is set, the storage control unit 232 adds the directory by writing the management information of the directory corresponding to the determined directory name of the current directory in the counter table 244A (step S414).

次に、記憶制御部232は、追加したディレクトリに対応付けてファイルを書き込む(ステップS416)。次に記憶制御部232は、ファイルの書き込み時間を検出する(ステップS418)。記憶制御部232は、例えば、ハードディスク装置210Aにライトコマンドを出力した時刻から、ハードディスク装置210Aから書き込み完了の応答を入力した時刻までの期間を計測することで、ファイルの書き込み時間を検出する。   Next, the storage control unit 232 writes a file in association with the added directory (step S416). Next, the storage controller 232 detects the file writing time (step S418). For example, the storage control unit 232 detects the file writing time by measuring the period from the time when the write command is output to the hard disk device 210A to the time when the write completion response is input from the hard disk device 210A.

記憶制御部232は、検出した書き込み時間が所定時間を超えているか否かを判定する(ステップS420)。記憶制御部232は、検出した書き込み時間が所定時間を超えている場合、カレントディレクトリのディレクトリについての上限値を減少させる(ステップS422)。   The storage control unit 232 determines whether or not the detected writing time exceeds a predetermined time (step S420). If the detected write time exceeds the predetermined time, the storage control unit 232 decreases the upper limit value for the directory of the current directory (step S422).

なお、ディレクトリ名リクエストを受信していない場合、書き込み要求を受信しない場合、および書き込み時間が所定時間を超えていない場合、ストレージサーバ200は、本フローチャートの処理を終了する。   If no directory name request has been received, no write request has been received, and if the write time has not exceeded the predetermined time, the storage server 200 ends the processing of this flowchart.

なお、ストレージシステム1は、ストレージサーバ200によりファイルの書き込み時間が所定時間を超えた場合にファイル数の上限値を変更したが、これに限定されない。フロントサーバ100は、ストレージサーバ200に書き込み要求を送信した時刻から、ストレージサーバ200からレスポンスを受信した時刻までの時間が所定時間を超えた場合に、ストレージサーバ200に通知してよい。ストレージサーバ200は、フロントサーバ100から通知を受信した場合に、カレントディレクトリに対応付けてファイルを書き込むことを制限する。そして、ストレージサーバ200は、新たなカレントディレクトリのディレクトリ名を決定して、フロントサーバ100に新たなカレントディレクトリのディレクトリ名を通知する。   Although the storage system 1 changes the upper limit value of the number of files when the file write time exceeds a predetermined time by the storage server 200, the present invention is not limited to this. The front server 100 may notify the storage server 200 when the time from the time when the write request is transmitted to the storage server 200 to the time when the response is received from the storage server 200 exceeds a predetermined time. When the storage server 200 receives a notification from the front server 100, the storage server 200 restricts writing a file in association with the current directory. Then, the storage server 200 determines the directory name of the new current directory and notifies the front server 100 of the directory name of the new current directory.

また、ストレージシステム1は、ファイルの書き込み時間が所定時間を超える場合にディレクトリに対応する上限値を減少させるが、これに限定されない。ストレージシステム1は、ファイルの書き込み時間が所定時間よりも短い場合に、ディレクトリに対応する上限値を増加させてよい。   Further, the storage system 1 decreases the upper limit value corresponding to the directory when the file writing time exceeds a predetermined time, but is not limited thereto. The storage system 1 may increase the upper limit value corresponding to the directory when the file writing time is shorter than the predetermined time.

[第3実施形態の効果]
第3実施形態のストレージシステム1によれば、ファイルの書き込み時間が所定時間を超える場合に、カレントディレクトリのディレクトリに対応する上限値を減少させるので、カレントディレクトリに対応付けて書き込むファイル数を抑制することができる。これにより、ストレージシステム1によれば、ファイルの書き込み時間が長くなることを抑制することができる。
[Effect of the third embodiment]
According to the storage system 1 of the third embodiment, when the file writing time exceeds a predetermined time, the upper limit value corresponding to the directory of the current directory is decreased, so the number of files to be written in association with the current directory is suppressed. be able to. Thereby, according to the storage system 1, it can suppress that the write time of a file becomes long.

<実施例1>
以下、上述したストレージシステム1の実施例1を説明する。図17は、カレントディレクトリに対応付けて書き込んだファイル数と、秒単位の書き込みリクエストの処理数との関係を示す図である。図17において、実施例1は、上述した実施形態において各ディレクトリに対するファイル数の上限値を「1000」に設定した場合の書き込みリクエストの処理数の変化を表している。実施例2は、上述した実施形態において各ディレクトリに対するファイル数の上限値を「10000」に設定した場合の書き込みリクエストの処理数の変化を表している。比較例1は、1つのカレントディレクトリに対応付けてファイルを書き込んだ場合の書き込みリクエストの処理数の変化を表している。比較例2は、ディレクトリを固定数設定し、さらに、当該ディレクトリの下位にディレクトリを同数設定した場合の書き込みリクエストの処理数の変化を表している。
<Example 1>
Hereinafter, the first embodiment of the storage system 1 described above will be described. FIG. 17 is a diagram showing the relationship between the number of files written in association with the current directory and the number of write requests processed per second. In FIG. 17, Example 1 represents a change in the number of write requests processed when the upper limit value of the number of files for each directory is set to “1000” in the above-described embodiment. Example 2 represents a change in the number of write requests processed when the upper limit value of the number of files for each directory is set to “10000” in the above-described embodiment. Comparative Example 1 represents a change in the number of write requests processed when a file is written in association with one current directory. Comparative example 2 represents a change in the number of write requests processed when a fixed number of directories are set and the same number of directories is set below the directory.

実施例1および実施例2におけるリクエストの処理数は、各ディレクトリに対応したファイル数が増加しても大きく低下していないことが分かる。一方、比較例1におけるリクエストの処理数は、ファイル数が一定数を超えると急峻に低下していることが分かる。また、比較例2におけるリクエストの処理数は、ファイル数が一定数を超えても、実施例1および実施例2におけるリクエストの処理数より低いことが分かる。   It can be seen that the number of requests processed in the first and second embodiments does not drop significantly even when the number of files corresponding to each directory increases. On the other hand, it can be seen that the number of requests processed in Comparative Example 1 sharply decreases when the number of files exceeds a certain number. It can also be seen that the number of requests processed in Comparative Example 2 is lower than the number of requests processed in Example 1 and Example 2 even if the number of files exceeds a certain number.

<実施例2>
以下、上述したストレージシステム1の実施例2を説明する。図18は、比較例1のディスクオフセット、シーク回数、およびスループットを表す図である。図19は、実施例のディスクオフセット、シーク回数、およびスループットを表す図である。図18および図19の特性は、blktraceを用いて、ストレージサーバ200におけるインターフェース255(ブロックI/Oレイヤ)における信号を検出して得たものである。
<Example 2>
Hereinafter, a second embodiment of the above-described storage system 1 will be described. FIG. 18 is a diagram illustrating the disk offset, the number of seeks, and the throughput of Comparative Example 1. FIG. 19 is a diagram illustrating the disk offset, the number of seeks, and the throughput of the example. The characteristics shown in FIGS. 18 and 19 are obtained by detecting a signal at the interface 255 (block I / O layer) in the storage server 200 using blktrace.

図18および図19を参照すると、実施例におけるディスクオフセットおよびシーク回数は、比較例におけるディスクオフセットおよびシーク回数よりも低いことが分かる。また、実施例におけるスループットは、比較例におけるスループットよりも高いことが分かる。
<実施例3>
以下、上述したストレージシステム1の実施例3を説明する。図20は、磁気ディスク221上に書き込まれたファイルの物理位置の時間的な変化を示す図である。図20を参照すると、実施例は、比較例よりも狭い範囲にファイルを書き込んでいることが分かる。 <ハードウェア構成>
図21は、ユーザ端末400、フロントサーバ100、ストレージサーバ200、およびメタデータデータベースサーバ300のハードウェア構成の一例を示す図である。本図は、ユーザ端末400がスマートフォンなどの携帯電話である例を示している。ユーザ端末400は、例えば、CPU401、RAM402、ROM403、フラッシュメモリなどの二次記憶装置404、タッチパネル405、および無線通信モジュール406が、内部バスあるいは専用通信線によって相互に接続された構成となっている。ナビアプリは、ネットワークNWを介してダウンロードされ、二次記憶装置404に格納される。
Referring to FIGS. 18 and 19, it can be seen that the disk offset and the number of seeks in the example are lower than the disk offset and the number of seeks in the comparative example. Moreover, it turns out that the throughput in an Example is higher than the throughput in a comparative example.
<Example 3>
The third embodiment of the storage system 1 will be described below. FIG. 20 is a diagram showing temporal changes in the physical position of a file written on the magnetic disk 221. Referring to FIG. 20, it can be seen that the example writes the file in a narrower range than the comparative example. <Hardware configuration>
FIG. 21 is a diagram illustrating an example of a hardware configuration of the user terminal 400, the front server 100, the storage server 200, and the metadata database server 300. This figure shows an example in which the user terminal 400 is a mobile phone such as a smartphone. The user terminal 400 has a configuration in which, for example, a CPU 401, a RAM 402, a ROM 403, a secondary storage device 404 such as a flash memory, a touch panel 405, and a wireless communication module 406 are connected to each other via an internal bus or a dedicated communication line. . The navigation application is downloaded via the network NW and stored in the secondary storage device 404.

フロントサーバ100は、例えば、NIC101、CPU102、RAM103、ROM104、フラッシュメモリやHDDなどの二次記憶装置105、およびドライブ装置106が、内部バスあるいは専用通信線によって相互に接続された構成となっている。ドライブ装置106には、光ディスクなどの可搬型記憶媒体が装着される。二次記憶装置105、またはドライブ装置106に装着された可搬型記憶媒体に記憶されたプログラムがDMAコントローラ(不図示)などによってRAM103に展開され、CPU102によって実行されることで、各サーバの機能部が実現される。   The front server 100 has a configuration in which, for example, a NIC 101, a CPU 102, a RAM 103, a ROM 104, a secondary storage device 105 such as a flash memory or an HDD, and a drive device 106 are connected to each other via an internal bus or a dedicated communication line. . The drive device 106 is loaded with a portable storage medium such as an optical disk. A program stored in a portable storage medium attached to the secondary storage device 105 or the drive device 106 is expanded in the RAM 103 by a DMA controller (not shown) or the like, and executed by the CPU 102, so that the functional unit of each server Is realized.

ストレージサーバ200は、例えば、NIC201、CPU202、RAM203、ROM204、フラッシュメモリやHDDなどの二次記憶装置205、およびドライブ装置206が、内部バスあるいは専用通信線によって相互に接続された構成となっている。ドライブ装置206には、光ディスクなどの可搬型記憶媒体が装着される。二次記憶装置205、またはドライブ装置206に装着された可搬型記憶媒体に記憶されたプログラムがDMAコントローラ(不図示)などによってRAM203に展開され、CPU202によって実行されることで、各サーバの機能部が実現される。   The storage server 200 has a configuration in which, for example, a NIC 201, a CPU 202, a RAM 203, a ROM 204, a secondary storage device 205 such as a flash memory or an HDD, and a drive device 206 are connected to each other via an internal bus or a dedicated communication line. . The drive device 206 is loaded with a portable storage medium such as an optical disk. A program stored in a portable storage medium attached to the secondary storage device 205 or the drive device 206 is expanded in the RAM 203 by a DMA controller (not shown) or the like and executed by the CPU 202, so that the functional unit of each server Is realized.

メタデータデータベースサーバ300は、例えば、NIC301、CPU302、RAM303、ROM304、フラッシュメモリやHDDなどの二次記憶装置305、およびドライブ装置306が、内部バスあるいは専用通信線によって相互に接続された構成となっている。ドライブ装置306には、光ディスクなどの可搬型記憶媒体が装着される。二次記憶装置305、またはドライブ装置306に装着された可搬型記憶媒体に記憶されたプログラムがDMAコントローラ(不図示)などによってRAM303に展開され、CPU302によって実行されることで、各サーバの機能部が実現される。   The metadata database server 300 has a configuration in which, for example, a NIC 301, a CPU 302, a RAM 303, a ROM 304, a secondary storage device 305 such as a flash memory or an HDD, and a drive device 306 are connected to each other via an internal bus or a dedicated communication line. ing. The drive device 306 is loaded with a portable storage medium such as an optical disk. A program stored in a portable storage medium mounted on the secondary storage device 305 or the drive device 306 is expanded in the RAM 303 by a DMA controller (not shown) or the like, and executed by the CPU 302, so that the functional unit of each server Is realized.

以上、本発明を実施するための形態について実施形態を用いて説明したが、本発明はこうした実施形態に何等限定されるものではなく、本発明の要旨を逸脱しない範囲内において種々の変形及び置換を加えることができる。   As mentioned above, although the form for implementing this invention was demonstrated using embodiment, this invention is not limited to such embodiment at all, In the range which does not deviate from the summary of this invention, various deformation | transformation and substitution Can be added.

1…ストレージシステム
100…フロントサーバ
130…フロント制御部
132…アプリケーション処理部
134…ファイル管理部
136…キャッシュメモリ
136A…ディレクトリ情報
200…ストレージサーバ
210…ファイルストレージ部
230…ストレージ制御部
232…記憶制御部
234…ファイルカウンタ部
244…ファイル数記憶部
244A…カウンタテーブル
400…ユーザ端末
DESCRIPTION OF SYMBOLS 1 ... Storage system 100 ... Front server 130 ... Front control part 132 ... Application processing part 134 ... File management part 136 ... Cache memory 136A ... Directory information 200 ... Storage server 210 ... File storage part 230 ... Storage control part 232 ... Storage control part 234 ... File counter unit 244 ... File number storage unit 244A ... Counter table 400 ... User terminal

Claims (11)

ディレクトリ名を指定したファイルの書き込み要求を受け付ける受付部と、
各ディレクトリに対応して記憶装置に書き込まれるファイル数に設けられる上限の範囲内で、前記受付部により受け付けられた書き込み要求に応答して、指定された前記ディレクトリ名のディレクトリに対応付けて前記ファイルを前記記憶装置に書き込む制御部と、 を備える、ストレージ装置。
A reception unit that accepts a write request for a file that specifies a directory name;
In response to a write request accepted by the accepting unit within the upper limit of the number of files written to the storage device corresponding to each directory, the file is associated with the directory of the specified directory name A storage unit comprising: a control unit that writes to the storage device.
前記制御部は、各ディレクトリに対応付けて書き込まれたファイル数をカウントし、カウントしたファイル数が前記上限を超えた場合に、前記ディレクトリ名のディレクトリに対応付けてファイルを書き込むことを制限する、
請求項1に記載のストレージ装置。
The control unit counts the number of files written in association with each directory, and restricts writing of files in association with the directory of the directory name when the counted number of files exceeds the upper limit.
The storage apparatus according to claim 1.
前記制御部は、各ディレクトリに対応付けて書き込まれたファイル数をカウントし、カウントしたファイル数が前記上限を超えた場合に、新たなディレクトリ名を決定し、決定した前記新たなディレクトリ名を外部装置に送信する、
請求項2に記載のストレージ装置。
The control unit counts the number of files written in association with each directory, determines a new directory name when the counted number of files exceeds the upper limit, and determines the determined new directory name as an external Send to device,
The storage apparatus according to claim 2.
前記制御部は、前記受付部により前記新たなディレクトリ名を指定したファイルの書き込み要求を受け付けた場合に、前記新たなディレクトリ名に対応するディレクトリの管理情報をメモリに書き込み、前記新たなディレクトリ名のディレクトリに対応付けて前記ファイルを前記記憶装置に書き込む、
請求項3に記載のストレージ装置。
When the receiving unit receives a write request for a file specifying the new directory name by the receiving unit, the control unit writes management information of a directory corresponding to the new directory name to a memory, and stores the new directory name Write the file to the storage device in association with a directory;
The storage device according to claim 3.
前記制御部は、前記新たなディレクトリ名を決定した場合に、決定した前記新たなディレクトリ名に対応するディレクトリの管理情報をメモリに書き込む、
請求項3に記載のストレージ装置。
When the control unit determines the new directory name, the control unit writes management information of a directory corresponding to the determined new directory name in a memory.
The storage device according to claim 3.
前記制御部は、前記新たなディレクトリ名を決定した場合に、ファイル数が前記上限を超えたディレクトリに対応付けてファイルを書き込むことなしに、前記新たなディレクトリ名のディレクトリに対応付けてファイルを前記記憶装置に書き込む、
請求項4または5に記載のストレージ装置。
When the control unit determines the new directory name, the control unit writes the file in association with the directory of the new directory name without writing the file in association with the directory in which the number of files exceeds the upper limit. Write to storage,
The storage apparatus according to claim 4 or 5.
前記制御部は、前記記憶装置における前記ファイルの書き込み時間に基づいて、各ディレクトリに対応付けて書き込まれるファイル数に設けられる前記上限を変更する、
請求項1から6のうちいずれか1項に記載のストレージ装置。
The control unit changes the upper limit provided for the number of files written in association with each directory, based on the writing time of the file in the storage device.
The storage apparatus according to any one of claims 1 to 6.
前記制御部は、
前記受付部により端末装置からのリクエストを受け付けた場合に、新たな書き込み要求に基づいて書き込まれるファイルに対応付け可能なカレントディレクトリのディレクトリ名を通知部に要求する要求部と、
前記要求部から供給された要求に対して、前記カレントディレクトリのディレクトリ名を前記要求部に通知する通知部と、を含む、
請求項1から7のうちいずれか1項に記載のストレージ装置。
The controller is
A request unit that requests the notification unit a directory name of a current directory that can be associated with a file to be written based on a new write request when a request is received from the terminal device by the reception unit;
A notification unit for notifying the request unit of the directory name of the current directory in response to the request supplied from the request unit;
The storage device according to any one of claims 1 to 7.
前記制御部は、
新たな書き込み要求に基づいて書き込まれるファイルに対応付け可能なカレントディレクトリが変更した場合に、変更したカレントディレクトリのディレクトリ名を通知することを通知部に要求する要求部と、
前記カレントディレクトリを変更した場合に、前記カレントディレクトリのディレクトリ名を前記要求部に通知する通知部と、を含む、
請求項1から7のうちいずれか1項にストレージ装置。
The controller is
A request unit that requests the notification unit to notify the directory name of the changed current directory when the current directory that can be associated with a file to be written based on a new write request is changed;
A notification unit for notifying the request unit of the directory name of the current directory when the current directory is changed,
The storage apparatus according to any one of claims 1 to 7.
ディレクトリ名を指定したファイルの書き込み要求を受け付け、
各ディレクトリに対応して記憶装置に書き込まれるファイル数に設けられる上限の範囲内で、受け付けた書き込み要求に応答して、指定された前記ディレクトリ名のディレクトリに対応付けて前記ファイルを前記記憶装置に書き込む、
ファイル書き込み方法。
Accepts a write request for a file with a directory name specified,
In response to the received write request, the file is associated with the directory of the specified directory name in the storage device within the upper limit set for the number of files written to the storage device corresponding to each directory. Write,
File writing method.
コンピュータに、
ディレクトリ名を指定したファイルの書き込み要求を受け付けさせ、
各ディレクトリに対応して記憶装置に書き込まれるファイル数に設けられる上限の範囲内で、受け付けた書き込み要求に応答して、指定された前記ディレクトリ名のディレクトリに対応付けて前記ファイルを前記記憶装置に書き込ませる、
プログラム。
On the computer,
Accept a write request for a file with a directory name specified,
In response to the received write request, the file is associated with the directory of the specified directory name in the storage device within the upper limit set for the number of files written to the storage device corresponding to each directory. To write,
program.
JP2017159250A 2017-08-22 2017-08-22 Storage device, file writing method, and program Active JP6720120B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2017159250A JP6720120B2 (en) 2017-08-22 2017-08-22 Storage device, file writing method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2017159250A JP6720120B2 (en) 2017-08-22 2017-08-22 Storage device, file writing method, and program

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2016104303A Division JP6227055B1 (en) 2016-05-25 2016-05-25 Storage system and file writing method

Publications (3)

Publication Number Publication Date
JP2017212009A true JP2017212009A (en) 2017-11-30
JP2017212009A5 JP2017212009A5 (en) 2019-05-23
JP6720120B2 JP6720120B2 (en) 2020-07-08

Family

ID=60476192

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2017159250A Active JP6720120B2 (en) 2017-08-22 2017-08-22 Storage device, file writing method, and program

Country Status (1)

Country Link
JP (1) JP6720120B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11080638B2 (en) 2017-04-27 2021-08-03 Toyota Jidosha Kabushiki Kaisha Analysis technique presenting system, method, and program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11080638B2 (en) 2017-04-27 2021-08-03 Toyota Jidosha Kabushiki Kaisha Analysis technique presenting system, method, and program

Also Published As

Publication number Publication date
JP6720120B2 (en) 2020-07-08

Similar Documents

Publication Publication Date Title
US10484468B2 (en) Method and device for downloading file
US20170346893A1 (en) Peer-to-peer data migration
US7962518B2 (en) Method and apparatus to control media transfer protocol device to manage media file
WO2020134616A1 (en) Method, system, apparatus and device for processing request in alliance chain
US11455117B2 (en) Data reading method, apparatus, and system, avoiding version rollback issues in distributed system
JP6772794B2 (en) Distributed data management device, distributed data management program and distributed data management method
JP6227055B1 (en) Storage system and file writing method
JP6720120B2 (en) Storage device, file writing method, and program
US10055443B2 (en) Information processing method, storage medium, and information processing apparatus
JP5976033B2 (en) Mobile terminal, access point related content acquisition method, mobile terminal program
WO2019228009A1 (en) Lsm tree optimization method and device and computer equipment
CN112558872A (en) Data processing method and device, storage medium and electronic equipment
CN107209656B (en) Adjusting speaker settings
KR20090020327A (en) Method and apparatus for receiving/transmitting contents automatically
JP2015185119A (en) Position content providing server, position content providing method, and program for position content providing server
KR20150139546A (en) Removable storage device identity and configuration information
WO2016172948A1 (en) Routing information configuration method and apparatus
CN105389108A (en) Identification method and device of touch operation of mobile terminal
US10375370B2 (en) Audio capture on mobile client devices
JP6310512B2 (en) Access point related content providing server
JP5729823B2 (en) Backup apparatus, backup method, and backup program
US20210144217A1 (en) Service communication proxy apparatus and method
JP5776403B2 (en) Region search method, region search program, and information processing apparatus
CN104993999A (en) Information processing method and server
JP6498462B2 (en) User information registration server, user information registration method, and user information registration program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20190319

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20190408

A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A712

Effective date: 20191101

RD03 Notification of appointment of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7423

Effective date: 20191108

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20200227

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20200303

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20200421

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20200609

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20200617

R150 Certificate of patent or registration of utility model

Ref document number: 6720120

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313111

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350