JP2016057871A - Information processing apparatus, information processing method, and program - Google Patents

Information processing apparatus, information processing method, and program Download PDF

Info

Publication number
JP2016057871A
JP2016057871A JP2014184035A JP2014184035A JP2016057871A JP 2016057871 A JP2016057871 A JP 2016057871A JP 2014184035 A JP2014184035 A JP 2014184035A JP 2014184035 A JP2014184035 A JP 2014184035A JP 2016057871 A JP2016057871 A JP 2016057871A
Authority
JP
Japan
Prior art keywords
processing
command
maximum
execution
weight
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
JP2014184035A
Other languages
Japanese (ja)
Other versions
JP6384218B2 (en
Inventor
聖子 松村
Kiyoko Matsumura
聖子 松村
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP2014184035A priority Critical patent/JP6384218B2/en
Publication of JP2016057871A publication Critical patent/JP2016057871A/en
Application granted granted Critical
Publication of JP6384218B2 publication Critical patent/JP6384218B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

PROBLEM TO BE SOLVED: To provide an information processing apparatus configured to prevent stop of background processing even when multiple kinds of commands are executed, an information processing method, and a program.SOLUTION: An exclusive control apparatus 100 includes an execution control section 160 and a command count control section 141. The execution control section 160 causes a processing section 170 to execute required commands so that the number of commands to be executed by the processing section 170 for each command count period may be equal to or less than the maximum number of commands. The command count control section 141 sets the maximum number of commands, according to a cumulative value of weights of the required commands.SELECTED DRAWING: Figure 2

Description

本発明は、情報処理装置、情報処理方法、及び、プログラムに関し、特に、要求されたコマンドに係る処理とバックグラウンド処理とを実行する、情報処理装置、情報処理方法、及び、プログラムに関する。   The present invention relates to an information processing device, an information processing method, and a program, and more particularly, to an information processing device, an information processing method, and a program that execute processing related to a requested command and background processing.

複数のホストがディスク装置等の共通資源にアクセスするシステムにおいて、各ホストからの要求(コマンド)に対する排他制御を、排他制御装置を用いて行う方法が、例えば、特許文献1に開示されている。   In a system in which a plurality of hosts access a common resource such as a disk device, a method of performing exclusive control on a request (command) from each host using the exclusive control device is disclosed in, for example, Patent Document 1.

特許文献1のような排他制御装置は、ホストから受け取るコマンドに係る処理を実行するだけでなく、装置の障害監視等のバックグラウンド処理も実行する。ホストからのコマンドは、迅速な処理が要求されるため、排他制御装置は、ホストからのコマンドに係る処理を優先的に実行し、ホストからのコマンドがない時間に、バックグラウンド処理を行う。この場合、ホストからのコマンドの負荷が高くなると、バックグラウンド処理の実行が滞り、装置が正常に動作しなくなる可能性がある。そこで、例えば、所定長の周期毎に実行するコマンドの数を制限する技術が用いられる。これにより、ある周期において実行したコマンドの数が上限に達した場合は、当該周期における以降のコマンドの実行が中断され、バックグラウンド処理が実行される。   An exclusive control device such as Patent Literature 1 not only executes processing related to a command received from the host, but also executes background processing such as device failure monitoring. Since the command from the host requires rapid processing, the exclusive control device preferentially executes processing related to the command from the host and performs background processing when there is no command from the host. In this case, if the command load from the host becomes high, execution of background processing may be delayed and the apparatus may not operate normally. Thus, for example, a technique is used that limits the number of commands executed for each predetermined length of period. As a result, when the number of commands executed in a certain period reaches the upper limit, execution of subsequent commands in the period is interrupted and background processing is executed.

図16は、このような、周期毎に実行するコマンドの数を制限する技術における、受信したコマンドの実行タイミングの例を示す図である。図16の例では、500msecの周期(コマンドカウント周期)毎に、実行したコマンド数がカウントされ、ある周期のコマンド数が100になった場合、次の周期が開始されるまで、コマンドの実行が中断される。   FIG. 16 is a diagram illustrating an example of the execution timing of a received command in such a technique for limiting the number of commands executed for each period. In the example of FIG. 16, the number of executed commands is counted every 500 msec period (command count period). When the number of commands in a certain period reaches 100, the command is executed until the next period is started. Interrupted.

一方、データベースの巨大化等により、排他制御が必要な資源数が増大し、1台の排他制御装置では、処理できる資源数や性能に係る要求を満たせなくなりつつある。そのため、複数の排他制御装置を用いて処理を分散する技術が用いられている。このように、複数の排他制御装置を用いた場合、一部の排他制御装置の障害が全体の運用に影響するため、排他制御装置同士が互いに死活監視を行う必要がある。死活監視等の処理はバックグラウンドで行われるが、このようなバックグラウンド処理が滞ることは許されない。   On the other hand, the number of resources that require exclusive control increases due to the enlarging of the database and the like, and a single exclusive control device is becoming unable to satisfy the demands regarding the number of resources that can be processed and performance. Therefore, a technique for distributing processing using a plurality of exclusive control devices is used. As described above, when a plurality of exclusive control devices are used, failures of some exclusive control devices affect the overall operation, and thus it is necessary for the exclusive control devices to monitor each other. Processing such as alive monitoring is performed in the background, but such background processing is not allowed to be delayed.

図17は、複数の排他制御装置を用いたシステムにおいて、各排他制御装置がホストから受信するコマンドの例を示す図である。   FIG. 17 is a diagram illustrating an example of commands that each exclusive control device receives from a host in a system using a plurality of exclusive control devices.

図17に示すように、ホストから受信するコマンドは、処理に要する時間(CPU(Central Processing Unit)占有率)、発生頻度の違い等で、複数の種類に分類できる。複数の排他制御装置を用いたシステムでは、ある排他制御装置が故障した場合、上位装置(複数のホスト)が、他の排他制御装置への情報の再生(リカバリ)を実行する。リカバリでは、図17におけるリカバリ系コマンドのように、CPU占有率の高いコマンドが連続して発行される。この場合、所定長の周期毎に実行するコマンドの数を制限する技術を用いても、コマンド数が上限に達することなくCPUが占有され続けてしまうため、バックグラウンド処理が実行されないことがある。そのため、ホストは、リカバリの開始および終了を排他制御装置へ通知し、排他制御装置は、リカバリ中におけるバックグラウンド処理の実行停止による誤動作を防ぐための対処を行っていた。   As shown in FIG. 17, the commands received from the host can be classified into a plurality of types depending on the time required for processing (CPU (Central Processing Unit) occupancy), the frequency of occurrence, and the like. In a system using a plurality of exclusive control devices, when a certain exclusive control device breaks down, the host device (a plurality of hosts) executes information reproduction (recovery) to other exclusive control devices. In the recovery, commands having a high CPU occupancy rate are issued continuously like the recovery commands in FIG. In this case, even if a technique for limiting the number of commands to be executed for each period of a predetermined length is used, the background processing may not be executed because the CPU continues to be occupied without reaching the upper limit. For this reason, the host notifies the exclusive control device of the start and end of recovery, and the exclusive control device takes measures to prevent malfunction due to the stop of execution of background processing during recovery.

特開2003−330906号公報JP 2003-330906 A

上述のように、排他制御装置において、所定長の周期毎に実行するコマンドの数を制限する方法では、コマンドの種類によっては、バックグラウンド処理が実行されないという問題があった。   As described above, in the method of limiting the number of commands to be executed for each cycle of a predetermined length in the exclusive control device, there is a problem that background processing is not executed depending on the type of command.

本発明の目的は、上述した課題を解決し、複数種類のコマンドが実行される場合でも、バックグラウンド処理の実行停止を防ぐことができる、情報処理装置、情報処理方法、及び、プログラムを提供することにある。   An object of the present invention is to provide an information processing apparatus, an information processing method, and a program capable of solving the above-described problems and preventing background processing from being stopped even when a plurality of types of commands are executed. There is.

本発明の情報処理装置は、処理手段により実行される所定長の周期毎の処理の数が、最大処理数以下となるように、要求された処理の実行を前記処理手段に指示する実行制御手段と、前記要求された処理の重みの累積値に応じて、前記最大処理数を設定する、処理数制御手段と、を備える。   The information processing apparatus according to the present invention includes an execution control unit that instructs the processing unit to execute a requested process so that the number of processes per cycle of a predetermined length executed by the processing unit is equal to or less than the maximum number of processes. And a processing number control means for setting the maximum processing number in accordance with the accumulated value of the requested processing weights.

本発明の情報処理方法は、要求された処理の重みの累積値に応じて、最大処理数を設定し、処理手段により実行される所定長の周期毎の処理の数が、前記最大処理数以下となるように、前記要求された処理の実行を前記処理手段に指示する。   In the information processing method of the present invention, the maximum number of processes is set according to the accumulated value of the requested process weights, and the number of processes per period of a predetermined length executed by the processing means is equal to or less than the maximum number of processes. The processing means is instructed to execute the requested processing.

本発明のプログラムは、コンピュータに、要求された処理の重みの累積値に応じて、最大処理数を設定し、処理手段により実行される所定長の周期毎の処理の数が、前記最大処理数以下となるように、前記要求された処理の実行を前記処理手段に指示する、処理を実行させる。   The program of the present invention sets the maximum number of processes in the computer according to the accumulated value of the requested process weights, and the number of processes per period of a predetermined length executed by the processing means is the maximum number of processes. In order to execute the requested processing, the processing means is instructed to execute the requested processing.

本発明の効果は、複数種類のコマンドが実行される場合でも、バックグラウンド処理の実行停止を防げることである。   The effect of the present invention is to prevent the background process from being stopped even when a plurality of types of commands are executed.

本発明の実施の形態の特徴的な構成を示すブロック図である。It is a block diagram which shows the characteristic structure of embodiment of this invention. 本発明の実施の形態における、排他制御装置100の構成を示すブロック図である。It is a block diagram which shows the structure of the exclusive control apparatus 100 in embodiment of this invention. 本発明の実施の形態における、排他制御システム1の構成を示すブロック図である。It is a block diagram which shows the structure of the exclusive control system 1 in embodiment of this invention. 本発明の実施の形態における、コンピュータにより実現された排他制御装置100の構成を示すブロック図である。It is a block diagram which shows the structure of the exclusive control apparatus 100 implement | achieved by computer in embodiment of this invention. 本発明の実施の形態における、重み集計処理を示すフローチャートである。It is a flowchart which shows the weight total process in embodiment of this invention. 本発明の実施の形態における、コマンド受信処理を示すフローチャートである。It is a flowchart which shows the command reception process in embodiment of this invention. 本発明の実施の形態における、コマンド実行制御処理を示すフローチャートである。It is a flowchart which shows the command execution control processing in embodiment of this invention. 本発明の実施の形態における、コマンド実行処理を示すフローチャートである。It is a flowchart which shows the command execution process in embodiment of this invention. 本発明の実施の形態における、集計テーブル232の例を示す図である。It is a figure which shows the example of the total table 232 in embodiment of this invention. 本発明の実施の形態における、重みテーブル242の例を示す図である。It is a figure which shows the example of the weight table 242 in embodiment of this invention. 本発明の実施の形態における、デフォルトコマンド数244の例を示す図である。It is a figure which shows the example of the default command number 244 in embodiment of this invention. 本発明の実施の形態における、重み閾値245の例を示す図である。It is a figure which shows the example of the weight threshold value 245 in embodiment of this invention. 本発明の実施の形態における、コマンドに係る処理、及び、バックグラウンド処理の実行例を示す図である。It is a figure which shows the execution example of the process which concerns on a command, and a background process in embodiment of this invention. 本発明の実施の形態における、コマンドに係る処理、及び、バックグラウンド処理の実行例(図13の続き)を示す図である。It is a figure which shows the execution example (continuation of FIG. 13) of the process which concerns on a command, and a background process in embodiment of this invention. 本発明の実施の形態における、コマンドに係る処理、及び、バックグラウンド処理の実行例(図14の続き)を示す図である。It is a figure which shows the execution example (continuation of FIG. 14) of the process which concerns on a command, and a background process in embodiment of this invention. 周期毎に実行するコマンドの数を制限する技術における、受信したコマンドの実行タイミングの例を示す図である。It is a figure which shows the example of the execution timing of the received command in the technique which restrict | limits the number of commands performed for every period. 複数の排他制御装置を用いたシステムにおいて、各排他制御装置がホストから受信するコマンドの例を示す図である。It is a figure which shows the example of the command which each exclusive control apparatus receives from a host in the system using a some exclusive control apparatus.

はじめに、本発明の実施の形態の構成について説明する。図3は、本発明の実施の形態における、排他制御システム1の構成を示すブロック図である。   First, the configuration of the embodiment of the present invention will be described. FIG. 3 is a block diagram showing a configuration of the exclusive control system 1 in the embodiment of the present invention.

排他制御システム1は、複数の排他制御装置100、複数のホスト300、及び、資源400を含む。排他制御装置100は、本発明の情報処理装置の一実施形態である。   The exclusive control system 1 includes a plurality of exclusive control devices 100, a plurality of hosts 300, and resources 400. The exclusive control device 100 is an embodiment of the information processing device of the present invention.

各排他制御装置100は、複数のホスト300の各々とネットワーク等により接続される。また、各排他制御装置100は、複数のホスト300が共有する資源400と接続される。資源400は、例えば、HDD(Hard Disk Drive)やSSD(Solid State Drive)等のディスク装置である。また、資源400は、拡張メモリ等でもよい。   Each exclusive control device 100 is connected to each of a plurality of hosts 300 via a network or the like. Each exclusive control device 100 is connected to a resource 400 shared by a plurality of hosts 300. The resource 400 is a disk device such as an HDD (Hard Disk Drive) or an SSD (Solid State Drive). Further, the resource 400 may be an extended memory or the like.

複数のホスト300の各々は、複数の排他制御装置100のいずれかにコマンドを送信して、資源400へのアクセス(例えば、資源400上のデータの読み出し/書き込み)を行う。   Each of the plurality of hosts 300 transmits a command to any of the plurality of exclusive control devices 100 to access the resource 400 (for example, read / write data on the resource 400).

複数の排他制御装置100は、互いに連携して、ホスト300から資源400へのアクセスに係る排他制御(例えば、資源400上の同じデータに対する、複数ホスト300からの同時アクセスの制限)を行う。また、複数の排他制御装置100のいずれかに障害が発生した場合、ホスト300は、残りの排他制御装置100で運用が継続できるように、リカバリを行う。   The plurality of exclusive control devices 100 cooperate with each other to perform exclusive control related to access from the host 300 to the resource 400 (for example, restriction of simultaneous access from the multiple hosts 300 to the same data on the resource 400). Further, when a failure occurs in any of the plurality of exclusive control devices 100, the host 300 performs recovery so that the operation can be continued with the remaining exclusive control devices 100.

図2は、本発明の実施の形態における、排他制御装置100の構成を示すブロック図である。   FIG. 2 is a block diagram showing a configuration of the exclusive control device 100 in the embodiment of the present invention.

排他制御装置100は、インターバルタイマ110、スリープタイマ120、集計制御部130、インデックス記憶部131、及び、集計テーブル記憶部132を含む。また、排他制御装置100は、コマンド受信部140、重みテーブル記憶部142、最大コマンド数記憶部143、デフォルトコマンド数記憶部144、重み閾値記憶部145、及び、実行待ちキュー150を含む。さらに、排他制御装置100は、実行制御部160、実行カウンタ記憶部161、制御カウンタ記憶部162、バックグラウンド処理時間記憶部163、及び、処理部170を含む。   The exclusive control device 100 includes an interval timer 110, a sleep timer 120, a total control unit 130, an index storage unit 131, and a total table storage unit 132. The exclusive control device 100 includes a command receiving unit 140, a weight table storage unit 142, a maximum command number storage unit 143, a default command number storage unit 144, a weight threshold storage unit 145, and an execution waiting queue 150. Furthermore, the exclusive control device 100 includes an execution control unit 160, an execution counter storage unit 161, a control counter storage unit 162, a background processing time storage unit 163, and a processing unit 170.

インターバルタイマ110は、所定の時間間隔(インターバル)で、集計制御部130と実行制御部160とを起床させるタイマである。インターバルの長さは、例えば管理者等により、外部から設定されてもよい。本発明の実施の形態では、後述する、排他制御装置100で実行されたコマンド数(処理数)をカウントする周期(コマンドカウント周期)の長さや、重み累積カウンタの合計値を算出するための期間(重み合計期間)は、インターバルの回数をもとに設定される。   The interval timer 110 is a timer that wakes up the aggregation control unit 130 and the execution control unit 160 at a predetermined time interval (interval). The length of the interval may be set from the outside by an administrator or the like, for example. In the embodiment of the present invention, the period for calculating the number of commands executed by the exclusive control device 100 (the number of processes) (command count period), and the period for calculating the total value of the weight accumulation counter, which will be described later. The (total weight period) is set based on the number of intervals.

スリープタイマ120は、設定された時間後に、実行制御部160を起床させるタイマである。   The sleep timer 120 is a timer that wakes up the execution control unit 160 after a set time.

インデックス記憶部131は、現在インデックス231を記憶する。現在インデックス231は、集計テーブル232において、コマンドの重みを累積中である重み累積カウンタのインデックスを示す。   The index storage unit 131 stores the current index 231. The current index 231 indicates an index of a weight accumulation counter that is accumulating command weights in the aggregation table 232.

集計テーブル記憶部132は、集計テーブル232を記憶する。集計テーブル232は、インターバル毎の重み累積カウンタを記憶する。   The aggregation table storage unit 132 stores the aggregation table 232. The aggregation table 232 stores a weight accumulation counter for each interval.

図9は、本発明の実施の形態における、集計テーブル232の例を示す図である。図9の例では、集計テーブル232は、n個(nは、例えば、n≧2の整数)の重み累積カウンタからなる配列である。n個の重み累積カウンタは、サイクリックに使用される。各重み累積カウンタには、対応するインターバルにおける、コマンドの重みの累積値が設定される。   FIG. 9 is a diagram showing an example of the aggregation table 232 in the embodiment of the present invention. In the example of FIG. 9, the tabulation table 232 is an array including n weight accumulation counters (n is an integer where n ≧ 2, for example). The n weight accumulation counters are used cyclically. In each weight accumulation counter, a cumulative value of command weights in a corresponding interval is set.

集計制御部130は、インターバル毎に、現在インデックス231をインクリメント(1を加算)し、集計テーブル232における、現在インデックス231が示す重み累積カウンタを初期化する。なお、インクリメント後の現在インデックス231の値が、集計テーブル232の重み累積カウンタの数を超える場合、現在インデックス231の値は、集計テーブル232における、先頭の重み累積カウンタを示すように更新される。   The aggregation control unit 130 increments the current index 231 (adds 1) for each interval, and initializes the weight accumulation counter indicated by the current index 231 in the aggregation table 232. When the value of the current index 231 after the increment exceeds the number of weight accumulation counters in the aggregation table 232, the value of the current index 231 is updated to indicate the head weight accumulation counter in the aggregation table 232.

重みテーブル記憶部142は、重みテーブル242を記憶する。重みテーブル242は、各コマンドに係る処理が、排他制御装置100のCPUを占有する度合い、或いは、各コマンドに係る処理が、他の処理に与える影響の度合いを表す、重みを示す。   The weight table storage unit 142 stores a weight table 242. The weight table 242 indicates weights indicating the degree to which the process related to each command occupies the CPU of the exclusive control device 100 or the degree of influence the process related to each command has on other processes.

図10は、本発明の実施の形態における、重みテーブル242の例を示す図である。各コマンドの重みは、図17で示したような、各コマンドの特性や、CPU占有度、発生頻度をもとに決定される。重みテーブル242は、例えば、管理者等により、予め設定される。   FIG. 10 is a diagram showing an example of the weight table 242 in the embodiment of the present invention. The weight of each command is determined based on the characteristics of each command, CPU occupancy, and occurrence frequency as shown in FIG. The weight table 242 is set in advance by, for example, an administrator.

最大コマンド数記憶部143は、最大コマンド数243を記憶する。最大コマンド数243は、コマンドカウント周期におけるコマンド数(処理数)の上限を示す。最大コマンド数243は、上述のように、コマンド数制御部141により更新される。   The maximum command number storage unit 143 stores the maximum command number 243. The maximum command number 243 indicates the upper limit of the number of commands (number of processes) in the command count cycle. The maximum command number 243 is updated by the command number control unit 141 as described above.

デフォルトコマンド数記憶部144は、デフォルトコマンド数244を記憶する。デフォルトコマンド数244は、通常時に、最大コマンド数243に設定される値を示す。デフォルトコマンド数244は、排他制御装置100の処理能力(性能)等をもとに決定される。デフォルトコマンド数244は、例えば、管理者等により、予め設定される。   The default command number storage unit 144 stores a default command number 244. The default command number 244 indicates a value set to the maximum command number 243 at the normal time. The default command number 244 is determined based on the processing capability (performance) of the exclusive control device 100. The default command number 244 is preset by, for example, an administrator.

図11は、本発明の実施の形態における、デフォルトコマンド数244の例を示す図である。図11の例では、デフォルトコマンド数244に「18」が設定されている。   FIG. 11 is a diagram showing an example of the default command number 244 in the embodiment of the present invention. In the example of FIG. 11, “18” is set as the default command number 244.

重み閾値記憶部145は、重み閾値245を記憶する。重み閾値245は、最大コマンド数243をデフォルトコマンド数244より小さい値に制限するかどうかを判定するために用いられる。重み閾値245は、重み合計期間の重み累積カウンタの合計値と比較される。重み合計期間は、現在のインターバルより前の、所定数のインターバルの期間である。重み閾値245は、例えば、管理者等により、予め設定される。   The weight threshold storage unit 145 stores the weight threshold 245. The weight threshold 245 is used to determine whether to limit the maximum command number 243 to a value smaller than the default command number 244. The weight threshold value 245 is compared with the total value of the weight accumulation counter in the weight total period. The weight sum period is a period of a predetermined number of intervals before the current interval. The weight threshold value 245 is set in advance by an administrator or the like, for example.

図12は、本発明の実施の形態における、重み閾値245の例を示す図である。図12の例では、重み閾値245に「6」が設定されている。   FIG. 12 is a diagram showing an example of the weight threshold value 245 in the embodiment of the present invention. In the example of FIG. 12, “6” is set to the weight threshold value 245.

コマンド受信部140は、ホスト300から受信したコマンドを、実行待ちキュー150へキューイングし、実行制御部160を起床させる。   The command receiving unit 140 queues the command received from the host 300 to the execution waiting queue 150 and wakes up the execution control unit 160.

コマンド受信部140は、コマンド数制御部141(または、処理数制御部)を含む。コマンド数制御部141は、ホスト300から受信したコマンドの重みを重みテーブル242から抽出し、現在インデックス231が示す重み累積カウンタに加算する。また、コマンド数制御部141は、重み合計期間の重み累積カウンタの合計値を算出し、算出した合計値と重み閾値245とを比較する。合計値が重み閾値245以上の場合、コマンド数制御部141は、最大コマンド数243を、デフォルトコマンド数244の半分に制限する。それ以外の場合、コマンド数制御部141は、最大コマンド数243にデフォルトコマンド数244を設定する。   The command receiving unit 140 includes a command number control unit 141 (or a processing number control unit). The command number control unit 141 extracts the weight of the command received from the host 300 from the weight table 242 and adds it to the weight accumulation counter indicated by the current index 231. Further, the command number control unit 141 calculates the total value of the weight accumulation counter during the total weight period, and compares the calculated total value with the weight threshold value 245. When the total value is greater than or equal to the weight threshold 245, the command number control unit 141 limits the maximum command number 243 to half of the default command number 244. In other cases, the command number control unit 141 sets the default command number 244 as the maximum command number 243.

実行待ちキュー150は、排他制御装置100が実行すべきコマンドをFIFO(First In, First Out)形式で記憶する。   The waiting queue 150 stores commands to be executed by the exclusive control device 100 in a FIFO (First In, First Out) format.

実行カウンタ記憶部161は、実行カウンタ261を記憶する。実行カウンタ261は、コマンドカウント周期において実行されたコマンド数(処理数)を示す。   The execution counter storage unit 161 stores an execution counter 261. The execution counter 261 indicates the number of commands (number of processes) executed in the command count cycle.

制御カウンタ記憶部162は、制御カウンタ262を記憶する。制御カウンタ262は、インターバルの回数を示す。   The control counter storage unit 162 stores a control counter 262. The control counter 262 indicates the number of intervals.

バックグラウンド処理時間記憶部163は、バックグラウンド処理時間263を記憶する。バックグラウンド処理時間263は、各コマンドカウント周期において、コマンドに係る処理以外の、バックグラウンド処理(例えば、排他制御装置100の障害監視、性能監視等)を実行するために必要な時間を示す。バックグラウンド処理時間263は、例えば、管理者等により設定される。   The background processing time storage unit 163 stores the background processing time 263. The background processing time 263 indicates a time required for executing background processing (for example, fault monitoring, performance monitoring, etc. of the exclusive control device 100) other than processing related to the command in each command count cycle. The background processing time 263 is set by an administrator or the like, for example.

実行制御部160は、実行待ちキュー150にキューイングされたコマンドの実行を、処理部170に指示する。   The execution control unit 160 instructs the processing unit 170 to execute a command queued in the execution waiting queue 150.

実行制御部160は、実行カウンタ261が最大コマンド数243に達していなければ、実行待ちキュー150からコマンドを取得し、当該コマンドの実行を、処理部170に指示する。ここで、実行制御部160は、実行カウンタ261をインクリメント(1を加算)する。また、実行制御部160は、実行カウンタ261が最大コマンド数243に達していれば、バックグラウンド処理時間263経過後に、実行待ちキュー150からコマンドを取得し、当該コマンドの実行を、処理部170に指示する。   If the execution counter 261 has not reached the maximum command number 243, the execution control unit 160 acquires a command from the execution waiting queue 150 and instructs the processing unit 170 to execute the command. Here, the execution control unit 160 increments the execution counter 261 (adds 1). If the execution counter 261 has reached the maximum command number 243, the execution control unit 160 acquires a command from the execution queue 150 after the background processing time 263 has elapsed, and sends the execution of the command to the processing unit 170. Instruct.

さらに、実行制御部160は、インターバル毎に、制御カウンタ262をインクリメント(1を加算)する。実行制御部160は、制御カウンタ262をもとに、コマンドカウント周期の経過を検出し、コマンドカウント周期毎に実行カウンタ261をリセットする。   Further, the execution control unit 160 increments (adds 1) the control counter 262 at every interval. The execution control unit 160 detects the elapse of the command count cycle based on the control counter 262, and resets the execution counter 261 every command count cycle.

処理部170は、実行制御部160から指示されたコマンドに係る処理(排他制御処理)を実行し、実行結果をホスト300に送信する。また、処理部170は、当該コマンド(または、排他制御に必要なコマンド)を、他の排他制御装置100でも実行する必要がある場合、当該コマンド(または、当該排他制御に必要なコマンド)を当該他の排他制御装置100の実行待ちキュー150へ転送する。また、処理部170は、他の排他制御装置100から転送されたコマンドに係る処理を実行する。   The processing unit 170 executes processing (exclusive control processing) related to the command instructed from the execution control unit 160 and transmits the execution result to the host 300. In addition, when the processing unit 170 needs to execute the command (or a command necessary for exclusive control) also in another exclusive control device 100, the processing unit 170 executes the command (or a command necessary for the exclusive control). Transfer to the waiting queue 150 of another exclusive control device 100. In addition, the processing unit 170 executes processing related to the command transferred from the other exclusive control device 100.

さらに、処理部170は、実行制御部160からコマンドの実行を指示されていない場合(実行すべきコマンドがない場合)、所定のバックグラウンド処理を実行する。   Furthermore, when the execution control unit 160 does not instruct the execution of a command (when there is no command to be executed), the processing unit 170 executes a predetermined background process.

なお、排他制御装置100は、CPUとプログラムを記憶した記憶媒体を含み、プログラムに基づく制御によって動作するコンピュータであってもよい。   Note that the exclusive control device 100 may be a computer that includes a CPU and a storage medium that stores a program and that operates by control based on the program.

図4は、本発明の実施の形態における、コンピュータにより実現された排他制御装置100の構成を示すブロック図である。   FIG. 4 is a block diagram showing a configuration of the exclusive control device 100 realized by a computer in the embodiment of the present invention.

排他制御装置100は、CPU101、ハードディスクやメモリ等の記憶手段(記憶媒体)102、他の装置等とデータ通信を行う通信手段103、キーボード等の入力手段104、及び、ディスプレイ等の出力手段105を含む。CPU101は、インターバルタイマ110、スリープタイマ120、集計制御部130、コマンド受信部140、実行制御部160、及び、処理部170の機能を実現するためのコンピュータプログラムを実行する。記憶手段102は、インデックス記憶部131、集計テーブル記憶部132、重みテーブル記憶部142、最大コマンド数記憶部143、デフォルトコマンド数記憶部144、及び、重み閾値記憶部145のデータを記憶する。記憶手段102は、さらに、実行待ちキュー150、実行カウンタ記憶部161、制御カウンタ記憶部162、バックグラウンド処理時間記憶部163のデータを記憶する。通信手段103は、ホスト300からコマンドを受信し、コマンドの実行結果をホスト300に送信する。また、また、通信手段103は、コマンドに従って、資源400へのデータの書き込み、及び、資源400からのデータの読み出しを行う。入力手段104は、管理者等から、例えば、重みテーブル242、デフォルトコマンド数244、重み閾値245、バックグラウンド処理時間263等の各種設定を受け付ける。出力手段105は、管理者等へ、例えば、各種設定の結果を出力する。   The exclusive control device 100 includes a CPU 101, a storage means (storage medium) 102 such as a hard disk and a memory, a communication means 103 that performs data communication with other devices, an input means 104 such as a keyboard, and an output means 105 such as a display. Including. The CPU 101 executes a computer program for realizing the functions of the interval timer 110, the sleep timer 120, the aggregation control unit 130, the command reception unit 140, the execution control unit 160, and the processing unit 170. The storage unit 102 stores data of the index storage unit 131, the total table storage unit 132, the weight table storage unit 142, the maximum command number storage unit 143, the default command number storage unit 144, and the weight threshold storage unit 145. The storage unit 102 further stores data of the execution waiting queue 150, the execution counter storage unit 161, the control counter storage unit 162, and the background processing time storage unit 163. The communication unit 103 receives a command from the host 300 and transmits a command execution result to the host 300. In addition, the communication unit 103 writes data to the resource 400 and reads data from the resource 400 in accordance with commands. The input unit 104 receives various settings such as a weight table 242, a default command number 244, a weight threshold value 245, and a background processing time 263 from an administrator or the like. The output unit 105 outputs, for example, the results of various settings to an administrator or the like.

次に、本発明の実施の形態の動作を説明する。   Next, the operation of the embodiment of the present invention will be described.

はじめに、本発明の実施の形態における、重み集計処理について説明する。   First, the weight aggregation process in the embodiment of the present invention will be described.

図5は、本発明の実施の形態における、重み集計処理を示すフローチャートである。   FIG. 5 is a flowchart showing the weight totaling process in the embodiment of the present invention.

はじめに、集計制御部130は、インターバルタイマ110により起床されると(ステップS101)、現在インデックス231をインクリメントする(ステップS102)。   First, when the totaling control unit 130 is woken up by the interval timer 110 (step S101), it increments the current index 231 (step S102).

集計制御部130は、集計テーブル232における、現在インデックス231が示す重み累積カウンタを初期化する(ステップS103)。   The aggregation control unit 130 initializes a weight accumulation counter indicated by the current index 231 in the aggregation table 232 (step S103).

以降、ステップS101からの処理が繰り返される。   Thereafter, the processing from step S101 is repeated.

コマンド受信部140は、現在インデックス231が示す重み累積カウンタに、ホスト300から受信したコマンドの重みを加算する。現在インデックス231は、インターバルごとにインクリメントされるため、インターバルごとのコマンドの重みの累積値が、各重み累積カウンタに、順次、保存される。   The command receiving unit 140 adds the weight of the command received from the host 300 to the weight accumulation counter indicated by the current index 231. Since the current index 231 is incremented for each interval, the command weight cumulative value for each interval is sequentially stored in each weight cumulative counter.

次に、本発明の実施の形態における、コマンド受信処理について説明する。   Next, command reception processing in the embodiment of the present invention will be described.

図6は、本発明の実施の形態における、コマンド受信処理を示すフローチャートである。   FIG. 6 is a flowchart showing command reception processing in the embodiment of the present invention.

はじめに、コマンド受信部140が、ホスト300からコマンドを受信すると(ステップS201)、コマンド数制御部141は、重みテーブル242から、受信したコマンドの重みを抽出する(ステップS202)。コマンド数制御部141は、抽出した重みを、現在インデックス231が示す重み累積カウンタに加算する(ステップS203)。   First, when the command receiving unit 140 receives a command from the host 300 (step S201), the command number control unit 141 extracts the weight of the received command from the weight table 242 (step S202). The command number control unit 141 adds the extracted weight to the weight accumulation counter indicated by the current index 231 (step S203).

コマンド数制御部141は、重み合計期間の重み累積カウンタの値の合計値を算出する(ステップS204)。   The command number control unit 141 calculates the total value of the weight accumulation counter values in the total weight period (step S204).

ここで、重み合計期間の長さは、例えば、インターバルの回数m(mは、例えば、1≦m<nの整数)で指定される。この場合、コマンド数制御部141は、現在インデックス231が示す重み累積カウンタより前のm個の重み累積カウンタの合計値を算出する。   Here, the length of the total weight period is specified by, for example, the number of intervals m (m is an integer of 1 ≦ m <n), for example. In this case, the command number control unit 141 calculates a total value of m weight accumulation counters before the weight accumulation counter indicated by the current index 231.

コマンド数制御部141は、算出した合計値と重み閾値245とを比較する(ステップS205)。合計値が重み閾値245以上の場合(ステップS205/Y)、コマンド数制御部141は、最大コマンド数243に、デフォルトコマンド数244の半分の値を設定する(ステップS206)。合計値が重み閾値245未満の場合(ステップS205/N)、コマンド数制御部141は、最大コマンド数243にデフォルトコマンド数244の値を設定する(ステップS207)。   The command number control unit 141 compares the calculated total value with the weight threshold value 245 (step S205). When the total value is greater than or equal to the weight threshold value 245 (step S205 / Y), the command number control unit 141 sets the half of the default command number 244 to the maximum command number 243 (step S206). When the total value is less than the weight threshold value 245 (step S205 / N), the command number control unit 141 sets the value of the default command number 244 as the maximum command number 243 (step S207).

コマンド受信部140は、受信したコマンドを実行待ちキュー150へキューイングし(ステップS208)、実行制御部160を起床させる(ステップS209)。   The command receiving unit 140 queues the received command to the execution waiting queue 150 (step S208), and wakes up the execution control unit 160 (step S209).

以降、ステップS201からの処理が繰り返される。   Thereafter, the processing from step S201 is repeated.

次に、本発明の実施の形態における、コマンド実行制御処理について説明する。   Next, the command execution control process in the embodiment of the present invention will be described.

図7は、本発明の実施の形態における、コマンド実行制御処理を示すフローチャートである。   FIG. 7 is a flowchart showing command execution control processing in the embodiment of the present invention.

はじめに、実行制御部160は、コマンド受信部140により起床されると(ステップS301、S302/Y)、実行待ちキュー150にコマンドがあるかどうかを確認する(ステップS303)。   First, when the execution control unit 160 is woken up by the command reception unit 140 (steps S301 and S302 / Y), the execution control unit 160 checks whether there is a command in the execution waiting queue 150 (step S303).

ステップS303で、コマンドがない場合(ステップS303/N)、ステップS301からの処理が繰り返される。   If there is no command in step S303 (step S303 / N), the processing from step S301 is repeated.

一方、ステップS303で、コマンドがある場合(ステップS303/Y)、実行制御部160は、実行カウンタ261が最大コマンド数243未満かどうかを判定する(ステップS304)。   On the other hand, if there is a command in step S303 (step S303 / Y), the execution control unit 160 determines whether or not the execution counter 261 is less than the maximum command number 243 (step S304).

ステップS304で、最大コマンド数243未満の場合(ステップS304/Y)、実行制御部160は、実行カウンタ261をインクリメントする(ステップS305)。そして、実行制御部160は、実行待ちキュー150からコマンドを1つ取得し(ステップS306)、処理部170に、当該コマンドの実行を指示する(ステップS307)。   In step S304, when the maximum number of commands is less than 243 (step S304 / Y), the execution control unit 160 increments the execution counter 261 (step S305). Then, the execution control unit 160 acquires one command from the execution waiting queue 150 (step S306), and instructs the processing unit 170 to execute the command (step S307).

以降、ステップS303からの処理が繰り返される。   Thereafter, the processing from step S303 is repeated.

一方、ステップS304で、最大コマンド数243以上の場合(ステップS304/N)、実行制御部160は、バックグラウンド処理時間263をスリープタイマ120に設定し、処理部170に対するコマンドの実行指示を中断する(スリープする)。   On the other hand, if the maximum number of commands is 243 or more in step S304 (step S304 / N), the execution control unit 160 sets the background processing time 263 in the sleep timer 120 and interrupts the command execution instruction to the processing unit 170. (Sleep).

これにより、コマンドカウント周期に実行されたコマンドの数が、最大コマンド数243に達した場合、処理部170において、バックグラウンド処理が実行される。   As a result, when the number of commands executed in the command count cycle reaches the maximum command number 243, background processing is executed in the processing unit 170.

実行制御部160は、スリープタイマ120より起床されると(ステップS301、S302/N、S309/N)、実行カウンタ261をリセットし(ステップS312)、ステップS303からの処理を実行する。   When the execution control unit 160 gets up from the sleep timer 120 (steps S301, S302 / N, S309 / N), the execution control unit 160 resets the execution counter 261 (step S312), and executes the processing from step S303.

これにより、処理部170において、バックグラウンド処理が実行された後で、最大コマンド数243を超えたコマンドを実行させることができる。   Thereby, in the processing unit 170, after the background process is executed, it is possible to execute a command exceeding the maximum command number 243.

また、実行制御部160は、インターバルタイマ110より起床されると(ステップS301、S302/N、S309/Y)、制御カウンタ262をインクリメントする(ステップS310)。そして、実行制御部160は、制御カウンタ262をもとに、コマンドカウント周期が経過したかどうかを判定する(ステップS311)。   Further, when the execution control unit 160 gets up from the interval timer 110 (steps S301, S302 / N, S309 / Y), the execution control unit 160 increments the control counter 262 (step S310). Then, the execution control unit 160 determines whether or not the command count cycle has elapsed based on the control counter 262 (step S311).

ここで、コマンドカウント周期の長さは、例えば、インターバルの回数x(xは、例えば、1以上の整数)で指定される。この場合、実行制御部160は、制御カウンタ262がxの整数倍を示した場合に、コマンドカウント周期が経過したと判定する。   Here, the length of the command count cycle is specified by, for example, the number of intervals x (x is an integer of 1 or more, for example). In this case, the execution control unit 160 determines that the command count cycle has elapsed when the control counter 262 indicates an integral multiple of x.

ステップS311で、コマンドカウント周期が経過した場合(ステップS311/Y)、実行制御部160は、実行カウンタ261をリセットし(ステップS312)、ステップS303からの処理を実行する。   In step S311, when the command count cycle has elapsed (step S311 / Y), the execution control unit 160 resets the execution counter 261 (step S312), and executes the processing from step S303.

これにより、コマンドカウント周期ごとに、実行カウンタ261はリセットされる。   As a result, the execution counter 261 is reset every command count cycle.

一方、ステップS311で、コマンドカウント周期が経過していない場合(ステップS311/N)、ステップS301からの処理が繰り返される。   On the other hand, if the command count cycle has not elapsed in step S311 (step S311 / N), the processing from step S301 is repeated.

次に、本発明の実施の形態における、コマンド実行処理について説明する。   Next, command execution processing in the embodiment of the present invention will be described.

図8は、本発明の実施の形態における、コマンド実行処理を示すフローチャートである。   FIG. 8 is a flowchart showing command execution processing in the embodiment of the present invention.

処理部170は、実行制御部160による、コマンドの実行指示により起床され(ステップS401)、コマンドに係る処理(排他制御処理)を実行する(ステップS402)。ここで、処理部170は、例えば、コマンドにより指定された、資源400上のデータへのアクセス(読み出し/書き込み)を、同じデータに対する複数ホスト300からの同時アクセスが発生しないように、実行する。   The processing unit 170 is woken up by a command execution instruction from the execution control unit 160 (step S401), and executes processing related to the command (exclusive control processing) (step S402). Here, the processing unit 170 executes, for example, access (read / write) to the data on the resource 400 specified by the command so that simultaneous access from the plurality of hosts 300 to the same data does not occur.

処理部170は、コマンドを他の排他制御装置100でも実行する必要があるかどうかを判定する(ステップS403)。   The processing unit 170 determines whether the command needs to be executed by another exclusive control device 100 (step S403).

ステップS403で実行する必要がある場合(ステップS403/Y)、処理部170は、コマンドを、当該他の排他制御装置100の実行待ちキュー150にキューイングする(ステップS404)。   When it is necessary to execute in step S403 (step S403 / Y), the processing unit 170 queues the command in the execution waiting queue 150 of the other exclusive control device 100 (step S404).

処理部170は、実行したコマンドの処理結果を、ホスト300へ送信する(ステップS405)。ここで、処理部170は、例えば、資源400上のデータへのアクセス結果(読み出しデータ/書き込み結果)を、ホスト300へ送信する。   The processing unit 170 transmits the processing result of the executed command to the host 300 (step S405). Here, for example, the processing unit 170 transmits an access result (read data / write result) to data on the resource 400 to the host 300.

以降、ステップS401からの処理が繰り返し、実行される。   Thereafter, the processing from step S401 is repeated and executed.

次に、本発明の実施の形態の動作の具体例を説明する。   Next, a specific example of the operation of the embodiment of the present invention will be described.

図13〜図15は、本発明の実施の形態における、コマンドに係る処理、及び、バックグラウンド処理の実行例を示す図である。   FIGS. 13 to 15 are diagrams illustrating execution examples of processing related to commands and background processing according to the embodiment of the present invention.

ここでは、重みテーブル記憶部142に、図10の重みテーブル242、デフォルトコマンド数記憶部144に、図11のデフォルトコマンド数244、重み閾値記憶部145に、図12の重み閾値245が、それぞれ設定されていると仮定する。また、コマンドカウント周期の長さはインターバル10回分(x=10)、集計テーブル232における重み累積カウンタの数は4(n=4)、重み合計期間の長さはインターバル2回分(m=2)であると仮定する。   Here, the weight table storage unit 142 is set with the weight table 242 of FIG. 10, the default command number storage unit 144 is set with the default command number 244 of FIG. 11, and the weight threshold storage unit 145 is set with the weight threshold value 245 of FIG. Assuming that The length of the command count cycle is 10 intervals (x = 10), the number of weight accumulation counters in the aggregation table 232 is 4 (n = 4), and the length of the total weight period is 2 intervals (m = 2). Assume that

また、図10の重みテーブル242におけるコマンド「B」、「C」の処理に必要な時間(CPUを占有する時間)は、コマンド「A」の処理に必要な時間の、それぞれ、2倍、3倍であると仮定する。さらに、バックグラウンド処理時間263には、コマンド「A」の処理に必要な時間の6倍が設定されていると仮定する。   Also, the time required for processing the commands “B” and “C” in the weight table 242 in FIG. 10 (the time that occupies the CPU) is twice as long as the time required for processing the command “A”. Assume that it is double. Furthermore, it is assumed that the background processing time 263 is set to 6 times the time necessary for processing the command “A”.

また、ここでは。制御カウンタ262が「j」を示すインターバルを、インターバル「j」のように記述する。   Also here. An interval where the control counter 262 indicates “j” is described as an interval “j”.

図13〜図15に示すように、実行制御部160は、インターバル毎に、制御カウンタ262をインクリメントする。また、実行制御部160は、コマンドカウント周期毎(制御カウンタ262の値が「10」の倍数(10、20、…)のとき)に、実行カウンタ261をリセットする。集計制御部130は、インターバル毎に、現在インデックス231を「0」〜「3」の範囲でインクリメントする。   As illustrated in FIGS. 13 to 15, the execution control unit 160 increments the control counter 262 for each interval. Further, the execution control unit 160 resets the execution counter 261 every command count cycle (when the value of the control counter 262 is a multiple of “10” (10, 20,...)). The aggregation control unit 130 increments the current index 231 in the range of “0” to “3” for each interval.

コマンド受信部140は、ホスト300から受信したコマンド(「A」、「B」、「C」)を、実行待ちキュー150にキューイングする。ここで、コマンド数制御部141は、インターバル毎に、コマンド(「A」、「B」、「C」)に対する重み(それぞれ、「1」、「2」、「3」)を、現在インデックス231により示される重み累積カウンタ(インデックス「0」〜「3」)に加算する。また、コマンド数制御部141は、現在のインターバルの前のインターバルから、前方の2つのインターバルの重み累積カウンタの合計値を算出する。   The command receiving unit 140 queues the commands (“A”, “B”, “C”) received from the host 300 in the execution waiting queue 150. Here, the command number control unit 141 assigns the weight (“1”, “2”, “3”) for the command (“A”, “B”, “C”) to the current index 231 for each interval. Is added to the weight accumulation counter (index “0” to “3”). Further, the command number control unit 141 calculates the total value of the weight accumulation counters of the two preceding intervals from the interval before the current interval.

重み累積カウンタの合計値が重み閾値245「6」未満の場合、コマンド数制御部141は、最大コマンド数243にデフォルトコマンド数244「18」を設定する。重み累積カウンタの合計値が重み閾値245「6」以上の場合、コマンド数制御部141は、最大コマンド数243にデフォルトコマンド数244の半分である「9」を設定する。   When the total value of the weight accumulation counter is less than the weight threshold value 245 “6”, the command number control unit 141 sets the default command number 244 “18” as the maximum command number 243. When the total value of the weight accumulation counter is equal to or greater than the weight threshold 245 “6”, the command number control unit 141 sets “9”, which is half the default command number 244, to the maximum command number 243.

例えば、最初のコマンドカウント周期(図13、インターバル「0」〜「9」)では、重みの小さなコマンド「A」や「B」が、散発的に、ホスト300から受信される。この場合、各インターバルで算出される重み累積カウンタの合計値は「6」未満であるため、最大コマンド数243には「18」が設定される。   For example, in the first command count cycle (FIG. 13, intervals “0” to “9”), commands “A” and “B” with small weights are sporadically received from the host 300. In this case, since the total value of the weight accumulation counter calculated in each interval is less than “6”, “18” is set as the maximum command number 243.

また、次のコマンドカウント周期(図14、インターバル「10」〜「19」)では、重みの小さなコマンド「A」が、集中的に、ホスト300から受信される。この場合も、各インターバルで算出される重み累積カウンタの合計値は「6」未満であるため、最大コマンド数243には「18」が設定される。   Also, in the next command count cycle (FIG. 14, intervals “10” to “19”), the command “A” having a small weight is received from the host 300 in a concentrated manner. Also in this case, since the total value of the weight accumulation counter calculated in each interval is less than “6”, “18” is set to the maximum command number 243.

さらに、次のコマンドカウント周期(図15、インターバル「20」〜「29」)では、重みの小さなコマンド「C」が、連続的に、ホスト300から受信される。この場合、インターバル「25」「26」において、重み累積カウンタの合計値「6」が算出されるため、最大コマンド数243は「9」に制限される。   Furthermore, in the next command count cycle (FIG. 15, intervals “20” to “29”), a command “C” having a small weight is continuously received from the host 300. In this case, since the total value “6” of the weight accumulation counter is calculated in the intervals “25” and “26”, the maximum command number 243 is limited to “9”.

実行制御部160は、実行カウンタ261の値が最大コマンド数243(「18」または「9」)未満であれば、実行待ちキュー150にキューイングされたコマンドの実行を、処理部170に指示し、実行カウンタ261をインクリメントする。また、実行制御部160は、実行カウンタ261の値が最大コマンド数243(「18」または「9」)以上であれば、バックグラウンド処理時間263の間、処理部170に対するコマンドの実行指示を中断する。処理部170は、実行制御部160により指示されているコマンドが無い場合、バックグラウンド処理を実行する。   If the value of the execution counter 261 is less than the maximum command number 243 (“18” or “9”), the execution control unit 160 instructs the processing unit 170 to execute the command queued in the execution queue 150. The execution counter 261 is incremented. If the value of the execution counter 261 is equal to or greater than the maximum command number 243 (“18” or “9”), the execution control unit 160 interrupts the command execution instruction to the processing unit 170 during the background processing time 263. To do. If there is no command instructed by the execution control unit 160, the processing unit 170 executes background processing.

例えば、最初のコマンドカウント周期(図13、インターバル「0」〜「9」)では、実行カウンタ261の値は「18」に達していないため、各コマンドの実行指示は中断されない。処理部170では、各コマンドに係る処理が実行されるとともに、コマンドが無いタイミングで、バックグラウンド処理に必要な時間(バックグラウンド処理時間263)が確保され、バックグラウンド処理が実行される。   For example, in the first command count cycle (interval “0” to “9” in FIG. 13), the value of the execution counter 261 has not reached “18”, so the execution instruction of each command is not interrupted. In the processing unit 170, processing related to each command is executed, and at the timing when there is no command, a time required for background processing (background processing time 263) is secured, and background processing is executed.

また、次のコマンドカウント周期(図14、インターバル「10」〜「19」)では、インターバル「17」の時刻「t1」で、実行カウンタ261の値が「18」に達している。このため、時刻「t1」〜「t2」のバックグラウンド処理時間263の間、処理部170に対するコマンドの実行指示が中断される。これにより、処理部170では、時刻「t1」より前のコマンドが無いタイミング、及び、時刻「t1」〜「t2」の間で、バックグラウンド処理時間263が確保され、バックグラウンド処理が実行される。そして、インターバル「19」の時刻「t2」で、処理部170に対するコマンドの実行指示が再開される。   In the next command count cycle (FIG. 14, intervals “10” to “19”), the value of the execution counter 261 reaches “18” at time “t1” of the interval “17”. For this reason, during the background processing time 263 from time “t1” to “t2”, the command execution instruction to the processing unit 170 is interrupted. As a result, the processing unit 170 secures the background processing time 263 between the timing when there is no command before the time “t1” and the time “t1” to “t2”, and the background processing is executed. . Then, at time “t2” in the interval “19”, the command execution instruction to the processing unit 170 is resumed.

また、次のコマンドカウント周期(図15、インターバル「20」〜「29」)では、インターバル「26」の時刻「t3」で、実行カウンタ261の値が、制限された値「9」に達している。このため、時刻「t3」〜「t4」のバックグラウンド処理時間263の間、処理部170に対するコマンドの実行指示が中断される。これにより、処理部170では、時刻「t3」より前のコマンドが無いタイミング、及び、時刻「t3」〜「t4」の間で、バックグラウンド処理時間263が確保され、バックグラウンド処理が実行される。そして、インターバル「28」の時刻「t4」で、処理部170に対するコマンドの実行指示が再開される。   In the next command count cycle (FIG. 15, intervals “20” to “29”), the value of the execution counter 261 reaches the limited value “9” at the time “t3” of the interval “26”. Yes. For this reason, the command execution instruction to the processing unit 170 is interrupted during the background processing time 263 from time “t3” to “t4”. As a result, the processing unit 170 secures the background processing time 263 between the timing when there is no command before the time “t3” and the time “t3” to “t4”, and the background processing is executed. . Then, at time “t4” of the interval “28”, the command execution instruction to the processing unit 170 is resumed.

以上により、本発明の実施の形態の動作が完了する。   Thus, the operation of the embodiment of the present invention is completed.

なお、本発明の実施の形態では、重み累積カウンタの合計値が重み閾値245以上の場合に、実行されるコマンドの数を制限するために、最大コマンド数243に、デフォルトコマンド数244よりも小さい値を設定した。しかしながら、これに限らず、最大コマンド数243を変える代わりに、コマンドを実行したときに実行カウンタ261に加算する値を変えてもよい。この場合、例えば、上述のステップS205で、合計値が重み閾値245以上の場合、ステップS206で、コマンド数制御部141は、カウント係数に2を設定する。また、上述のステップS205で、合計値が重み閾値245未満の場合、ステップS206で、コマンド数制御部141は、カウント係数に1を設定する。そして、上述のステップS305で、実行制御部160は、実行カウンタ261にカウント係数を加算する。   In the embodiment of the present invention, when the total value of the weight accumulation counter is equal to or greater than the weight threshold value 245, the maximum command number 243 is smaller than the default command number 244 in order to limit the number of commands to be executed. A value was set. However, the present invention is not limited to this, and instead of changing the maximum command number 243, the value added to the execution counter 261 when the command is executed may be changed. In this case, for example, if the total value is greater than or equal to the weight threshold value 245 in step S205 described above, the command number control unit 141 sets 2 to the count coefficient in step S206. If the total value is less than the weight threshold 245 in step S205 described above, the command number control unit 141 sets 1 to the count coefficient in step S206. In step S305 described above, the execution control unit 160 adds the count coefficient to the execution counter 261.

また、本発明の実施の形態では、重み累積カウンタの合計値が重み閾値245以上の場合に、最大コマンド数243に、デフォルトコマンド数244の半分の値を設定した。しかしながら、これに限らず、合計値の範囲に対して設定された、複数のレベルに応じたコマンド数を、最大コマンド数243に設定してもよい。   In the embodiment of the present invention, when the total value of the weight accumulation counter is equal to or greater than the weight threshold value 245, the maximum command number 243 is set to a value half of the default command number 244. However, the present invention is not limited to this, and the number of commands corresponding to a plurality of levels set for the total value range may be set as the maximum command number 243.

次に、本発明の実施の形態の特徴的な構成を説明する。図1は、本発明の実施の形態の特徴的な構成を示すブロック図である。   Next, a characteristic configuration of the embodiment of the present invention will be described. FIG. 1 is a block diagram showing a characteristic configuration of an embodiment of the present invention.

排他制御装置100(情報処理装置)は、実行制御部160、及び、コマンド数制御部141(処理数制御部)を含む。実行制御部160は、コマンドカウント周期(所定長の周期)毎の処理部170により実行されるコマンド(処理)の数が、最大コマンド数243(最大処理数)以下となるように、要求されたコマンド(処理)を処理部170に実行させる。コマンド数制御部141は、要求されたコマンド(処理)の重みの累積値に応じて、最大コマンド数243(最大処理数)を設定する。   The exclusive control device 100 (information processing device) includes an execution control unit 160 and a command number control unit 141 (processing number control unit). The execution control unit 160 is requested so that the number of commands (processing) executed by the processing unit 170 for each command count cycle (cycle of a predetermined length) is equal to or less than the maximum command number 243 (maximum processing number). Causes the processing unit 170 to execute a command (processing). The command number control unit 141 sets the maximum command number 243 (maximum processing number) according to the accumulated value of the weight of the requested command (processing).

本発明の実施の形態によれば、複数種類のコマンドが実行される場合でも、バックグラウンド処理の実行停止を防ぐことができる。その理由は、コマンド数制御部141が、要求されたコマンドの重みの累積値に応じて、最大コマンド数243を設定するためである。   According to the embodiment of the present invention, it is possible to prevent the background process from being stopped even when a plurality of types of commands are executed. The reason is that the command number control unit 141 sets the maximum command number 243 according to the accumulated value of the requested command weights.

これにより、例えば、コマンド数は少ないものの、CPU占有率が高いコマンドがある期間に連続して発生した場合でも、実行するコマンドの数が制限され、バックグラウンド処理を実行できる。   Thus, for example, even when commands having a small number of commands but having a high CPU occupancy are generated continuously during a certain period, the number of commands to be executed is limited, and background processing can be executed.

また、図16に示すように、周期毎に実行するコマンドの数を制限する技術では、ある周期でコマンドが多発し、コマンドの実行が中断された場合、中断されたコマンドのTAT(Turn Around Time)が増大(間延び)するという問題があった。   Also, as shown in FIG. 16, in the technique for limiting the number of commands executed for each cycle, when commands occur frequently in a certain cycle and the command execution is interrupted, the TAT (Turn Around Time) of the interrupted command is interrupted. ) Increases (extends).

本発明の実施の形態によれば、実行が中断されたコマンドのTATが増大することを防ぐことができる。その理由は、実行したコマンドの数が最大コマンド数243に達した場合でも、バックグラウンド処理時間263経過後に、中断されたコマンドを処理部170に実行させるためである。   According to the embodiment of the present invention, it is possible to prevent an increase in TAT of a command whose execution has been interrupted. The reason is that, even when the number of executed commands reaches the maximum command number 243, the interrupted command is executed by the processing unit 170 after the background processing time 263 has elapsed.

これにより、ある周期において、実行したコマンドの数が上限に達した場合でも、図16のように次の周期の開始を待つことなく、バックグラウンド処理終了後、当該周期の残りの時間に、中断されたコマンドを実行できる。このため、中断されたコマンドのTATの増大は、最小限に抑えられる。   As a result, even if the number of executed commands reaches the upper limit in a certain cycle, the program is interrupted at the remaining time of the cycle after the background processing is completed without waiting for the start of the next cycle as shown in FIG. Command can be executed. For this reason, the increase in the TAT of the interrupted command is minimized.

また、本発明の実施の形態によれば、複数の排他制御装置を用いて処理を分散するシステムで行われる、排他制御装置の故障に伴うリカバリにおいて、ホストからのリカバリの開始、終了の通知や、排他制御装置における誤動作を防ぐための対処が不要である。その理由は、リカバリにおいてCPU占有率の高い(重みの大きい)コマンドが連続して発行された場合の最大コマンド数243の制限、及び、リカバリ終了後の最大コマンド数243の制限解除が、コマンド数制御部141により動的に実行されるためである。   Further, according to the embodiment of the present invention, in recovery accompanying a failure of an exclusive control device performed in a system that distributes processing using a plurality of exclusive control devices, recovery start and end notifications from the host Therefore, no countermeasure is required to prevent malfunction in the exclusive control device. The reason is that the limitation on the maximum command number 243 when a command having a high CPU occupancy rate (high weight) is continuously issued in the recovery, and the limitation release on the maximum command number 243 after the recovery ends are the number of commands. This is because it is dynamically executed by the control unit 141.

以上、実施形態を参照して本願発明を説明したが、本願発明は上記実施形態に限定されるものではない。本願発明の構成や詳細には、本願発明のスコープ内で当業者が理解し得る様々な変更をすることができる。   While the present invention has been described with reference to the embodiments, the present invention is not limited to the above embodiments. Various changes that can be understood by those skilled in the art can be made to the configuration and details of the present invention within the scope of the present invention.

例えば、本発明の実施の形態では、排他制御システム1に含まれる複数の排他制御装置100が、連携して、ホスト300から資源400へのアクセスに係る排他制御を行う場合を例に説明した。しかしながら、排他制御装置100が、複数種類のコマンドとバックグラウンド処理とを行う装置であれば、排他制御システム1は、1つの排他制御装置100により構成されていてもよい。   For example, in the embodiment of the present invention, the case where a plurality of exclusive control devices 100 included in the exclusive control system 1 perform exclusive control related to access from the host 300 to the resource 400 has been described as an example. However, if the exclusive control device 100 is a device that performs a plurality of types of commands and background processing, the exclusive control system 1 may be configured by a single exclusive control device 100.

また、本発明の実施の形態では、情報処理装置が、ホスト300から資源400へのアクセスに係る排他制御を行う排他制御装置100である場合を例に説明した。しかしながら、受信したコマンドや発生したイベントに応じた複数種類の処理とバックグラウンド処理とを行う装置であれば、情報処理装置は、排他制御装置100以外の装置でもよい。   In the embodiment of the present invention, the case where the information processing apparatus is the exclusive control apparatus 100 that performs exclusive control related to access from the host 300 to the resource 400 has been described as an example. However, the information processing apparatus may be an apparatus other than the exclusive control apparatus 100 as long as the apparatus performs a plurality of types of processing and background processing according to the received command and the generated event.

1 排他制御システム
100 排他制御装置
101 CPU
102 記憶手段
103 通信手段
104 入力手段
105 出力手段
110 インターバルタイマ
120 スリープタイマ
130 集計制御部
131 インデックス記憶部
132 集計テーブル記憶部
140 コマンド受信部
141 コマンド数制御部
142 重みテーブル記憶部
143 最大コマンド数記憶部
144 デフォルトコマンド数記憶部
145 重み閾値記憶部
150 実行待ちキュー
160 実行制御部
161 実行カウンタ記憶部
162 制御カウンタ記憶部
163 バックグラウンド処理時間記憶部
170 処理部
231 現在インデックス
232 集計テーブル
242 重みテーブル
243 最大コマンド数
244 デフォルトコマンド数
245 重み閾値
261 実行カウンタ
262 制御カウンタ
263 バックグラウンド処理時間
300 ホスト
400 資源
DESCRIPTION OF SYMBOLS 1 Exclusive control system 100 Exclusive control apparatus 101 CPU
DESCRIPTION OF SYMBOLS 102 Memory | storage means 103 Communication means 104 Input means 105 Output means 110 Interval timer 120 Sleep timer 130 Total control part 131 Index memory | storage part 132 Total table memory | storage part 140 Command receiving part 141 Command number control part 142 Weight table memory | storage part 143 Maximum command number memory | storage Unit 144 default command number storage unit 145 weight threshold value storage unit 150 execution waiting queue 160 execution control unit 161 execution counter storage unit 162 control counter storage unit 163 background processing time storage unit 170 processing unit 231 current index 232 aggregation table 242 weight table 243 Maximum number of commands 244 Default number of commands 245 Weight threshold 261 Execution counter 262 Control counter 263 Background processing time 3 0 host 400 resources

Claims (10)

処理手段により実行される所定長の周期毎の処理の数が、最大処理数以下となるように、要求された処理の実行を前記処理手段に指示する実行制御手段と、
前記要求された処理の重みの累積値に応じて、前記最大処理数を設定する、処理数制御手段と、
を備える情報処理装置。
Execution control means for instructing the processing means to execute the requested processing so that the number of processes per cycle of a predetermined length executed by the processing means is equal to or less than the maximum number of processes;
A processing number control means for setting the maximum processing number according to a cumulative value of the requested processing weights;
An information processing apparatus comprising:
前記処理数設定手段は、現在より前の所定期間における前記累積値が所定の閾値以上の場合、前記最大処理数に、前記累積値が所定の閾値未満の場合の前記最大処理数より小さい値を設定する、
請求項1に記載の情報処理装置。
When the cumulative value in a predetermined period before the present is equal to or greater than a predetermined threshold, the processing number setting means sets the maximum processing number to a value smaller than the maximum processing number when the cumulative value is less than the predetermined threshold. Set,
The information processing apparatus according to claim 1.
前記重みは、処理時間の長い処理の重みが、処理時間の短い処理より大きくなるように設定される、
請求項1または2に記載の情報処理装置。
The weight is set so that the weight of the processing with a long processing time is larger than the processing with a short processing time.
The information processing apparatus according to claim 1 or 2.
前記実行制御手段は、前記所定長の周期の各々において、前記処理手段により実行された処理の数が前記最大処理数に等しくなった場合に、所定のバックグラウンド処理を完了するために必要な時間の間、要求された処理の前記処理手段への実行指示を中断し、
前記処理手段は、前記処理手段により実行が指示されている処理がない場合に、所定のバックグラウンド処理を行う、
請求項1乃至3のいずれかに記載の情報処理装置。
The execution control means is a time required to complete a predetermined background process when the number of processes executed by the processing means becomes equal to the maximum number of processes in each of the predetermined length cycles. During which the execution instruction to the processing means for the requested processing is interrupted,
The processing means performs a predetermined background process when there is no processing instructed to be executed by the processing means.
The information processing apparatus according to claim 1.
前記実行制御手段は、前記所定のバックグラウンド処理を完了するために必要な時間経過後、前記所定長の周期毎の前記処理手段により実行される処理の数が前記最大処理数を超えて、前記要求された処理の実行を前記処理手段に指示する、
請求項4に記載の情報処理装置。
The execution control means, after a lapse of time necessary to complete the predetermined background processing, the number of processes executed by the processing means for each cycle of the predetermined length exceeds the maximum processing number, Instructing the processing means to execute the requested processing;
The information processing apparatus according to claim 4.
要求された処理の重みの累積値に応じて、最大処理数を設定し、
処理手段により実行される所定長の周期毎の処理の数が、前記最大処理数以下となるように、前記要求された処理の実行を前記処理手段に指示する、
情報処理方法。
Set the maximum number of processes according to the accumulated value of the requested process weight,
Instructing the processing means to execute the requested process so that the number of processes per period of a predetermined length executed by the processing means is equal to or less than the maximum processing number;
Information processing method.
前記最大処理数を設定する場合、現在より前の所定期間における前記累積値が所定の閾値以上の場合、前記最大処理数に、前記累積値が所定の閾値未満の場合の前記最大処理数より小さい値を設定する、
請求項6に記載の情報処理方法。
When setting the maximum number of processes, if the cumulative value in a predetermined period before the present is greater than or equal to a predetermined threshold, the maximum number of processes is smaller than the maximum number of processes when the cumulative value is less than a predetermined threshold. Set the value,
The information processing method according to claim 6.
前記重みは、処理時間の長い処理の重みが、処理時間の短い処理より大きくなるように設定される、
請求項6または7に記載の情報処理方法。
The weight is set so that the weight of the processing with a long processing time is larger than the processing with a short processing time.
The information processing method according to claim 6 or 7.
前記処理手段において、実行が指示されている処理がない場合に、所定のバックグラウンド処理が行われ、
前記所定長の周期の各々において、前記処理手段により実行された処理の数が前記最大処理数に等しくなった場合、所定のバックグラウンド処理を完了するために必要な時間の間、要求された処理の前記処理手段への実行指示を中断する、
請求項6乃至8のいずれかに記載の情報処理方法。
In the processing means, when there is no processing instructed to execute, a predetermined background processing is performed,
In each of the predetermined length cycles, when the number of processes executed by the processing means is equal to the maximum number of processes, the requested process for the time required to complete the predetermined background process Interrupting the execution instruction to the processing means,
The information processing method according to claim 6.
コンピュータに、
要求された処理の重みの累積値に応じて、最大処理数を設定し、
処理手段により実行される所定長の周期毎の処理の数が、前記最大処理数以下となるように、前記要求された処理の実行を前記処理手段に指示する、
処理を実行させるプログラム。
On the computer,
Set the maximum number of processes according to the accumulated value of the requested process weight,
Instructing the processing means to execute the requested process so that the number of processes per period of a predetermined length executed by the processing means is equal to or less than the maximum processing number;
A program that executes processing.
JP2014184035A 2014-09-10 2014-09-10 Information processing apparatus, information processing method, and program Active JP6384218B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2014184035A JP6384218B2 (en) 2014-09-10 2014-09-10 Information processing apparatus, information processing method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014184035A JP6384218B2 (en) 2014-09-10 2014-09-10 Information processing apparatus, information processing method, and program

Publications (2)

Publication Number Publication Date
JP2016057871A true JP2016057871A (en) 2016-04-21
JP6384218B2 JP6384218B2 (en) 2018-09-05

Family

ID=55758412

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014184035A Active JP6384218B2 (en) 2014-09-10 2014-09-10 Information processing apparatus, information processing method, and program

Country Status (1)

Country Link
JP (1) JP6384218B2 (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000322365A (en) * 1999-05-12 2000-11-24 Hitachi Ltd Acceptance limiting method for server computer
US6675190B1 (en) * 1998-10-08 2004-01-06 Alcatel Method for cooperative multitasking in a communications network, and a network element for carrying out the method
JP2006171823A (en) * 2004-12-13 2006-06-29 Hitachi Ltd Access control device in computer system
JP2010044633A (en) * 2008-08-14 2010-02-25 Bank Of Tokyo-Mitsubishi Ufj Ltd Online system and access control method
JP2011070435A (en) * 2009-09-25 2011-04-07 Hitachi Ltd Computer system, method of processing request, and server device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6675190B1 (en) * 1998-10-08 2004-01-06 Alcatel Method for cooperative multitasking in a communications network, and a network element for carrying out the method
JP2000322365A (en) * 1999-05-12 2000-11-24 Hitachi Ltd Acceptance limiting method for server computer
JP2006171823A (en) * 2004-12-13 2006-06-29 Hitachi Ltd Access control device in computer system
JP2010044633A (en) * 2008-08-14 2010-02-25 Bank Of Tokyo-Mitsubishi Ufj Ltd Online system and access control method
JP2011070435A (en) * 2009-09-25 2011-04-07 Hitachi Ltd Computer system, method of processing request, and server device

Also Published As

Publication number Publication date
JP6384218B2 (en) 2018-09-05

Similar Documents

Publication Publication Date Title
US20170155560A1 (en) Management systems for managing resources of servers and management methods thereof
US8032679B2 (en) Device and method for controlling network processing mode, and non-transitory computer-readable medium recording program for controlling network processing mode
JP4387970B2 (en) Data I / O program, device, and method
JP2008046997A (en) Arbitration circuit, crossbar, request selection method, and information processor
JP6001480B2 (en) Migration processing method and processing apparatus
JP5471822B2 (en) I / O control program, information processing apparatus, and I / O control method
US20200125395A1 (en) Automated switching between interrupt context i/o processing and thread context i/o processing
JP2012221340A (en) Control method, program and computer
JP2015069384A (en) Information processing system, control method for information processing system, and control program for information processor
US20180217875A1 (en) Data processing system and data processing method
JP2017194931A (en) Storage management device, storage device management method, and storage device management program
EP2905703A1 (en) Parallel computer system, control method of parallel computer system, and computer-readable storage medium
JP6384218B2 (en) Information processing apparatus, information processing method, and program
CN107315700B (en) Interrupt processing method and related device
JP6046523B2 (en) In-memory distributed database, data distribution method and program
JP5526748B2 (en) Packet processing device, packet distribution device, control program, and packet distribution method
JP5678923B2 (en) Storage system, input / output control device, input / output control method, and computer program
JP2010244164A (en) Dma controller, information processor, and dma management method
KR20140042420A (en) Semiconductor device and operating method thereof
US10078604B1 (en) Interrupt coalescing
JP6204287B2 (en) Distributed processing method, processing server, and program
JP2010186347A (en) System, method and program for scheduling job
JPWO2016079786A1 (en) Computer system and data processing method
JP6468066B2 (en) Parallel computing device, parallel computing system, collective communication method, and collective communication program
JP6819874B2 (en) Memory access device, memory access control method, program, multi-core processor

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20170809

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20180314

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20180508

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20180704

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20180723

R150 Certificate of patent or registration of utility model

Ref document number: 6384218

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150