JP5574774B2 - File server, continuous snapshot management method, and continuous snapshot management program - Google Patents

File server, continuous snapshot management method, and continuous snapshot management program Download PDF

Info

Publication number
JP5574774B2
JP5574774B2 JP2010070622A JP2010070622A JP5574774B2 JP 5574774 B2 JP5574774 B2 JP 5574774B2 JP 2010070622 A JP2010070622 A JP 2010070622A JP 2010070622 A JP2010070622 A JP 2010070622A JP 5574774 B2 JP5574774 B2 JP 5574774B2
Authority
JP
Japan
Prior art keywords
snapshot
file
snapshots
file server
file system
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2010070622A
Other languages
Japanese (ja)
Other versions
JP2011204008A (en
Inventor
隆介 小西
敏 盛合
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nippon Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone 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 Nippon Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2010070622A priority Critical patent/JP5574774B2/en
Publication of JP2011204008A publication Critical patent/JP2011204008A/en
Application granted granted Critical
Publication of JP5574774B2 publication Critical patent/JP5574774B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

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

Description

本発明は、ファイルサーバ及び連続スナップショット管理方法及び連続スナップショット管理プログラムに係り、特に、連続的なスナップショットを作成するためのファイルサーバ及び連続スナップショット管理方法及び連続スナップショット管理プログラムに関する。 The present invention relates to a file server, a continuous snapshot management method, and a continuous snapshot management program, and more particularly, to a file server, a continuous snapshot management method, and a continuous snapshot management program for creating a continuous snapshot .

ファイルサーバは、自身が有する記憶装置を、ネットワーク上の他のコンピュータと共有して、他のコンピュータから利用できるようにする機能をもったコンピュータまたは装置である。記憶装置としてはハードディスクやフラッシュメモリなどの不揮発でランダムアクセスが可能なデバイスが用いられる。ファイルサーバは、ファイルシステムという基本ソフト(OS)の機能を通じて、データをファイルという資源として抽象化して扱い、その生成・削除やデータの読み書きといったアクセス手段を提供する。   A file server is a computer or device having a function of sharing a storage device of itself with other computers on a network and making them available from other computers. As the storage device, a non-volatile and random accessible device such as a hard disk or a flash memory is used. The file server abstracts and handles data as a resource called a file through a function of a basic software (OS) called a file system, and provides access means such as generation / deletion and reading / writing of data.

通常ファイルシステムは、データの管理を容易かつ効率的にするために、フォルダもしくはディレクトリと呼ばれるファイルもしくはディレクトリ自身の入れ物の抽象化である永続的な資源により、ファイルを階層的に管理し、パス名という名前によってそれらの所在を指定することが可能であるが、ファイルサーバはこういった名前空間を他のコンピュータから透過的にアクセスできるような機能も備える。これらのファイルや名前空間に対するアクセスや操作の機能は、所定のネットワークプロトコル(リモートファイル管理プロトコル)を通じて、クライアントとサーバ間で伝達される。代表的なリモートファイル管理プロトコルとしては、NFS(Network File System)やCIFS(Common Internet File system)、あるいはHTTPを拡張したWebDAV(Web-based Distributed Authoring and Versioning)が知られている。   In order to make data management easier and more efficient, file systems usually manage files hierarchically with persistent resources, which are abstractions of files or directories themselves, called folders or directories, and path names. However, the file server also has a function of making such a name space transparently accessible from other computers. Access and operation functions for these files and name spaces are transmitted between the client and the server through a predetermined network protocol (remote file management protocol). As a typical remote file management protocol, NFS (Network File System), CIFS (Common Internet File system), or WebDAV (Web-based Distributed Authoring and Versioning) extending HTTP is known.

ファイルサーバは、ユーザのデータを保管する役割を担うため、高い信頼性やデータ保護機能が求められる。ハードウェア障害からデータを保護するため、ファイルサーバは複数の記憶装置を組み合わせ、ミラーリング、あるいはRAID(Redundant Arrays of Inexpensive Disks)などの技法を適用して冗長化する場合が多い。   Since the file server plays a role of storing user data, high reliability and a data protection function are required. In order to protect data from hardware failure, a file server is often made redundant by combining a plurality of storage devices and applying a technique such as mirroring or RAID (Redundant Arrays of Inexpensive Disks).

こういった冗長化手法は、記憶装置の故障からデータを保護するのに有効であるが、ユーザが誤って行った操作や、ソフトウェアのバグによるデータ破壊、あるいはウィルスによるデータ改ざんなどに対しては、冗長化されたデータが全て同時に影響を受けてしまうため有効でない。   These redundancy methods are effective in protecting data from storage device failures, but they can be used to prevent accidental user operations, data corruption due to software bugs, or data tampering with viruses. This is not effective because all redundant data is affected at the same time.

これらのハードウェア障害に起因しない問題によるデータ喪失を避ける一つ方法は、記憶装置のデータをテープや他の記憶装置に対し定期的にバックアップを行うことである。あるいはファイルサーバの中には、記憶装置(ブロックデバイス)もしくはファイルシステムのある時点の状態を凍結して残し、その凍結した状態(スナップショット)を後から参照できるようにすることで、前記の障害によるデータ喪失を防ぐために提供するものがある。ファイルシステムのスナップショットは、ファイルのデータと、ファイルを管理するために同一記憶装置上に保存されるメタデータと呼ばれるファイルシステムの内部データを、コピーして複製を作ったり、データやメタデータを上書きせずに、新たな場所に書き込むことで効率的に過去の状態を残す"Copy-on-Write"と呼ばれる書き込み手法を採ることにより実現される。   One way to avoid data loss due to problems not caused by these hardware failures is to regularly back up the data in the storage device to tape or other storage devices. Alternatively, in the file server, the state of the storage device (block device) or file system at a certain point in time is left frozen, and the frozen state (snapshot) can be referred to later, so that the above-mentioned failure There is something to provide to prevent data loss due to. File system snapshots copy file data and file system internal data called metadata that is stored on the same storage device to manage the file, and copy data and metadata. This is realized by adopting a writing method called “Copy-on-Write” that efficiently leaves the past state by writing to a new location without overwriting.

しかし通常バックアップやスナップショットは、運用システムに対する負荷や、バックアップ、スナップショットの取得作成にかかる時間そのものの制約により、あまり頻度を高めることができず、結果として最後の取得時刻以降の誤操作、バグによるデータ破壊、改ざん、などよるデータ喪失を避けることは難しい。   However, regular backups and snapshots cannot be increased frequently due to the load on the operating system and the time taken to create backups and snapshots themselves, resulting in incorrect operations and bugs after the last acquisition time. It is difficult to avoid data loss due to data destruction and alteration.

これを克服する技術として、連続的に他のマシンにバックアップを転送するCDP(Continuous Data Protection)やログ構造化ファイルシステム方式に基づき連続的にスナップショットが取得可能なファイルシステムNILFS(New Implementation of the Log-Structured Filesystem)がある(例えば、非特許文献1参照)。NILFSは、変更のあったデータとそれを管理するメタデータブロックをディスク上に追記するログ構造化ファイルシステムを応用し、ログ構造化ファイルシステムが定期的に生成するチェックポイント(ファイルシステムのある首尾一貫した状態を保つ点)をスナップショットとしてアクセス可能にする技術である。NILFSはローカルファイルシステム内に多数のスナップショット(もしくはチェックポイント)を自動的かつ暗黙的に生成し、変更データをディスクに書き戻す際や、同期保証つきの書き込みを実行する粒度で、細かくスナップショットを生成することができる。   As a technology to overcome this, NILFS (New Implementation of the file system) that can continuously acquire snapshots based on CDP (Continuous Data Protection) that continuously transfers backups to other machines and log structured file system method Log-Structured Filesystem) (see Non-Patent Document 1, for example). NILFS applies a log structured file system in which changed data and metadata blocks that manage it are added to the disk, and checkpoints generated periodically by the log structured file system (successful with a file system). This is a technology that makes a consistent state) accessible as a snapshot. NILFS automatically and implicitly generates a large number of snapshots (or checkpoints) in the local file system, and makes detailed snapshots at the granularity of writing modified data back to disk and writing with guaranteed synchronization. Can be generated.

図18に、連続スナップショットファイルシステムの概念を示す。   FIG. 18 shows the concept of the continuous snapshot file system.

通常のファイルシステムではアプリケーションが編集して保存したファイルはディスク上でも上書き保存され、過去のバージョンのデータは残らない。バックアップを定期的に実施している場合は、バックアップを実施した時点の状態は復元可能であるが、バックアップ間の変更、特に、最後にバックアップを取得した以降に変更したデータは保護されない。これに対しNILFSでは、以前のデータも上書きされずにスナップショットとして記憶装置上に残っており、前述の人為的あるいはソフトウェア的な障害により失われたデータやディレクトリを復元することができる。   In a normal file system, files edited and saved by the application are overwritten on the disk, and no past version data remains. When backups are performed regularly, the state at the time of backup can be restored, but changes between backups, in particular, data that has changed since the last backup was acquired are not protected. On the other hand, in NILFS, the previous data is not overwritten and remains on the storage device as a snapshot, and data and directories lost due to the above-mentioned artificial or software failure can be restored.

NILFSの連続スナップショット手法は、こういったデータ保護のソリューションとしては、専用のハードを必要としない、運用システムに対するオーバヘッドがほぼ無視できる、ファイル単位ではなく、ファイルシステム全体の整合性を保証するようなリカバリが可能である、などの利点を有している。   NILFS's continuous snapshot method does not require dedicated hardware as such a data protection solution, the overhead on the operating system is almost negligible, and guarantees the integrity of the entire file system, not the file unit. It has the advantage that it can be recovered easily.

佐藤孝治、小西隆介、木原誠司、天海良治、盛合敏「ログ構造化ファイルシステムNILFSの設計と実装」, 情報処理学会 論文誌コンピューティングシステム(ACS), Vol.2, No.1, pp.110-122, 2009.Koji Sato, Ryusuke Konishi, Seiji Kihara, Ryoji Amami, Satoshi Moriai “Design and Implementation of Log Structured File System NILFS”, IPSJ Transactions on Computing Systems (ACS), Vol.2, No.1, pp.110 -122, 2009.

しかしながら、NILFSのような連続的なスナップショット作成技術により、多数のスナップショットを追記的に生成すると、スナップショットが保持する過去のデータを維持するため、記憶装置の容量が逼迫することになる。このためスナップショットを必要に応じ削除してディスク領域を解放するなどの操作が必要になるが、前述のファイルサーバではこういった操作は自律的に行えないと、ユーザの利便性・保守性を著しく損なうことになる。   However, if a large number of snapshots are additionally generated by a continuous snapshot creation technique such as NILFS, the past data held by the snapshots is maintained, so that the capacity of the storage device becomes tight. For this reason, operations such as deleting snapshots as necessary to free disk space are necessary. However, with the above-mentioned file server, such operations cannot be performed autonomously, improving user convenience and maintainability. It will be seriously damaged.

ここで多数生成されるスナップショットの削除は、ファイルサーバにI/O負荷をかけるので、ユーザからのアクセスの応答性が低下しないよう調整することが望ましい。一つの方法は、夜間などの業務時間外にスナップショットの削除処理をずらすことであるが、NILFSのようにスナップショットが高い頻度で生成されるシステムにおいては、スケジュールされた削除処理を実施する間に多数のスナップショットが蓄積され、記憶装置の使用量の変動が大きくなる。過渡的に必要以上の容量を消費するため、容量不足が生じやすくなる。   Since deletion of a large number of snapshots generated here places an I / O load on the file server, it is desirable to adjust so that the responsiveness of access from the user does not deteriorate. One method is to shift the snapshot deletion process outside business hours such as at night, but in a system where snapshots are generated at a high frequency, such as NILFS, during the scheduled deletion process. A large number of snapshots are accumulated in the storage device, and the usage amount of the storage device varies greatly. Since a capacity more than necessary is consumed transiently, a capacity shortage is likely to occur.

一方、ファイルサーバのクライアント側に視点を移すと、多数のスナップショットが提供されることにより、それを閲覧するユーザが混乱したり、クライアントシステムのスナップショット処理が多数のスナップショットを扱いきれなくなるなどの弊害が生じる。今日のコモディティPC向けのOSの中には、ファイルサーバのスナップショット機能を用いてファイルの変更履歴を抽出し、ユーザにファイル単位の履歴参照を可能にするものがあるが、こういった機能はバックグラウンド処理としてスナップショットを横断的に参照するため、スナップショット数に応じて処理時間とメモリ消費量が増え、クライアントPC(パーソナルコンピュータ)の応答性や安定性を低下させる。   On the other hand, when the viewpoint is moved to the client side of the file server, a large number of snapshots are provided, so that the user who views them is confused, and the snapshot processing of the client system cannot handle a large number of snapshots. The harmful effects of Some of today's commodity PC OSs use the file server's snapshot function to extract file change history and allow the user to refer to the history of each file. Since the snapshot is referred to as a background process, the processing time and memory consumption increase according to the number of snapshots, and the responsiveness and stability of the client PC (personal computer) are reduced.

さらに、共有ファイルサーバの一つの利用法として、ユーザのPC上のデータのバックアップに使う場合があるが、こういった用途ではファイルサーバ上のユーザのデータは、バックアップの頻度でしか更新されないので、バックアップ間の更新データは保護されず、連続スナップショットのきめ細やかなスナップショット作成機能を活かすことができない。   Furthermore, as one method of using the shared file server, it may be used for backing up data on the user's PC. In such applications, the user's data on the file server is updated only at the frequency of backup. Update data between backups is not protected, and the detailed snapshot creation function of continuous snapshots cannot be used.

また、連続スナップショットによって多数のスナップショットをファイルサーバ上で提供することの他の問題として、所望のファイルを探し出すことが難しくなることが挙げられる。このため補助的な手段としてファイル検索が重要となる。
とりわけ、多数のスナップショットから効率的にファイルを探し出す手段としてインデックス検索方式に基づくファイル検索機能が有効である。NILFSの連続スナップショットは、ファイルシステムの名前空間の広がりに加えて、時間的な広がりも与えるが、過去のスナップショットのそれぞれをサブディレクトリとして割り付けることで、スナップショット上のファイルも検索対象に加えることができる。
Another problem of providing a large number of snapshots on a file server by continuous snapshots is that it becomes difficult to find a desired file. For this reason, file search is important as an auxiliary means.
In particular, a file search function based on an index search method is effective as a means for efficiently searching for a file from a large number of snapshots. NILFS continuous snapshots provide time spread in addition to the expansion of the file system name space, but by assigning each of the past snapshots as subdirectories, the files on the snapshot are also included in the search target. be able to.

しかしながら、このように各スナップショットを単純に名前空間に割り付けて検索を行う場合には、ファイルがスナップショット単位で履歴が分かれ、ユーザの利便性の面でも、検索インデックスの効率の面でも無駄がある。特に、スナップショットが連続的に生成され、削除される状況に対して、検索インデックスを自動かつ効率的に保守することが求められる。   However, when searching by simply assigning each snapshot to the name space in this way, the history of the file is divided in units of snapshots, which is wasteful in terms of user convenience and search index efficiency. is there. In particular, it is required to maintain a search index automatically and efficiently for situations where snapshots are continuously generated and deleted.

本発明は、上記の点に鑑みなされたもので、スナップショットが連続的に生成され、削除される状況において、直近の誤操作によって喪失したデータは保全し、一定時間経った過去のスナップショットについては時間経過に応じて残すようなスナップショットを自動かつ効率的に保守することが可能なファイルサーバ及び連続スナップショット管理方法及び連続スナップショット管理プログラムを提供することを目的とする。 The present invention has been made in view of the above points. In a situation where snapshots are continuously generated and deleted, data lost due to the latest erroneous operation is preserved, and past snapshots after a certain period of time are preserved. It is an object of the present invention to provide a file server, a continuous snapshot management method, and a continuous snapshot management program that can automatically and efficiently maintain snapshots that remain as time passes.

図1は、本発明の原理構成図である。   FIG. 1 is a principle configuration diagram of the present invention.

本発明(請求項1)は、ファイルの内容や属性、ディレクトリツリーの構成などの状態の変更を検知し、記憶手段110の同一ボリューム内にスナップショットを自動的かつ追加的に作成するファイルシステム151に対するスナップショットの管理を行うファイルサーバであって、
ファイルシステム151からスナップショットを取得し、該スナップショットの生成時刻の情報に基づきスナップショットをグループ分けし、現在時刻より定められた時間遡った過去の時点より後に生成されたスナップショットは全て該ファイルシステムに保存するスナップショット取得手段1611と、
過去の時点より以前のスナップショットについては、スナップショットの生成時刻の間隔が、グループ毎に定められた時間以上となるよう、ファイルシステム151のテーブルから段階的にスナップショットを削除するスナップショット削除手段1612と、
ファイルサーバが、スナップショットを、NFS(Network File System)、CIFS (Common Internet File System)といったリモートファイル管理プロトコルを通じ、クライアント端末からネットワーク経由で公開する連続スナップショットを共有するサーバであるときに、
スナップショットを生成時刻から現在時刻までの存続期間に応じて複数のグループに分け、ファイルシステムに格納するグループ化手段と、
ファイルシステムの各グループから一定個数のスナップショットを選んで公開することで、クライアント端末にアクセスさせるスナップショットの数を一定個数以内に抑える公開手段と、を有する。
The present invention (Claim 1) detects a change in the state of the file contents and attributes, the structure of the directory tree, etc., and automatically and additionally creates a snapshot in the same volume of the storage means 110. A file server that manages snapshots for
Snapshots are acquired from the file system 151, and the snapshots are grouped based on information on the generation time of the snapshots. All snapshots generated after a past time point that is a predetermined time later than the current time are the files. Snapshot acquisition means 1611 to be stored in the system;
For snapshots prior to the past time point, snapshot deletion means for deleting snapshots in a step-by-step manner from the table of the file system 151 so that the interval between generation times of snapshots is equal to or greater than the time determined for each group. 1612,
File server, a snapshot, NFS (Network File System), through a remote file management protocols such as CIFS (Common Internet File S ystem) , when a server that shares a continuous snapshots exposed via a network from a client terminal ,
Grouping means for dividing the snapshots into a plurality of groups according to the duration from the generation time to the current time, and storing them in the file system;
A disclosure unit that selects and publishes a predetermined number of snapshots from each group of the file system, thereby limiting the number of snapshots to be accessed by the client terminal within a predetermined number;

また、本発明(請求項2)は、請求項1のファイルサーバにおいて、
ファイルシステム151のテーブル上でスナップショットを削除した場合でも、スナップショットが使用するディスク上のデータ及びメタデータ領域を直ちには解放せず、予め定められたスケジュールに従って動作するか、もしくはCPUの使用率やディスク入出力量などのシステム負荷が一定水準より低い期間に動作するバックグラウンドプログラムによって、領域をスナップショット削除時より遅らせて解放する解放手段を更に有する。
The present invention (Claim 2) is the file server of Claim 1,
Even when a snapshot is deleted from the table of the file system 151, the data and metadata areas on the disk used by the snapshot are not released immediately, but operate according to a predetermined schedule, or the CPU usage rate And a release means for releasing the area later than when the snapshot is deleted by a background program that operates during a period when the system load such as the disk input / output amount is lower than a certain level.

図2は、本発明の原理を説明するための図である。   FIG. 2 is a diagram for explaining the principle of the present invention.

本発明(請求項3)は、ファイルの内容や属性、ディレクトリツリーの構成などの状態の変更を検知し、記憶手段の同一ボリューム内にスナップショットを自動的かつ追加的に作成するファイルシステムに対するスナップショットの管理を行うファイルサーバにおける連続スナップショット管理方法であって、
ファイルサーバのスナップショット取得手段が、
ファイルシステムからスナップショットを取得し(ステップ1)、該スナップショットの生成時刻の情報に基づきスナップショットをグループ分けし(ステップ2)、現在時刻より定められた時間遡った過去の時点より後に生成されたスナップショットは全て該ファイルシステムに保存し(ステップ3)、
ファイルサーバのスナップショット削除手段が、
過去の時点より以前のスナップショットについては、スナップショットの生成時刻の間隔が、グループごとに定められた時間以上となるよう、ファイルシステムのテーブルから段階的にスナップショットを削除し(ステップ4)、
ファイルサーバが、スナップショットを、NFS(Network File System)、CIFS (Common Internet File System)といったリモートファイル管理プロトコルを通じ、クライアント端末からネットワーク経由で公開する連続スナップショットを共有するサーバであるときは、
ファイルサーバのグループ化手段が、
スナップショットを生成時刻から現在時刻までの存続期間に応じて複数のグループに分け、ファイルシステムに格納し、
ファイルサーバの公開手段が、
ファイルシステムの各グループから一定個数のスナップショットを選んで公開することで、クライアント端末にアクセスさせるスナップショットの数を一定個数以内に抑える。
According to the present invention (Claim 3), a snap to a file system that automatically and additionally creates a snapshot in the same volume of the storage means by detecting a change in the state of the file contents and attributes, the structure of the directory tree, etc. A continuous snapshot management method in a file server for managing shots,
The file server snapshot acquisition means
Snapshots are acquired from the file system (step 1), snapshots are grouped based on the snapshot generation time information (step 2), and are generated after a past time point that is a predetermined time after the current time. Save all snapshots in the file system (step 3)
File server snapshot deletion means
For snapshots prior to the past time point, delete snapshots step by step from the file system table so that the interval between snapshot generation times is equal to or greater than the time determined for each group (step 4),
File server, a snapshot, NFS (Network File System), CIFS through (Common Internet File S ystem) such remote file management protocol, when a server that shares a continuous snapshots exposed via a network from a client terminal ,
File server grouping means
The snapshots are divided into multiple groups according to the duration from the generation time to the current time, stored in the file system,
File server disclosure means
By selecting and releasing a certain number of snapshots from each group of the file system, the number of snapshots accessed by the client terminal is kept within a certain number.

また、本発明(請求項)は、請求項の連続スナップショット管理方法において、
ファイルサーバの解放手段が、
ファイルシステムのテーブル上でスナップショットを削除した場合でも、スナップショットが使用するディスク上のデータ及びメタデータ領域を直ちには解放せず、予め定められたスケジュールに従って動作するか、もしくはCPUの使用率やディスク入出力量などのシステム負荷が一定水準より低い期間に動作するバックグラウンドプログラムによって、領域をスナップショット削除時より遅らせて解放する。
Further, the present invention (Claim 4 ) is the continuous snapshot management method according to Claim 3 ,
File server release means
Even when a snapshot is deleted from the file system table, the data and metadata areas on the disk used by the snapshot are not released immediately, but operate according to a predetermined schedule, or the CPU usage rate The area is released later than when the snapshot is deleted by a background program that operates during a period when the system load such as the disk I / O amount is lower than a certain level.

本発明(請求項5)は、請求項1または2に記載のファイルサーバを構成する各手段としてコンピュータを機能させるための連続スナップショット管理プログラムである。 The present invention (Claim 5) is a continuous snapshot management program for causing a computer to function as each means constituting the file server according to Claim 1 or 2 .

上記のように本発明によれば、以下のような効果を奏する。   As described above, the present invention has the following effects.

請求項1,3,5の発明(第1の発明)によれば,連続的に多数のスナップショットを自動作成するファイルサーバにおいて、直近の誤操作によって喪失したデータは保全し、また一定時間経った過去のスナップショットについては時間経過に応じてユーザが必要なスナップショットを代表として残すような、データ保護と履歴管理を両立する連続スナップショットの管理を機械的に行えるようになる。そして、連続スナップショットを蓄積しているボリュームが履歴(スナップショット)の増加によってディスクフルにならないよう長期間運用するファイルサーバが実現できる。また、連続スナップショットをリモートファイル管理プロトコルを通じ、クライアントマシンからネットワーク経由で公開する場合で、スナップショットからファイル履歴を抽出するようなスナップショットを横断的にアクセスする処理をクライアントマシンが行う場合に、参照スナップショットの数が一定個数に抑えられることで、クライアントマシンとファイルサーバ双方の負荷を抑え、応答性と安定性を改善できる。また、ユーザがクライアントPC上のGUIを通じてスナップショットを閲覧する際に、所望の時刻・バージョンのスナップショットを探して選択する際の使い勝手が改善される。 Claim 1, according to the 3,5 invention (first invention), in a file server to automatically create a continuous number of snapshots, the preserving data loss by the last erroneous operation, also has passed a predetermined time With regard to past snapshots, continuous snapshot management that achieves both data protection and history management can be performed mechanically, such that a user needs a snapshot that remains necessary as time passes. In addition, a file server that can be operated for a long period of time can be realized so that a volume in which continuous snapshots are accumulated does not become full due to an increase in history (snapshot). In addition, when a continuous snapshot is published via a remote file management protocol from a client machine via a network, and when a client machine performs a process of accessing a snapshot that extracts a file history from a snapshot, By limiting the number of reference snapshots to a certain number, it is possible to reduce the load on both the client machine and the file server, and improve responsiveness and stability. In addition, when the user browses the snapshot through the GUI on the client PC, usability when searching for and selecting a snapshot of a desired time and version is improved.

請求項2,4,5の発明(第2の発明)によれば、第1の発明によるファイルサーバにおいてユーザからのファイルアクセスのない業務時間帯外や、業務時間帯内であってもユーザのアクセスが少ない空白時間にスナップショット削除が実施されるようになり、ユーザがファイルサーバ上のファイルにアクセスする際の応答性をなるべく低下させずに連続的に多数生成されるスナップショットを削除できるようになる。 According to the second, fourth, and fifth aspects of the invention (second invention), the file server according to the first aspect of the invention can be used even when the file server does not have a file access from the user or outside the business hours. Snapshot deletion will be performed in the low access time, so that many continuously generated snapshots can be deleted without reducing the responsiveness when the user accesses the file on the file server as much as possible. become.

本発明の原理構成図である。It is a principle block diagram of this invention. 本発明の原理を説明するための図である。It is a figure for demonstrating the principle of this invention. 本発明の第1の実施の形態における連続スナップショットファイルサーバの構成図である。It is a block diagram of the continuous snapshot file server in the 1st Embodiment of this invention. 本発明の第1の実施の形態におけるスナップショット管理デーモンの動作のフローチャートである。It is a flowchart of operation | movement of the snapshot management daemon in the 1st Embodiment of this invention. 本発明の第1の実施の形態におけるスナップショットの段階的な削除を説明するための図である。It is a figure for demonstrating the stepwise deletion of the snapshot in the 1st Embodiment of this invention. 本発明の第2の実施の形態における連続スナップショットファイルサーバの構成図である。It is a block diagram of the continuous snapshot file server in the 2nd Embodiment of this invention. 本発明の第2の実施の形態における解放デーモンの動作のフローチャートである。It is a flowchart of operation | movement of the release daemon in the 2nd Embodiment of this invention. スナップショットの共有方法を示す図である。It is a figure which shows the sharing method of a snapshot. 本発明の第3の実施の形態におけるスナップショットの選別処理のフローチャートである。It is a flowchart of the selection process of the snapshot in the 3rd Embodiment of this invention. 本発明の第4の実施の形態におけるバックアップシステムの構成図である。It is a block diagram of the backup system in the 4th Embodiment of this invention. 本発明の第4の実施の形態における同期デーモンの動作のフローチャートである。It is a flowchart of operation | movement of the synchronous daemon in the 4th Embodiment of this invention. 第1・第2の実施の形態による連続スナップショットファイルサーバにおけるファイルの存続期間とスナップショット番号の関係を示す図である。It is a figure which shows the relationship between the lifetime of a file in the continuous snapshot file server by 1st, 2nd embodiment, and a snapshot number. 本発明の第5の実施の形態における検索インデックスの構成例である。It is a structural example of the search index in the 5th Embodiment of this invention. 本発明の第6〜第8の実施の形態における検索インデックス生成装置の構成図である。It is a block diagram of the search index production | generation apparatus in the 6th-8th embodiment of this invention. 本発明の第6の実施の形態における検索インデックス生成処理のフローチャートである。It is a flowchart of the search index production | generation process in the 6th Embodiment of this invention. 本発明の第7の実施の形態における検索インデックスの更新処理のフローチャートである。It is a flowchart of the update process of the search index in the 7th Embodiment of this invention. 本発明の第8の実施の形態における検索インデックスの最適化処理のフローチャートである。It is a flowchart of the optimization process of the search index in the 8th Embodiment of this invention. 連続スナップショットファイルシステムの概念を示す図である。It is a figure which shows the concept of a continuous snapshot file system.

以下、図面と共に本発明の実施の形態を説明する。   Hereinafter, embodiments of the present invention will be described with reference to the drawings.

[第1の実施の形態]
図3は、本発明の第1の実施の形態における連続スナップショットファイルサーバの構成例を示す。
[First Embodiment]
FIG. 3 shows a configuration example of the continuous snapshot file server in the first embodiment of the present invention.

同図に示す連続スナップショットファイルサーバ100は、記憶装置(ディスク)110とネットワークインタフェース120を搭載し、その基本ソフトOS(Operating System)150は、連続スナップショットファイルシステム151と、ネットワークインタフェース120のデバイスドライバやネットワークプロトコルスタックなどからなるネットワーク通信部152を有するものとする。また、クライアントPCに対するプログラムとしてファイル共有サービス165とスナップショット管理デーモン161を有する。ここで記憶装置110は、ハードウェア故障に対するデータ喪失を避けるよう一般性を失うことなくミラーリングやRAIDなどの冗長化技術を適用して可用性・信頼性を高めることができる。   The continuous snapshot file server 100 shown in FIG. 1 includes a storage device (disk) 110 and a network interface 120, and its basic software OS (Operating System) 150 includes a continuous snapshot file system 151 and devices of the network interface 120. Assume that the network communication unit 152 includes a driver, a network protocol stack, and the like. In addition, a file sharing service 165 and a snapshot management daemon 161 are provided as programs for the client PC. Here, the storage device 110 can improve availability and reliability by applying a redundancy technique such as mirroring or RAID without losing generality so as to avoid data loss due to hardware failure.

連続スナップショットファイルシステム151は、記憶装置110上のボリュームにブロックI/O(a1)を行い、通常のファイルシステムと同様ユーザ空間のアプリケーションにファイルやディレクトリなどシステム資源を提供し、それらを通じ記憶装置110へのデータの保存、及び、記憶装置110のデータの参照もしくは管理機能を提供する。なお、ここで「ブロックI/O」とは、本発明のファイルシステムはブロックデバイスを対象としているため、ブロック単位で入出力することを意味する。   The continuous snapshot file system 151 performs block I / O (a1) on the volume on the storage device 110, and provides system resources such as files and directories to applications in the user space in the same manner as a normal file system. The function of storing data in 110 and referring to or managing data in the storage device 110 is provided. Here, “block I / O” means that the file system of the present invention targets block devices, and therefore inputs and outputs in block units.

ファイル共有サービス165は、連続スナップショットファイルシステム151のこれら資源をネットワーク通信部152とネットワークインタフェース120を通じ、クライアントPCからアクセス可能とする(a2〜a5)。   The file sharing service 165 makes these resources of the continuous snapshot file system 151 accessible from the client PC through the network communication unit 152 and the network interface 120 (a2 to a5).

スナップショット管理デーモン161は、定期的に連続スナップショットファイルシステム151の状態を調べ(a6)、時間経過に応じてスナップショットを削除する(a7)。   The snapshot management daemon 161 periodically checks the state of the continuous snapshot file system 151 (a6), and deletes the snapshot as time elapses (a7).

図4は、本発明の第1の実施の形態におけるスナップショット管理デーモンの動作のフローチャートを示す。   FIG. 4 shows a flowchart of the operation of the snapshot management daemon in the first embodiment of the present invention.

ステップ101) スナップショット管理デーモン161はまず、設定ファイル(外部からアクセスできないようなシステムの記憶域を指す)などから、「最近」のスナップショットの保持期間Trecent、「時間毎」のスナップショットの保持期間Thourly、「日ごと」のスナップショットの保持期間Tdaily、「週毎」のスナップショットの保持期間Tweeklyを読み込み、メモリ(図示せず)上に設定する。 Step 101) First, the snapshot management daemon 161 is configured to store the “recent” snapshot retention period T recent and “every hour” snapshot from the configuration file (pointing to the storage area of the system that cannot be accessed from the outside). The retention period T hourly , the “ daily ” snapshot retention period T daily , and the “weekly” snapshot retention period T weekly are read and set on a memory (not shown).

ステップ102) 連続スナップショットファイルシステム151から存在するスナップショットのスナップショット番号とタイムスタンプを取得する。   Step 102) The snapshot number and time stamp of the existing snapshot are acquired from the continuous snapshot file system 151.

ステップ103) また、基本ソフト150から現在時刻を取得し基準時刻Tに設定する。   Step 103) Also, the current time is acquired from the basic software 150 and set to the reference time T.

ステップ104) そして、取得したスナップショットから、当該スナップショットの生成時刻tがt≧T - Trecentであるスナップショットを除外する。 Step 104) Then, from the acquired snapshot, a snapshot whose generation time t of the snapshot is t ≧ T−T recent is excluded.

ステップ105) そして次に、生成時刻tがt≧T − Thourlyであるスナップショットを選択し、古いものもしくは新しいものから順にスナップショットの生成時刻の間隔を調べ、間隔が1時間に満たない中間スナップショットを削除し、選択された期間内の残りのスナップショットを処理対象から除外する。 Step 105) Next, a snapshot having a generation time t of t ≧ T−T hourly is selected, and the generation time intervals of the snapshots are examined in order from the oldest or newest one, and the interval is less than 1 hour. Delete the snapshot and exclude the remaining snapshots within the selected period from being processed.

ステップ106) 以降同様に、生成時刻tがt≧T - Tdailyであるスナップショットを選択して間隔が一日以上になるよう中間スナップショットを削除して残りのスナップショットを処理対象から除外する。 Step 106) Similarly, select a snapshot whose generation time t is t ≧ T−T daily , delete the intermediate snapshot so that the interval is one day or longer, and exclude the remaining snapshots from the processing target. .

ステップ107) 生成時刻tがt≧T - Tweeklyであるスナップショットを選択して間隔が一週間以上になるよう中間スナップショットを削除して残りのスナップショットを処理対象から除外する。 Step 107) Select a snapshot whose generation time t is t ≧ T−T weekly , delete the intermediate snapshot so that the interval is one week or longer, and exclude the remaining snapshots from the processing target.

ステップ108) 残ったスナップショットの間隔が一ヶ月以上となるよう中間スナップショットを削除する。   Step 108) Delete the intermediate snapshot so that the interval between the remaining snapshots is one month or longer.

ステップ109) そして停止要求の有無を調べ、あれば終了し、なければステップ110に移行する。   Step 109) Then, it is checked whether or not there is a stop request.

ステップ110) 一定時間スリープした後、ステップ102に移行し、スナップショット一覧の取得以降の処理を繰り返す。   Step 110) After sleeping for a predetermined time, the process proceeds to Step 102, and the processing after acquisition of the snapshot list is repeated.

このようにして間引かれたスナップショットは、図5のように時間経過に応じてスナップショット数を抑えたものとなる。   The snapshots thinned out in this manner are those in which the number of snapshots is suppressed as time passes as shown in FIG.

なお、本実施の形態では、スナップショット作成は連続スナップショットファイルシステム151が自動的に作成することを前提に、スナップショット管理デーモン161はスナップショット削除のみを行うこととしたが、スナップショット作成の指示をスナップショット管理デーモン161に行わせるようにすることで、スナップショット作成をサポートしているが、自動的には作成しないファイルシステムを対象として、連続スナップショットファイルサーバを構成することもできる。   In this embodiment, the snapshot management daemon 161 performs only snapshot deletion on the assumption that the snapshot creation is automatically created by the continuous snapshot file system 151. By causing the snapshot management daemon 161 to issue an instruction, snapshot creation is supported, but a continuous snapshot file server can be configured for a file system that is not automatically created.

また、連続スナップショットファイルシステム151がスナップショット情報を一元的に管理する機能を有さない場合には、多数のスナップショットの横断的なアクセスによりファイルサーバの性能が低下する。その場合、スナップショットのタイムスタンプ情報を含む一覧の情報を、スナップショット管理デーモン161内の記憶手段に保持させ、新たに作成されたスナップショットの情報のみを連続スナップショットファイルシステム151から取得させることで、性能低下を抑えるように実施することができる。   In addition, when the continuous snapshot file system 151 does not have a function for managing snapshot information in an integrated manner, the performance of the file server is deteriorated due to cross access of a large number of snapshots. In that case, the list information including the time stamp information of the snapshot is held in the storage unit in the snapshot management daemon 161, and only the information of the newly created snapshot is acquired from the continuous snapshot file system 151. Therefore, it can be implemented so as to suppress the performance degradation.

[第2の実施の形態]
本実施の形態では、ユーザからアクセスのない業務時間帯外や、ユーザからのアクセスが少ない時間にスナップショットを削除し、記憶装置110を解放する処理について説明する。
[Second Embodiment]
In the present embodiment, a process for deleting a snapshot and releasing the storage device 110 outside a business time period when there is no access from the user or when there is little access from the user will be described.

図6は、本発明の第2の実施の形態における連続スナップショットファイルサーバの構成を示す。   FIG. 6 shows the configuration of the continuous snapshot file server in the second embodiment of the present invention.

同図において、図3と同一構成部分には同一符号を付し、その説明を省略する。図6の構成は、図3の構成に解放デーモン162を付加した構成である。   In the figure, the same components as those in FIG. The configuration in FIG. 6 is a configuration in which a release daemon 162 is added to the configuration in FIG.

本実施の形態の連続スナップショットファイルサーバ100は、第1の実施の形態における連続スナップショットファイルサーバに基づいて構成されるが、スナップショット管理デーモン161は、スナップショットを削除する際、実際にスナップショットが利用している記憶装置110上のデータ領域は解放せず、指定されたスナップショットに削除要求のマークを付けるだけである(a6´)。   The continuous snapshot file server 100 according to the present embodiment is configured based on the continuous snapshot file server according to the first embodiment, but the snapshot management daemon 161 does not actually perform the snapshot when deleting the snapshot. The data area on the storage device 110 used by the shot is not released, and only the deletion request is marked on the designated snapshot (a6 ′).

本実施の形態において、スナップショットが利用している記憶装置110のデータ領域を解放するのは、解放デーモン162であり、これはユーザ空間のバックグラウンドプログラムとして実装されるか、あるいは基本ソフト150のプログラムとしてファイルシステムの一部に含めるかもしくは含めない形で実現することができる。   In this embodiment, it is the release daemon 162 that releases the data area of the storage device 110 used by the snapshot, which is implemented as a background program in the user space or the basic software 150. It can be implemented as a program that is included or not included as part of the file system.

図7は、本発明の第2の実施の形態における解放デーモンの処理のフローチャートである。   FIG. 7 is a flowchart of processing of the release daemon according to the second embodiment of this invention.

ステップ201) 解放デーモン162は、まず、サーバ100内の設定ファイル(図示せず)などから、CPU使用率の閾値Rcpu、I/O負荷の閾値RI/O、一回の解放処理の割当時間Tsliceを読み込み、メモリ(図示せず)に設定する。 Step 201) First, the release daemon 162 allocates a CPU usage rate threshold value R cpu , an I / O load threshold value R I / O , and one release processing allocation from a setting file (not shown) in the server 100. Read time T slice and set to memory (not shown).

ステップ202) 次に、CPU使用率Lcpuをシステムから取得する。 Step 202) Next, the CPU usage rate L cpu is acquired from the system.

ステップ203) CPU使用率LcpuとCPU使用率の閾値Rcpuを比較し、Lcpu<Rcpuでなければステップ211に移行し、Lcpu<Rcpuであればステップ204に移行する。 Step 203) The CPU usage rate L cpu and the CPU usage rate threshold value R cpu are compared. If L cpu <R cpu, the procedure proceeds to step 211, and if L cpu <R cpu , the procedure proceeds to step 204.

ステップ204) Lcpu <Rcpuなら、I/O負荷LI/Oを計測するか、または、システムから取得する。 Step 204) If L cpu <R cpu , measure or obtain I / O load L I / O from the system.

ステップ205) LI/O < RI/Oであればステップ206に移行し、LI/O < RI/Oでなければステップ211に移行する。 Step 205) If L I / O <R I / O , the process proceeds to step 206, and if L I / O <R I / O, the process proceeds to step 211.

ステップ206) LI/O < RI/Oなら、連続スナップショットファイルシステム151から削除要求がマークされたスナップショットの一覧を取得する。 Step 206) If L I / O <R I / O , a list of snapshots marked for deletion from the continuous snapshot file system 151 is acquired.

ステップ207) 次に、基本ソフト150から解放処理の開始時刻を取得する。   Step 207) Next, the release processing start time is acquired from the basic software 150.

ステップ208) そして、取得されたスナップショットの中から、スナップショット管理デーモン161によって削除要求がマークされたスナップショットを一つ解放する。   Step 208) Then, from the acquired snapshots, one snapshot whose deletion request is marked by the snapshot management daemon 161 is released.

ステップ209) 開始時刻からの経過時刻tがt≦ Tsliceか確認し、経過時刻がまだ過ぎていなければステップ207に移行して、ステップ207,208の処理を繰り返す。経過時間が過ぎている場合はステップ210に移行する。 Step 209) It is confirmed whether the elapsed time t from the start time is t ≦ T slice . If the elapsed time has not yet passed, the process proceeds to Step 207 and the processing of Steps 207 and 208 is repeated. If the elapsed time has passed, the process proceeds to step 210.

ステップ210) 経過時間が過ぎた場合には停止要求の有無を調べ、あれば終了し、なければステップ211に移行する。   Step 210) When the elapsed time has passed, the presence or absence of a stop request is checked.

ステップ211) 一定時間スリープした後、ステップ202以降の処理を繰り返す。   Step 211) After sleeping for a predetermined time, the processing from step 202 onward is repeated.

上記の説明では、スナップショットの使用するディスク領域の解放をスナップショット単位としているが、一般性を失うことなくステップ208で削除されるスナップショットは複数個としたり、あるいはスナップショットを構成するデータの所定のサイズ単位とすることができる。   In the above explanation, the disk area used by the snapshot is released in units of snapshots. However, multiple snapshots can be deleted in step 208 without loss of generality, or the data constituting the snapshot can be deleted. It can be a predetermined size unit.

また、ディスク領域の解放方法として、ディスク領域を複数の区間(セグメント)に分割し、セグメント毎にそこに含まれるディスクブロックが、削除要求対象でないスナップショットもしくはファイルシステムの現在の状態により使用されているかどうかを判定し、使用中の全てのブロックを空き領域にコピーし、セグメントを解放する方法がある。このような解放方法をとる場合でも、ステップ208の処理単位をディスク領域の単一もしくは複数のセグメント単位とすることで、一般性を損なうことなく、ディスク領域の解放の遅延処理が実現できる。   In addition, as a method of releasing disk space, the disk space is divided into multiple sections (segments), and the disk blocks included in each segment are used depending on the current state of the snapshot or file system not subject to deletion request. There is a method of determining whether or not, copying all blocks in use to an empty area, and releasing a segment. Even when such a release method is adopted, the processing unit of step 208 can be a single or a plurality of segment units of the disk area, so that the delay process of releasing the disk area can be realized without impairing generality.

[第3の実施の形態]
本実施の形態では、説明のために、図8に第1もしくは第2の実施の形態による連続スナップショットファイルサーバ100が、ネットワークで接続されたクライアントPCからスナップショットを閲覧、参照可能となるように、それらを共有フォルダとして公開する方法の例を示す。
[Third Embodiment]
In the present embodiment, for the sake of explanation, the continuous snapshot file server 100 according to the first or second embodiment shown in FIG. 8 can browse and reference a snapshot from a client PC connected via a network. Shows an example of how to publish them as shared folders.

図8は、本発明の第3の実施の形態におけるスナップショットの共有方法の例を説明するための図である。同図の例では、ファイルシステムの現在のファイルとその名前空間を共有フォルダ「share」10に割り当てて公開する一方、一連のスナップショットにスナップショットの生成時刻に基づく名前を与え、共有フォルダ「share」10 に対応するスナップショットフォルダ「snapshots」20の中に公開している。スナップショットフォルダ20は、通常の共有フォルダと同様にユーザから直接アクセスできるように公開する場合もあれば、現在のファイルシステム上の特定のサブディレクトリ(例えば".snapshots")に割り当てて公開する場合もある。もしくは、専らクライアントPCのスナップショット機能が参照するためのユーザからは直接見えないディレクトリとしてクライアントPCに公開する場合もある。また、スナップショットを割り当てるサブディレクトリ名は、生成時刻ではなくスナップショットの識別番号に基づく名前を与える場合もある。   FIG. 8 is a diagram for explaining an example of a snapshot sharing method according to the third embodiment of the present invention. In the example of the figure, the current file of the file system and its name space are allocated to the shared folder “share” 10 and published, while a series of snapshots are given names based on the generation time of the snapshot, and the shared folder “share” ”In the snapshot folder“ snapshots ”20 corresponding to“ 10 ”. The snapshot folder 20 may be published so that it can be directly accessed by the user in the same way as a normal shared folder, or may be published by being assigned to a specific subdirectory (for example, “.snapshots”) on the current file system. is there. Alternatively, the directory may be disclosed to the client PC as a directory that is not directly visible to the user for reference by the snapshot function of the client PC. In addition, the name of the subdirectory to which the snapshot is allocated may be given based on the snapshot identification number instead of the generation time.

こういったスナップショットフォルダ20の名前空間の生成と個々のスナップショットへの割り当ては、連続スナップショットファイルサーバ100のファイル共有サービス部165を通じて行われる。   The generation of the namespace of the snapshot folder 20 and the allocation to the individual snapshots are performed through the file sharing service unit 165 of the continuous snapshot file server 100.

図9は、本発明の第3の実施の形態におけるスナップショットの選別処理のフローチャートであり、スナップショットフォルダをクライアントPCに公開するスナップショットの選別処理の例を示す。   FIG. 9 is a flowchart of snapshot selection processing according to the third embodiment of the present invention, and shows an example of snapshot selection processing for publishing a snapshot folder to a client PC.

同図の例では、スナップショットを3つのグループ(新しいものから順に「ホット」グループ、「コールド」グループ、「残り」グループ)に分け選別している。   In the example shown in the figure, the snapshots are divided into three groups (in order from the newest one, the “hot” group, the “cold” group, and the “remaining” group).

ステップ301) まず、ファイル共有サービス部165は、スナップショットフォルダ20内のサブディレクトリ名の取得要求をクライアントPCから受けると、前記グループ毎のスナップショットの表示個数Nhot, Ncold, Nrestを取得する。 Step 301) First, when the file sharing service unit 165 receives an acquisition request for the subdirectory name in the snapshot folder 20 from the client PC, the file sharing service unit 165 acquires the number of displayed snapshots N hot , N cold , and N rest for each group. To do.

ステップ302) 現在を基準としてスナップショットをグループ分けするための遡及時間Thot, Tcoldを取得する。 Step 302) Acquire retroactive times T hot and T cold for grouping snapshots based on the current time.

ステップ303) 選別したスナップショット格納用のメモリ(図示せず)テーブルHを初期化する。   Step 303) The selected snapshot storage memory (not shown) table H is initialized.

ステップ304) 連続スナップショットファイルシステム151からスナップショットの一覧を取得する。   Step 304) A list of snapshots is acquired from the continuous snapshot file system 151.

ステップ305) 現在時刻を取得して基準時刻Tとして設定する。   Step 305) The current time is acquired and set as the reference time T.

ステップ306) しかる後に、取得したスナップショットの中から、生成時刻tがt ≧ T−Thotとなるものを「ホット」グループに属するものとして選び、その内、新しいものから順に最大でNhot個を選択してテーブルHに登録する。 Step 306) After that, from the acquired snapshots, those having a generation time t of t ≧ T−T hot are selected as belonging to the “hot” group, and among them, a maximum of N hot items in order from the new one And register it in Table H.

ステップ307) 同様に、生成時刻tがT−Thot > t ≧ T−Tcoldとなるスナップショットを「コールド」グループに属するものとして選び、その内、新しいものから順に最大でNcold個を選択してテーブルHに追加する。 Step 307) Similarly, select snapshots whose generation time t is T−T hot > t ≧ T−T cold as belonging to the “cold” group, and select a maximum of N cold in order from the newest one And add it to table H.

ステップ308) また、生成時刻tがt < T−Tcoldとなるスナップショットを「残り」グループに属するものとして選び、新しいものから順に最大でNrest個を選択してテーブルHに追加する。 Step 308) Further, the snapshots whose generation time t is t <T−T cold are selected as belonging to the “remaining” group, and a maximum of N rest are selected in order from the newest one and added to the table H.

ステップ309) 最後に、テーブルHに登録されたスナップショットを出力する。   Step 309) Finally, the snapshot registered in the table H is output.

例えば、テーブルHから図8に示すスナップショット毎のサブディレクトリに対応させて出力することにより、クライアントPCに公開する。   For example, by outputting from the table H corresponding to the subdirectory for each snapshot shown in FIG.

上記のスナップショット選別処理は、クライアントPCからスナップショットフォルダの閲覧要求があるたびに実施するのでなく、応答速度を改善するため短期間ファイル共有サービス165内にキャッシュして用いることもできる。またスナップショットグループ分け方(期間)は、第1の実施の形態による分け方(期間)と同一にする必要はない。第1の実施の形態はスナップショットを削除するので、ステップ304で取得するスナップショットは、その結果が反映されたものとなる。また、第2の実施の形態を適用する場合には、削除中のスナップショットはステップ304で取得するスナップショットからは除外する。   The above-described snapshot selection processing is not performed every time a snapshot folder browsing request is made from the client PC, but can be cached in the file sharing service 165 for a short period of time in order to improve the response speed. The snapshot grouping method (period) need not be the same as the dividing method (period) according to the first embodiment. Since the first embodiment deletes the snapshot, the snapshot acquired in step 304 reflects the result. Further, when applying the second embodiment, the snapshot being deleted is excluded from the snapshot acquired in step 304.

[第4の実施の形態]
図10は、本発明の第4の実施の形態におけるバックアップシステムの構成を示す。
[Fourth Embodiment]
FIG. 10 shows the configuration of the backup system in the fourth embodiment of the present invention.

同図に示すバックアップシステムは、第1もしくは第2の実施の形態による連続スナップショットファイルサーバ100とクライアントPC200を、ネットワークを介し接続して構成する。   The backup system shown in the figure is configured by connecting a continuous snapshot file server 100 and a client PC 200 according to the first or second embodiment via a network.

クライアントPC(PC)200は、記憶装置210とネットワークインタフェース220を搭載し、その基本ソフト(Operating System)250は、ローカルファイルシステム251、ネットワークインタフェース220のデバイスドライバやネットワークプロトコルスタックなどからなるネットワーク通信部252、ファイル共有クライアント部255、それにローカルファイルシステム上の変更操作をユーザランドのアプリケーションに通知する通知機能部254を有する。そしてユーザランドのプログラムとして同期デーモン261を有する。   A client PC (PC) 200 includes a storage device 210 and a network interface 220, and its basic software (Operating System) 250 includes a local file system 251, a device driver for the network interface 220, a network protocol stack, and the like. 252, a file sharing client unit 255, and a notification function unit 254 that notifies the userland application of a change operation on the local file system. A synchronization daemon 261 is provided as a userland program.

ファイルシステム251は通常のファイルシステムであり、記憶装置210上のボリュームにブロックI/O(b1)を行い、ファイルやディレクトリなどシステム資源を提供し、データの保存・参照もしくは管理機能を提供する。一方、ファイル共有クライアント部255は、ネットワーク通信部252とネットワークインタフェース220を通じ、連続スナップショットファイルサーバ100に接続し、当該サーバ100の共有フォルダの閲覧、参照、変更をアクセス権に応じてアクセスする機能を提供する(b2〜b4)。   The file system 251 is a normal file system, performs block I / O (b1) on the volume on the storage device 210, provides system resources such as files and directories, and provides data storage / reference or management functions. On the other hand, the file sharing client unit 255 is connected to the continuous snapshot file server 100 through the network communication unit 252 and the network interface 220, and accesses the browsing, reference, and change of the shared folder of the server 100 according to the access right. (B2 to b4).

同期デーモン261は、通知機能部254を通じてローカルファイルシステム251の予め登録されたディレクトリの変更を調べ(b5,b6)、ファイル共有クライアント部250を通じて、変更内容を連続スナップショットファイルサーバ100の共有フォルダ内の予め登録されたディレクトリに反映させる。   The synchronization daemon 261 checks the change of the directory registered in advance in the local file system 251 through the notification function unit 254 (b5, b6), and the change content is stored in the shared folder of the continuous snapshot file server 100 through the file sharing client unit 250. To be reflected in the previously registered directory.

図11は、本発明の第4の実施の形態における同期デーモンの動作のフローチャートである。   FIG. 11 is a flowchart of the operation of the synchronization daemon according to the fourth embodiment of this invention.

ステップ401) 同期デーモン261は、まず、設定ファイルなどから、ローカルファイルシステム251上の同期元ディレクトリDsrcと連続スナップショットファイルサーバ100の共有フォルダ上の同期先ディレクトリDdestの対を読み込み設定する。 Step 401) The synchronization daemon 261 first reads and sets a pair of the synchronization source directory D src on the local file system 251 and the synchronization destination directory D dest on the shared folder of the continuous snapshot file server 100 from a setting file or the like.

ステップ402) また、連続スナップショットファイルシステム151から存在するスナップショットのスナップショットDsrc内のファイル操作及びディレクトリ操作を監視するよう通知機能部254に設定する。 Step 402) Further, the notification function unit 254 is set to monitor file operations and directory operations in the snapshot D src of the snapshot existing from the continuous snapshot file system 151.

ステップ403) 次に、同期先ディレクトリDdest で指定された共有フォルダを有する連続スナップショットファイルサーバ100との通信が可能かどうか確認し、そうでなければ通信可能になるまで一定時間待つ。 Step 403) Next, it is confirmed whether or not communication with the continuous snapshot file server 100 having the shared folder specified in the synchronization destination directory D dest is possible, and otherwise waits for a certain time until communication is possible.

ステップ404) 確認処理がタイムアウトした場合には、ステップ405に移行し、タイムアウトしていない場合は、ステップ410に移行する。   Step 404) If the confirmation process has timed out, the process proceeds to step 405, and if not, the process proceeds to step 410.

ステップ405) 次に、停止要求の有無を調べ、停止要求がある場合は、ステップ406に移行し、ない場合はステップステップ403に移行する。   Step 405) Next, it is checked whether or not there is a stop request. If there is a stop request, the process proceeds to Step 406, and if not, the process proceeds to Step 403.

ステップ406) 停止要求がある場合は、同期元ディレクトリDsrc監視を解除するよう通知機能部254に設定して終了する。 Step 406) If there is a stop request, the notification function unit 254 is set to cancel the monitoring of the synchronization source directory D src and the process ends.

ステップ410) ファイルサーバ100との通信可能な場合には、まず同期元ディレクトリDsrcと同期先ディレクトリDdestの状態を一致させるため、DsrcとDdestのトップから再帰的に同期処理を行う。ディレクトリの場合には、ディレクトリの構成を調べ、構成が一致するようDdestに対してディレクトリの作成または削除を行い、ファイルの場合には内容が一致しているか調べ、一致していなければ、Ddest上の対象ディレクトリにファイルをコピーする。 Step 410) If communication with the file server 100 is possible, first, in order to make the states of the synchronization source directory D src and the synchronization destination directory D dest coincide, synchronization processing is recursively performed from the top of D src and D dest . If it is a directory, check the directory structure, create or delete the directory for D dest so that the structure matches, and if it is a file, check whether the contents match. Copy the file to the target directory on dest .

ステップ411) 同期化処理が完了した後、同期デーモン261は、通知機能部254からファイル操作・ディレクトリ操作のイベントe=<d,f,o>を受理し、なければイベント到着まで一定時間待つ。ここでd、f、oはそれぞれ、Dsrcのトップディレクトリからの対象ファイル、ディレクトリの相対パス、操作の種別、操作のオプションパラメータである。操作の種別とは、ファイルやディレクトリの作成・削除や移動・リネーム、ファイルの内容の変更、ファイル・ディレクトリのアクセス権、タイムスタンプ、所有者情報、グループ情報などの各種属性の変更などである。またオプションパラメータは、各操作を実施するのに必要な付帯的な情報である。 Step 411) After the synchronization processing is completed, the synchronization daemon 261 receives the event e = <d, f, o> of the file operation / directory operation from the notification function unit 254, and if not, waits for a certain time until the event arrives. Here, d, f, and o are a target file from the top directory of D src , a relative path of the directory, an operation type, and an operation optional parameter, respectively. The types of operations include creation / deletion / movement / renaming of files and directories, change of file contents, change of various attributes such as file / directory access rights, time stamp, owner information, and group information. The option parameter is incidental information necessary for performing each operation.

ステップ412) タイムアウトした場合はステップ415に移行し、タイムアウト以前であればステップ413に移行する。   Step 412) If timed out, the process proceeds to step 415, and if before time-out, the process proceeds to step 413.

ステップ413) ステップ411でイベントを受理した場合には、共有フォルダ内のディレクトリDdest /d(dはDsrc内の対象ファイル・ディレクトリの相対パス)で変更操作f(o)を実行する。 Step 413) When the event is accepted in Step 411, the change operation f (o) is executed with the directory D dest / d in the shared folder (d is the relative path of the target file / directory in D src ).

ステップ414) ステップ413の変更操作が失敗した場合には、ステップ405に移行し、成功した場合はステップ415に移行する。   Step 414) If the change operation in step 413 fails, the process proceeds to step 405, and if successful, the process proceeds to step 415.

ステップ415) 変更操作が成功した場合、もしくは前述のイベント受理がタイムアウトした場合には、停止要求の有無を確かめ、あればステップ406に移行し、それ以降の処理を実施し、なければステップ411に移行する。   Step 415) If the change operation is successful, or if the above-described event acceptance times out, the presence or absence of a stop request is confirmed. If there is, the process proceeds to Step 406, and the subsequent processing is performed. If not, the process proceeds to Step 411. Transition.

以上の説明では、変更を監視して再現する操作はファイルとディレクトリのみに限定しているが、シンボリックリンクその他の特殊ファイルに対しても一般性を損なうことなく拡張できる。また、ステップ410〜415の処理を、ワーカスレッドを生成して実行させることで、プログラムが長時間無応答にならないように手順化することも可能である。また、本実施の形態の説明では、同期元と同期先のディレクトリが一対の場合を説明しているが、結び付けられたディレクトリの対が複数の場合についても一般性を損なうことなく拡張できる。   In the above description, operations for monitoring and reproducing changes are limited to files and directories, but can be extended to symbolic links and other special files without loss of generality. It is also possible to create a procedure so that the program does not become unresponsive for a long time by generating a worker thread and executing the processing of steps 410 to 415. Further, in the description of the present embodiment, a case is described in which a pair of synchronization source and synchronization destination directories is described, but the case where there are a plurality of linked directory pairs can be expanded without impairing generality.

[第5の実施の形態]
図12は、第1もしくは第2の実施の形態による連続スナップショットファイルサーバにおける、ファイルの存続期間とスナップショット番号の関係の一例を示す。また、図13は、本発明の第5の実施の形態における検索インデックスの例を示す。図13の検索インデックスの例は、図12の状態に対応する本実施の形態による検索インデックスの構成例である。
[Fifth Embodiment]
FIG. 12 shows an example of the relationship between the file lifetime and the snapshot number in the continuous snapshot file server according to the first or second embodiment. FIG. 13 shows an example of a search index in the fifth embodiment of the present invention. The example of the search index of FIG. 13 is a configuration example of the search index according to the present embodiment corresponding to the state of FIG.

図12の例では、「ファイルA」がスナップショット番号2500の時点で作成され、スナップショット番号2520の時点でその内容が変更され、スナップショット番号2540で削除されたものとしている。   In the example of FIG. 12, it is assumed that “file A” was created at the time of snapshot number 2500, the contents were changed at the time of snapshot number 2520, and deleted at snapshot number 2540.

また「ファイルB」がスナップショット番号2510の時点で作成され、現在まで存続しているものとしている。スナップショット番号2500からスナップショット番号2520の直前まで「ファイルA」の内容は変わらないため、その検索キーワードも同一である。開始時点を基準にこれをKA,2500と表す。同様に、スナップショット番号[2520,2540]の「ファイルA」の検索キーワード集合をKA,2520、「ファイルB」のキーワード集合はKB,2510と表す。 In addition, it is assumed that “file B” is created at the time of snapshot number 2510 and continues to the present. Since the content of “file A” does not change from the snapshot number 2500 to immediately before the snapshot number 2520, the search keyword is also the same. This is expressed as K A, 2500 based on the starting point. Similarly, the search keyword set of “file A” with the snapshot number [ 2520 , 2540] is represented as K A, 2520 , and the keyword set of “file B” is represented as K B, 2510 .

この例に対応する第5の実施の形態による検索インデックスの形式は、図13の例に示すように、各キーワード集合に対応するエントリを、"FilePath", "StartNum", "EndNum"で始まる3つのフィールドによって識別する。
"FilePath"のフィールドにはファイルのパス名を格納し、 "StartNum"フィールドにはファイルがある状態にあるスナップショットの最初の番号を、"EndNum"フィールドにはファイルの削除や変更により、その状態が解消されたスナップショットの番号をそれぞれ格納する。「ファイルB」は現在まで継続しているので、"EndNum"フィールドにはその状態を表現するためにnull値を格納している。現在まで継続していることを示す値は、勿論、有効なスナップショット番号から識別される値であれば何でも良い。また"EndNum"フィールドには、ある状態が解消されたスナップショット番号を使用しているが、一般性を損なうことなく、ある状態が継続する最後のスナップショット番号、すなわち、ここで使用している値から1を引いた番号を使用することもできる。また、ここでは、ファイルの同一状態が継続する期間をスナップショット番号により与えているが、スナップショット番号とスナップショットのタイムスタンプ(作成時刻)の値を使用することも可能である。また本実施の形態の表現は、検索インデックスの意味的な構成を示しており、実際のインデックスファイルのデータ構造やフィールドの識別名には、勿論様々な構造、名前を使用することができる。
[第6の実施の形態]
以下の第6〜第8の実施の形態では、NAS(Network Attached Storage)上のWebサーバに対し、Google(登録商標)検索のようなWebインタフェースを通じて、ユーザが入力したキーワードに対応するスナップショット上のファイルを過去のファイルも含め探し出せるようにする。
As shown in the example of FIG. 13, the search index format according to the fifth embodiment corresponding to this example includes entries corresponding to each keyword set starting with “FilePath”, “StartNum”, “EndNum”. Identified by two fields.
The "FilePath" field stores the path name of the file, the "StartNum" field indicates the first number of the snapshot in which the file exists, and the "EndNum" field indicates the status of the file when it is deleted or changed Stores the number of the snapshot for which has been resolved. Since “File B” continues until now, a null value is stored in the “EndNum” field to express the state. Of course, the value indicating that it has continued until now can be any value as long as it is identified from a valid snapshot number. In the "EndNum" field, the snapshot number in which a certain state has been resolved is used, but the last snapshot number in which a certain state continues without sacrificing generality, that is, used here. A number obtained by subtracting 1 from the value can also be used. Here, the period during which the same state of the file continues is given by the snapshot number, but it is also possible to use the snapshot number and the time stamp (creation time) value of the snapshot. The expression of the present embodiment shows the semantic structure of the search index. Of course, various structures and names can be used for the actual index file data structure and field identification names.
[Sixth Embodiment]
In the following sixth to eighth embodiments, a snapshot corresponding to a keyword input by a user is transmitted to a Web server on NAS (Network Attached Storage) through a Web interface such as Google (registered trademark) search. Can be searched for, including past files.

以下の実施の形態では、連続スナップショットファイルサーバ100の多数のスナップショットから効率的にファイルを検索するために用いられる検索インデックを生成するための検索インデックス生成装置について説明する。   In the following embodiment, a search index generation device for generating a search index used for efficiently searching a file from a large number of snapshots of the continuous snapshot file server 100 will be described.

図14は、本発明の第6〜第8の実施の形態におけるインデックス生成装置の構成を示す。当該インデックス生成装置300は、検索インデックス作成部310、検索インデックス更新部330、検索インデックス最適化部340、検索インデックス参照部350、から構成される。   FIG. 14 shows the configuration of the index generation apparatus in the sixth to eighth embodiments of the present invention. The index generation apparatus 300 includes a search index creation unit 310, a search index update unit 330, a search index optimization unit 340, and a search index reference unit 350.

検索対象ファイル1100は、連続スナップショットファイルサーバ100の記憶装置110内に存在し、連続スナップショットファイルシステム151により管理されるファイルである。   The search target file 1100 is a file that exists in the storage device 110 of the continuous snapshot file server 100 and is managed by the continuous snapshot file system 151.

検索インデックス生成装置300の検索インデックス参照部350は、Webサーバ600にアクセスする。   The search index reference unit 350 of the search index generation device 300 accesses the Web server 600.

本実施の形態では、検索インデックス作成部310について説明するが、検索インデックス更新部330については第7の実施の形態で、検索インデックス最適化部340については第8の実施の形態でそれぞれ後述する。   In the present embodiment, the search index creation unit 310 will be described. The search index update unit 330 will be described later in the seventh embodiment, and the search index optimization unit 340 will be described later in an eighth embodiment.

図15は、本発明の第6の実施の形態における検索インデックスの作成処理のフローチャートである。   FIG. 15 is a flowchart of search index creation processing according to the sixth embodiment of the present invention.

ステップ601) 検索インデックスの作成部310は、まず、既存の検索インデックスを初期化ないしは新規に空の検索インデックスを作成する。   Step 601) The search index creation unit 310 first initializes an existing search index or creates a new empty search index.

ステップ602) そして、連続スナップショットファイルサーバ100からスナップショットの一覧S={s1,s2,…,sN}を取得する。但し、ここでNはスナップショットの個数であり、s1<s2<…<sNの順序関係があるものとする。 Step 602) Then, the snapshot list S = {s 1 , s 2 ,..., S N } is obtained from the continuous snapshot file server 100. However, where N is the number of snapshots, it is assumed that there is order relation s 1 <s 2 <... < s N.

ステップ603) 次に、スナップショットs1 を対象として、連続スナップショットファイルシステム151の記憶装置110上のディレクトリツリーを探索し、検索対象ファイル1100の F1={f1,f2,…,fm1}を処理対象として抽出する。 Step 603) Next, a directory tree on the storage device 110 of the continuous snapshot file system 151 is searched for the snapshot s 1, and F 1 = {f 1 , f 2 ,. m1 } is extracted as a processing target.

ステップ604) 検索対象ファイル1100のF1から未処理のファイルfを選択する。 Step 604) selects a file f unprocessed from F 1 of the search target files 1100.

ステップ605) そして、検索対象の全てのファイルに対して、検索キーワードを抽出する。   Step 605) Then, search keywords are extracted from all files to be searched.

ステップ606) 各ファイルに対し、抽出した検索キーワードとそのエントリをFilePathフィールドが検索ファイルのパス名に、StartNumフィールドがスナップショット番号s1に、EndNumフィールドがnull値となる新規エントリを検索インデックス記憶装置500の検索インデックスに追加する。 To step 606) the file, the extracted search keyword and the entry to the path name of the FilePath field search file, the StartNum field snapshot number s 1, search index storage a new entry that EndNum field is null value Add to 500 search indexes.

ステップ607) 検索対象のF1の全てのファイルを処理した場合は、ステップ608に移行し、全てのファイルを処理していない場合はステップ604に移行する。 Step 607) When all the files of F 1 to be searched are processed, the process proceeds to step 608, and when all the files are not processed, the process proceeds to step 604.

ステップ608) 続いて、一連のスナップショットに対して連続的に変更を追跡するために、インデックスiを1 に初期化する。   Step 608) Subsequently, index i is initialized to 1 to continuously track changes for a series of snapshots.

ステップ609) i=Nであった場合には直ちに処理を終了する。そうでない場合には、ステップ610に移行する。   Step 609) If i = N, the process is immediately terminated. Otherwise, the process proceeds to step 610.

ステップ610) スナップショットsi+1上の検索対象ファイルF i+1を抽出する。 Step 610) to extract the search target file F i + 1 on the snapshot s i + 1.

ステップ611) Fiに含まれるファイルfを選択する。 Step 611) The file f included in F i is selected.

ステップ612) ファイルfがスナップショットsi+1上に存在するかを判定し、存在する場合はステップ613に移行し、存在しない場合はステップ616に移行する。 Step 612) It is determined whether or not the file f exists on the snapshot s i +1. If it exists, the process proceeds to Step 613. If it does not exist, the process proceeds to Step 616.

ステップ613) スナップショットsi上のファイルfとスナップショットsi+1上のfのデータは同一であるかを判定し、同一である場合はステップ617に移行し、同一でない場合はステップ614に移行する。 Step 613) snapshots s i on file f and snapshot s i + 1 on the data of f determines whether the same, if the same processing proceeds to step 617, if not identical to step 614 Transition.

ステップ614) fの検索キーワード(Ki+1,f)を抽出する。 Step 614) The search keyword (K i + 1, f ) of f is extracted.

ステップ615) 検索インデックス記憶装置500の検索インデックスにキーワード集合k1+1,fを格納し、そのエントリを以下のフィールドで登録する。 Step 615) The keyword set k 1 + 1, f is stored in the search index of the search index storage device 500, and the entry is registered in the following fields.

・File Path: f
・StartNum:si+1
・EndNum:null
ステップ616) 検索インデックス記憶装置500の検索インデックスから
・FilePath=f,
・StartNum< si+1
・EndNum=null
のエントリを探索し、EndNumをsi+1に変更する。
・ File Path: f
・ StartNum: s i + 1
・ EndNum: null
Step 616) From the search index of the search index storage device 500: FilePath = f,
・ StartNum <s i + 1 ,
・ EndNum = null
Search for the entry and change EndNum to s i + 1 .

ステップ617) Fiの全てのファイルを処理したかを判定し、処理した場合はステップ618に移行し、処理していない場合はステップ611に移行する。 Step 617) to determine whether it has processed all of the files F i, if treated proceeds to step 618, if not treated proceeds to step 611.

ステップ618) Fi+1に含まれ、Fiに含まれないファイルf´を選択する。 Step 618) The file f ′ included in F i + 1 and not included in F i is selected.

ステップ619) ファイルf´の検索キーワード(Ki+1,f')を抽出する。 Step 619) The search keyword (K i + 1, f ′ ) of the file f is extracted.

ステップ620) 検索インデックス記憶装置500にキーワード集合(K1+1,f')を格納する。そのエントリを以下のフィールドで登録する。 Step 620) The keyword set (K 1 + 1, f ′ ) is stored in the search index storage device 500. Register the entry in the following fields:

・File Path: f´
・StartNum: si+1
・EndNum:null
ステップ621) Fi+1の全てのファイルを処理したかを判定し、処理した場合はステップ622に移行し、処理していない場合はステップ618に移行する。
・ File Path: f´
・ StartNum: s i + 1
・ EndNum: null
Step 621) It is determined whether all the files of F i + 1 have been processed. If processed, the process proceeds to step 622, and if not processed, the process proceeds to step 618.

上記のステップ610〜621では、先に処理したスナップショットsiとその次のスナップショットsi+1に対して、検索対象ファイル1100を調べ、内容を比較する。そしてsi+1で変更もしくは削除されたファイルに対しては、検索インデックス記憶装置500のファイルをFilePathに持つエントリで、StartNumフィールドが si+1 より小さく、EndNumフィールドが null 値であるエントリを見つけ、そのEndNumフィールドにsi+1を設定する。また、si+1で変更もしくは新規作成されたファイルに対して、検索キーワードを抽出し、各ファイルに対し、抽出した検索キーワードとそのエントリをFilePathフィールドが検索ファイルのパス名に、StartNumフィールドがスナップショット番号si+1に、EndNumフィールドがnull値となる新規エントリを検索インデックスに追加する。そして、インデックスiをインクリメントし、ステップ609からi=Nになるまで処理を繰り返す。 In steps 610 to 621 described above, the search target file 1100 is examined for the snapshot s i processed earlier and the next snapshot s i + 1 , and the contents are compared. For a file that has been changed or deleted with s i + 1 , an entry having the file of the search index storage device 500 in FilePath, the StartNum field being smaller than s i + 1 , and the EndNum field having a null value Find and set s i + 1 in its EndNum field. In addition, search keywords are extracted for files that have been changed or newly created with s i + 1 , and for each file, the extracted search keywords and their entries are displayed in the FilePath field as the path name of the search file, and in the StartNum field. A new entry having a null value in the EndNum field is added to the search index at the snapshot number s i + 1 . Then, the index i is incremented, and the process is repeated from step 609 until i = N.

[第7の実施の形態]
本実施の形態では検索インデックス更新部330による検索インデックス更新処理について説明する。
[Seventh Embodiment]
In the present embodiment, search index update processing by the search index update unit 330 will be described.

図16は、本発明の第7の実施の形態における検索インデックスの更新処理のフローチャートである。   FIG. 16 is a flowchart of search index update processing according to the seventh embodiment of the present invention.

本実施の形態の検索インデックスの更新処理は、検索インデックス更新部330の常駐プログラムにより実施される。   The search index update processing of the present embodiment is performed by a resident program of the search index update unit 330.

ステップ701) まず、検索インデックス記憶装置500の検索インデックスに対し、用いた最終スナップショット番号を取得しSprevとして設定する。Sprev は、検索インデックス記憶装置500上のエントリを網羅的に調べて決定するか、もしくは前述の検索インデックス生成処理でSNを保存するようにしてその値を使う。 Step 701) First, the last snapshot number used for the search index of the search index storage device 500 is acquired and set as S prev . S prev is determined by exhaustively examining the entries in the search index storage device 500, or the value is used by storing S N in the search index generation process described above.

ステップ702) そして、番号がs > sprevなるスナップショットs が存在するか確認する。存在しない場合には、ステップ703に移行し、存在する場合はステップ705に移行する。 Step 702) Then, it is confirmed whether there is a snapshot s whose number is s> s prev . If it does not exist, the process proceeds to step 703, and if it exists, the process proceeds to step 705.

ステップ703) 存在しない場合は、終了要求の有無を確認し、あれば直ちに終了し、なければステップ704に移行する。   Step 703) If it does not exist, the presence or absence of the end request is confirmed. If there is, the process ends immediately. If not, the process proceeds to Step 704.

ステップ704) 一定時間スリープした後、ステップ702に移行する。   Step 704) After sleeping for a predetermined time, the process proceeds to Step 702.

ステップ705) ステップ702において、番号がs>sprevなるスナップショットsが存在する場合は、s>sprevなるスナップショットを選び、snextとして設定する。 Step 705) If there is a snapshot s with the number s> s prev in step 702, a snapshot with s> s prev is selected and set as s next .

ステップ706) そして、スナップショットsprevとスナップショットsnextに対して、検索対象ファイル1100を調べ、内容を比較し、変更または削除されたファイルを抽出する。 Step 706) The search target file 1100 is examined for the snapshot s prev and the snapshot s next , the contents are compared, and the changed or deleted file is extracted.

ステップ707) 更新されたファイルFcmから未処理のファイルfを選択する。 Step 707) The unprocessed file f is selected from the updated file F cm .

ステップ708) fの検索キーワード(Knext,f)を抽出する。 Step 708) The search keyword (K next, f ) of f is extracted.

ステップ709) 検索インデックス記憶装置500にキーワード集合(Knext,f)を格納する。そのエントリを以下のフィールドで登録する。 Step 709) The keyword set (K next, f ) is stored in the search index storage device 500. Register the entry in the following fields:

・File Path: f
・StartNum: snext
・EndNum:null
ステップ710) Fcmの全てのファイルを処理した場合には、ステップ711に移行し、処理していない場合はステップ707に移行する。
・ File Path: f
・ StartNum: s next
・ EndNum: null
Step 710) If all the files of F cm have been processed, the process proceeds to step 711. If not, the process proceeds to step 707.

ステップ711) スナップショットsprev、snextの間で変更または削除されたファイルFmdを抽出する。 Step 711) The file F md changed or deleted between the snapshots s prev and s next is extracted.

ステップ712) ファイルFmdから未処理のファイルf´を選択する。 Step 712) The unprocessed file f ′ is selected from the file F md .

ステップ713) 検索インデックス記憶装置500の検索インデックスから、
・File Path: f´
・StartNum<si+1
・EndNum:null
を探索し、EndNumをsnextに変更する。
Step 713) From the search index of the search index storage device 500,
・ File Path: f´
・ StartNum <s i + 1
・ EndNum: null
And change EndNum to s next .

ステップ714) ファイルFmdの全てのファイルを処理したかを判定し、処理した場合はステップ715に移行し、処理していない場合はステップ712に移行する。 Step 714) It is determined whether all the files in the file F md have been processed. If processed, the process proceeds to Step 715. If not processed, the process proceeds to Step 712.

上記のステップ705〜715では、新スナップショットsが存在する場合には、s>sprevなるスナップショットを選び、snextとして設定する。そして、スナップショットsprevとスナップショットsnextに対して、検索対象ファイル1100を調べ、内容を比較する(ステップ705)。その結果、snextで変更もしくは削除されたファイルに対しては、検索インデックスの当該ファイルを FilePath に持つエントリで、StartNumフィールドが snext より小さく、EndNumフィールドがnull値であるエントリを見つけ、そのEndNumフィールドにsnextを設定する。また、snextで変更もしくは新規作成されたファイルに対して、検索キーワードを抽出し、各ファイルに対し、抽出した検索キーワードとそのエントリをFilePathフィールドが検索ファイルのパス名に、StartNumフィールドがスナップショット番号snextに、EndNumフィールドが null 値となる新規エントリを検索インデックスに追加する(ステップ706〜ステップ715)。そして、最終スナップショット番号にsnextを設定し、ステップ701から処理を繰り返す。 In steps 705 to 715 described above, if a new snapshot s exists, a snapshot satisfying s> s prev is selected and set as s next . Then, the search target file 1100 is examined for the snapshot s prev and the snapshot s next , and the contents are compared (step 705). As a result, for a file that has been changed or deleted with s next , find an entry that has the corresponding file in the search index in FilePath, the StartNum field is smaller than s next , and the EndNum field is null. Set s next in the field. Also, search keywords are extracted for files that have been changed or newly created with s next , and for each file, the extracted search keywords and their entries are the path name of the search file in the FilePath field, and the StartNum field is a snapshot. A new entry having a null value in the EndNum field is added to the search index at the number s next (steps 706 to 715). Then, s next is set as the final snapshot number, and the processing from step 701 is repeated.

[第8の実施の形態]
本実施の形態では、検索インデックス最適化部340による検索インデックスの最適化処理について説明する。
[Eighth embodiment]
In the present embodiment, search index optimization processing by the search index optimization unit 340 will be described.

図17は、本発明の第8の実施の形態における検索インデックスの最適化処理のフローチャートである。   FIG. 17 is a flowchart of search index optimization processing according to the eighth embodiment of the present invention.

ステップ801) 検索インデックス最適化部340では、まず、連続スナップショットファイルサーバ100より、スナップショット(番号)の一覧(S={s1,s2,…,sn})を取得する。   Step 801) First, the search index optimization unit 340 acquires a list of snapshots (numbers) (S = {s1, s2,..., Sn}) from the continuous snapshot file server 100.

ステップ802) 次に、検索インデックス記憶装置500の検索インデックスの各エントリを調べて、未処理のエントリeを1個抽出する。   Step 802) Next, each entry of the search index in the search index storage device 500 is examined, and one unprocessed entry e is extracted.

ステップ803) EndNum=nullであるかを調べ、nullである場合はステップ806に移行し、nullでない場合はステップ804に移行する。   Step 803) Whether EndNum = null is checked. If it is null, the process proceeds to Step 806. If it is not null, the process proceeds to Step 804.

ステップ804) StartNumフィールド≦s<EndNumフィールドなるスナップショット番号sがSに存在するかを判定し、存在する場合はステップ806に移行し、存在しない場合はステップ805に移行する。   Step 804) It is determined whether the snapshot number s satisfying StartNum field ≦ s <EndNum field exists in S. If it exists, the process proceeds to Step 806, and if it does not exist, the process proceeds to Step 805.

ステップ805) エントリeを検索インデックスから削除する。   Step 805) Delete entry e from the search index.

ステップ806) 検索インデックスの全てのエントリを処理した場合は、処理を終了し、処理していないエントリがある場合はステップ802に移行する。   Step 806) When all the entries of the search index have been processed, the process is terminated, and when there is an unprocessed entry, the process proceeds to Step 802.

上記のステップ802〜ステップ806では、EndNumフィールドにnull値以外が設定され、かつ StartNumフィールド≦s<EndNumフィールなるスナップショット番号s が取得スナップショット一覧に含まれないエントリを削除する。検索インデックスの全てのエントリに対しこの処理を適用することで、不要エントリを削除し、検索インデックスを削減する。この検索インデックスの最適化処理は、常駐プログラムで実施してもよいし、定められたスケジュールで実行しても良い。   In steps 802 to 806 described above, an entry whose non-null value is set in the EndNum field and the snapshot number s satisfying StartNum field ≦ s <EndNum field is not included in the acquired snapshot list is deleted. By applying this process to all entries in the search index, unnecessary entries are deleted and the search index is reduced. This search index optimization processing may be executed by a resident program or may be executed according to a predetermined schedule.

なお、上記の第1〜第3の実施の形態における連続スナップショットファイルサーバの構成要素の動作をプログラムとして構築し、連続スナップショットファイルサーバとして利用されるコンピュータにインストールして実行させる、または、ネットワークを介して流通させることが可能である。   The operation of the constituent elements of the continuous snapshot file server in the above first to third embodiments is constructed as a program and installed in a computer used as the continuous snapshot file server to be executed, or a network It is possible to circulate through.

また、第4の実施の形態におけるクライアント端末の構成要素の動作をプログラムとして構築し、クライアント端末として利用されるコンピュータにインストールして実行させる、または、ネットワークを介して流通させることが可能である。   Further, the operation of the components of the client terminal in the fourth embodiment can be constructed as a program, installed in a computer used as a client terminal and executed, or distributed via a network.

また、第5〜第8の実施の形態におけるインデックス生成装置の動作をプログラムとして構築し、インデックス生成装置として利用されるコンピュータにインストールして実行させる、または、ネットワークを介して流通させることが可能である。   In addition, the operation of the index generation device according to the fifth to eighth embodiments can be constructed as a program, installed in a computer used as the index generation device and executed, or distributed via a network. is there.

また、上記の構築されたプログラムをハードディスクや、フレキシブルディスク・CD−ROM等の可搬記憶媒体に格納し、コンピュータにインストールする、または、配布することが可能である。   Further, the constructed program can be stored in a portable storage medium such as a hard disk, a flexible disk, or a CD-ROM, and can be installed or distributed in a computer.

なお、本発明は、上記の実施の形態に限定されることなく、特許請求の範囲内において種々変更・応用が可能である。   The present invention is not limited to the above-described embodiment, and various modifications and applications can be made within the scope of the claims.

100 連続スナップショットファイルサーバ
110 記憶手段、記憶装置
120 ネットワークインタフェース
150 基本ソフト(OS)
151 ファイルシステム、連続スナップショットファイルシステム
152 ネットワーク通信部
161 スナップショット管理デーモン
162 解放デーモン
165 ファイル共有サービス部
200 クライアントPC
210 記憶装置
220 ネットワークインタフェース
250 基本ソフト(OS)
251 ローカルファイルシステム
252 ネットワーク通信部
254 通知機能部
255 ファイル共有クライアント部
261 同期デーモン
300 検索インデックス生成装置
310 検索インデックス作成部
330 検索インデックス更新部
340 検索インデックス最適化部
350 検索インデックス参照部
500 検索インデックス記憶装置
600 Webサーバ
1100 検索対象ファイル
1611 スナップショット取得手段
1612 スナップショット削除手段
100 continuous snapshot file server 110 storage means, storage device 120 network interface 150 basic software (OS)
151 File System, Continuous Snapshot File System 152 Network Communication Unit 161 Snapshot Management Daemon 162 Release Daemon 165 File Sharing Service Unit 200 Client PC
210 Storage device 220 Network interface 250 Basic software (OS)
251 Local file system 252 Network communication unit 254 Notification function unit 255 File sharing client unit 261 Synchronization daemon 300 Search index generation device 310 Search index creation unit 330 Search index update unit 340 Search index optimization unit 350 Search index reference unit 500 Search index storage Device 600 Web server 1100 Search target file 1611 Snapshot acquisition means 1612 Snapshot deletion means

Claims (5)

ファイルの内容や属性、ディレクトリツリーの構成などの状態の変更を検知し、記憶手段の同一ボリューム内にスナップショットを自動的かつ追加的に作成するファイルシステムに対するスナップショットの管理を行うファイルサーバであって、
前記ファイルシステムからスナップショットを取得し、該スナップショットの生成時刻の情報に基づきスナップショットをグループ分けし、現在時刻より定められた時間遡った過去の時点より後に生成されたスナップショットは全て該ファイルシステムに保存するスナップショット取得手段と、
前記過去の時点より以前のスナップショットについては、スナップショットの生成時刻の間隔が、グループごとに定められた時間以上となるよう、前記ファイルシステムのテーブルから段階的にスナップショットを削除するスナップショット削除手段と、
前記ファイルサーバが、スナップショットを、NFS(Network File System)、CIFS (Common Internet File System)といったリモートファイル管理プロトコルを通じ、クライアント端末からネットワーク経由で公開する連続スナップショットを共有するサーバであるときに、
スナップショットを生成時刻から現在時刻までの存続期間に応じて複数のグループに分け、前記ファイルシステムに格納するグループ化手段と、
前記ファイルシステムの各グループから一定個数のスナップショットを選んで公開することで、前記クライアント端末にアクセスさせるスナップショットの数を一定個数以内に抑える公開手段と、
を有することを特徴とするファイルサーバ。
A file server that detects changes in the status of file contents and attributes, directory tree configuration, etc., and manages snapshots for file systems that automatically and additionally create snapshots in the same volume of storage means. And
Snapshots are acquired from the file system, snapshots are grouped based on the generation time information of the snapshots, and all snapshots generated after a past point in time that is set back from the current time are the files. Snapshot acquisition means to be stored in the system;
For snapshots prior to the past time point, snapshot deletion is performed in such a manner that snapshots are deleted step by step from the file system table so that the interval between the generation times of snapshots is equal to or longer than the time determined for each group. Means,
When said file server, a snapshot, NFS (Network File System), through a remote file management protocols such as CIFS (Common Internet File S ystem) , is a server that shares a continuous snapshots exposed via a network from a client terminal In addition,
Grouping means for dividing the snapshots into a plurality of groups according to the duration from the generation time to the current time, and storing them in the file system;
An publishing means for keeping the number of snapshots to be accessed by the client terminal within a certain number by selecting and publishing a certain number of snapshots from each group of the file system;
A file server comprising:
前記ファイルシステムのテーブル上でスナップショットを削除した場合でも、スナップショットが使用するディスク上のデータ及びメタデータ領域を直ちには解放せず、予め定められたスケジュールに従って動作するか、もしくはCPUの使用率やディスク入出力量などのシステム負荷が一定水準より低い期間に動作するバックグラウンドプログラムによって、前記領域をスナップショット削除時より遅らせて解放する解放手段を更に有する
請求項1記載のファイルサーバ。
Even when a snapshot is deleted from the file system table, the data and metadata areas on the disk used by the snapshot are not released immediately, but operate according to a predetermined schedule, or the CPU usage rate 2. The file server according to claim 1, further comprising release means for releasing the area after a snapshot deletion by a background program that operates during a period when the system load such as the disk input / output amount is lower than a certain level.
ファイルの内容や属性、ディレクトリツリーの構成などの状態の変更を検知し、記憶手段の同一ボリューム内にスナップショットを自動的かつ追加的に作成するファイルシステムに対するスナップショットの管理を行うファイルサーバにおける連続スナップショット管理方法であって、
前記ファイルサーバのスナップショット取得手段が、
前記ファイルシステムからスナップショットを取得し、該スナップショットの生成時刻の情報に基づきスナップショットをグループ分けし、現在時刻より定められた時間遡った過去の時点より後に生成されたスナップショットは全て該ファイルシステムに保存し、
前記ファイルサーバのスナップショット削除手段が、
前記過去の時点より以前のスナップショットについては、スナップショットの生成時刻の間隔が、グループごとに定められた時間以上となるよう、前記ファイルシステムのテーブルから段階的にスナップショットを削除し、
前記ファイルサーバが、スナップショットを、NFS(Network File System)、CIFS (Common Internet File System)といったリモートファイル管理プロトコルを通じ、クライアント端末からネットワーク経由で公開する連続スナップショットを共有するサーバであるときは、
前記ファイルサーバのグループ化手段が、
スナップショットを生成時刻から現在時刻までの存続期間に応じて複数のグループに分け、前記ファイルシステムに格納し、
前記ファイルサーバの公開手段が、
前記ファイルシステムの各グループから一定個数のスナップショットを選んで公開することで、前記クライアント端末にアクセスさせるスナップショットの数を一定個数以内に抑える
ことを特徴とする連続スナップショット管理方法。
Continuous on a file server that manages snapshot management for file systems that detect state changes such as file contents and attributes, directory tree configuration, etc., and create snapshots automatically and additionally in the same volume of storage means A snapshot management method,
The file server snapshot acquisition means comprises:
Snapshots are acquired from the file system, snapshots are grouped based on the generation time information of the snapshots, and all snapshots generated after a past point in time that is set back from the current time are the files. Save it in the system,
The snapshot deletion means of the file server is
For snapshots prior to the past time point, snapshots are deleted step by step from the file system table so that the interval between snapshot generation times is equal to or greater than the time determined for each group,
When said file server, a snapshot, NFS (Network File System), through a remote file management protocols such as CIFS (Common Internet File S ystem) , is a server that shares a continuous snapshots exposed via a network from a client terminal Is
The file server grouping means comprises:
The snapshots are divided into a plurality of groups according to the duration from the generation time to the current time, stored in the file system,
The file server publishing means comprises:
A continuous snapshot management method, wherein a predetermined number of snapshots are selected from each group of the file system and released, thereby suppressing the number of snapshots to be accessed by the client terminal within a predetermined number.
前記ファイルサーバの解放手段が、
前記ファイルシステムのテーブル上でスナップショットを削除した場合でも、スナップショットが使用するディスク上のデータ及びメタデータ領域を直ちには解放せず、予め定められたスケジュールに従って動作するか、もしくはCPUの使用率やディスク入出力量などのシステム負荷が一定水準より低い期間に動作するバックグラウンドプログラムによって、前記領域をスナップショット削除時より遅らせて解放する
請求項3記載の連続スナップショット管理方法。
The file server release means comprises:
Even when a snapshot is deleted from the file system table, the data and metadata areas on the disk used by the snapshot are not released immediately, but operate according to a predetermined schedule, or the CPU usage rate 4. The continuous snapshot management method according to claim 3, wherein the area is released later than when the snapshot is deleted by a background program that operates during a period when the system load such as the disk input / output amount is lower than a certain level.
請求項1または2に記載のファイルサーバを構成する各手段としてコンピュータを機能させるための連続スナップショット管理プログラム。   The continuous snapshot management program for functioning a computer as each means which comprises the file server of Claim 1 or 2.
JP2010070622A 2010-03-25 2010-03-25 File server, continuous snapshot management method, and continuous snapshot management program Expired - Fee Related JP5574774B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2010070622A JP5574774B2 (en) 2010-03-25 2010-03-25 File server, continuous snapshot management method, and continuous snapshot management program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2010070622A JP5574774B2 (en) 2010-03-25 2010-03-25 File server, continuous snapshot management method, and continuous snapshot management program

Related Child Applications (1)

Application Number Title Priority Date Filing Date
JP2013209013A Division JP5650826B2 (en) 2013-10-04 2013-10-04 SEARCH INDEX GENERATION DEVICE, SEARCH INDEX CONSTRUCTION METHOD, AND SEARCH INDEX CONSTRUCTION PROGRAM

Publications (2)

Publication Number Publication Date
JP2011204008A JP2011204008A (en) 2011-10-13
JP5574774B2 true JP5574774B2 (en) 2014-08-20

Family

ID=44880583

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2010070622A Expired - Fee Related JP5574774B2 (en) 2010-03-25 2010-03-25 File server, continuous snapshot management method, and continuous snapshot management program

Country Status (1)

Country Link
JP (1) JP5574774B2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109656876A (en) * 2018-12-07 2019-04-19 杭州宏杉科技股份有限公司 Storing method, device, electronic equipment and the machine readable storage medium of snapshot
US10802928B2 (en) 2015-09-10 2020-10-13 International Business Machines Corporation Backup and restoration of file system

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101275661B1 (en) 2012-08-10 2013-06-17 (주)네오위즈게임즈 Method and server for managing log information of online game
JP2017004330A (en) * 2015-06-12 2017-01-05 日本広告メディア供給株式会社 Document editing system, document editing method, and document editing program
JP2017068729A (en) * 2015-10-01 2017-04-06 日本電気株式会社 File storage device, information processing method, program, and file storage system

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4215542B2 (en) * 2002-03-19 2009-01-28 ネットワーク アプライアンス, インコーポレイテッド System and method for determining changes between two snapshots and sending them to a destination snapshot
US7475098B2 (en) * 2002-03-19 2009-01-06 Network Appliance, Inc. System and method for managing a plurality of snapshots
JP4799936B2 (en) * 2005-07-11 2011-10-26 株式会社日立製作所 Conditional snapshot acquisition method and system
JP2007219609A (en) * 2006-02-14 2007-08-30 Hitachi Ltd Snapshot management device and method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10802928B2 (en) 2015-09-10 2020-10-13 International Business Machines Corporation Backup and restoration of file system
CN109656876A (en) * 2018-12-07 2019-04-19 杭州宏杉科技股份有限公司 Storing method, device, electronic equipment and the machine readable storage medium of snapshot

Also Published As

Publication number Publication date
JP2011204008A (en) 2011-10-13

Similar Documents

Publication Publication Date Title
US10956275B2 (en) Collaborative restore in a networked storage system
US20200210075A1 (en) Data management system
US9785518B2 (en) Multi-threaded transaction log for primary and restore/intelligence
US10846267B2 (en) Masterless backup and restore of files with multiple hard links
US8095756B1 (en) System and method for coordinating deduplication operations and backup operations of a storage volume
US9852150B2 (en) Avoiding client timeouts in a distributed filesystem
US8234468B1 (en) System and method for providing variable length deduplication on a fixed block file system
US20150193315A1 (en) Method and device for managing multiple snapshots of data strorage device
JP2015525419A (en) Advanced data management virtualization system
US7783598B1 (en) Avoiding frozen-volume write penalties
JP2013543198A (en) System and method for data management virtualization
US11474912B2 (en) Backup and restore of files with multiple hard links
US9569311B2 (en) Computer system for backing up data
JP5574774B2 (en) File server, continuous snapshot management method, and continuous snapshot management program
JP5650826B2 (en) SEARCH INDEX GENERATION DEVICE, SEARCH INDEX CONSTRUCTION METHOD, AND SEARCH INDEX CONSTRUCTION PROGRAM
US9047309B1 (en) Dynamic snapshot mounting
Wang et al. Fast off-site backup and recovery system for HDFS
Han et al. A Novel File-Level Continuous Data Protection System

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20120309

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20130711

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20130806

RD02 Notification of acceptance of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7422

Effective date: 20131001

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20131004

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20140107

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20140131

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: 20140624

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20140701

R150 Certificate of patent or registration of utility model

Ref document number: 5574774

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees