JP2012079143A - Channel control device and method - Google Patents
Channel control device and method Download PDFInfo
- Publication number
- JP2012079143A JP2012079143A JP2010224610A JP2010224610A JP2012079143A JP 2012079143 A JP2012079143 A JP 2012079143A JP 2010224610 A JP2010224610 A JP 2010224610A JP 2010224610 A JP2010224610 A JP 2010224610A JP 2012079143 A JP2012079143 A JP 2012079143A
- Authority
- JP
- Japan
- Prior art keywords
- channel
- restart
- busy
- virtual machine
- processing
- 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
Links
Images
Abstract
Description
本発明は,入出力装置についてのチャネル制御技術に関する。 The present invention relates to a channel control technique for an input / output device.
ホストシステム上に,仮想的なハードウェア(仮想マシン)を複数開設して同時に複数のOSの実行を可能とするコンピュータシステムにおいて,仮想マシンのOSでは複数のアーキテクチャが混在する。 In a computer system in which a plurality of virtual hardware (virtual machines) are opened on a host system and a plurality of OSs can be executed at the same time, a plurality of architectures are mixed in a virtual machine OS.
このようなコンピュータシステムで,専用ハードウェア(チャネル装置)を用いて入出力処理を制御するチャネル制御方式が採用されている場合に,チャネル制御を実行するチャネル制御装置が,あるチャネル配下の入出力装置を複数の仮想マシン(ゲスト)に割り当てることにより,チャネルを複数ゲストで共用することがある。 In such a computer system, when a channel control method for controlling input / output processing using dedicated hardware (channel device) is adopted, the channel control device for executing channel control is connected to an input / output under a certain channel. By assigning a device to multiple virtual machines (guests), the channel may be shared by multiple guests.
1つのチャネルで2つのゲスト各々から発行された入出力命令(IO命令)が衝突した場合に,チャネル制御装置は,先発のIO命令を処理し,後発のIO命令については,「チャネルビジー」状態として,先発のIO命令の処理完了を待機させる。そして,チャネル制御装置は,先発のIO命令の完了後に「ビジー解除」を行い,待機させていた後発のIO命令処理の再開(リスタート)を行う。 When an input / output command (IO command) issued from each of two guests in one channel collides, the channel controller processes the first IO command, and the second channel IO command is in the “channel busy” state. And waiting for the completion of the processing of the preceding IO instruction. Then, the channel control device performs “busy release” after completion of the first IO command, and resumes (restarts) the subsequent IO command processing that has been waiting.
後発のIO命令のリスタートは,ゲストのアーキテクチャによって,「ハードウェア(HW)リスタート」または「OSリスタート」のいずれかとなる。 The restart of the subsequent IO instruction is either “hardware (HW) restart” or “OS restart” depending on the guest architecture.
図8は,「HWリスタート」を説明するための図,図9は,「OSリスタート」を説明するための図である。 FIG. 8 is a diagram for explaining “HW restart”, and FIG. 9 is a diagram for explaining “OS restart”.
「HWリスタート」では,図8に示すように,ゲストOSがIO命令を発行したときに,チャネルβがビジーであれば,チャネル制御装置は,受け付けたIO命令を保持し,ビジーの解除を行った後に保持していたIO命令の処理を再開する。 In “HW restart”, as shown in FIG. 8, if the channel β is busy when the guest OS issues an IO command, the channel controller holds the received IO command and cancels the busy state. The processing of the IO instruction held after the execution is resumed.
「OSリスタート」では,図9に示すように,チャネルβがビジーであれば,チャネル制御装置は,IO命令を発行したゲストOSに対してチャネルビジーを通知し,ビジーの解除を行った後にビジー解除をさらに通知して,ゲストOSが再発行したリスタート用のIO命令を受け付けてIO命令の処理を行う。 In “OS restart”, as shown in FIG. 9, if the channel β is busy, the channel control device notifies the guest OS that issued the IO command of the channel busy and cancels the busy. Further, the busy cancellation is notified, and the restart IO instruction reissued by the guest OS is received and the IO instruction is processed.
従来,チャネルで衝突したIO命令を制御するために,低速CPUと高速CPUがドライブを共用する場合に,低速CPUが高速CPUに使用されているドライブにIO命令を発行するとチャネルビジーが通知され,高速CPUがドライブを開放すると,低速CPUのIO命令を優先的に処理する手法が知られている。 Conventionally, when a low-speed CPU and a high-speed CPU share a drive to control an IO instruction that has collided with a channel, a channel busy is notified when the low-speed CPU issues an IO instruction to a drive used for the high-speed CPU. There is known a method of preferentially processing an I / O command of a low-speed CPU when the high-speed CPU releases the drive.
また,複数のCPUにチャネルパスを介して接続される入出力制御装置と複数の入出力装置とを有する構成において,1つのCPUからIO命令を受け付けたときに他のCPUがその入出力装置を使用中であればデバイスビジーを通知し,あるCPUが他CPUのIO命令の受付で待たされた回数が規定値を超えたときに,他CPUからそのCPUへ入出力を切り換える手法が知られている。 Further, in a configuration having an input / output control device connected to a plurality of CPUs via a channel path and a plurality of input / output devices, when an I / O command is received from one CPU, another CPU selects the input / output device. There is known a method of notifying device busy when in use, and switching the input / output from another CPU to that CPU when the number of times that a certain CPU has waited for reception of an IO command from another CPU exceeds a specified value. Yes.
チャネルを共用する2つのゲストのうち,一方のゲストのI/O負荷が極端に高い場合や,チャネルのリザーブを長期間にわたって保持する状況が生じた場合など,他方のゲストのIO命令が処理されにくくなり,入出力レスポンスが悪くなることがある。 Of the two guests sharing a channel, the IO instruction of the other guest is processed, such as when the I / O load of one guest is extremely high or when there is a situation where the channel reserve is maintained for a long period of time. It may become difficult and input / output response may become worse.
例えば,図10に示すように,「OSリスタート」を採用するゲストと,「HWリスタート」を採用するゲストとがチャネルを共用し,ゲスト各々がIO命令を発行した場合に,双方のゲストがチャネルビジーを認識しているときには,OSリスタートのゲストは,再度チャネルビジーとなる確率が高くなる。これは,OSリスタートのゲストでは,最初のビジー解除からリスタート用のIO命令の再発行までの処理の所要時間が,HWリスタートのゲストに比べて長くかかることから,IO命令の再発行の時点で,チャネルが他のゲストのIO命令発行により再度ビジーとなることがあるからである。 For example, as shown in FIG. 10, when a guest adopting “OS restart” and a guest adopting “HW restart” share a channel and each guest issues an IO command, both guests When OS recognizes channel busy, the guest of OS restart has a higher probability of channel busy again. This is because the OS restart guest takes a longer time from the initial busy release to the re-issuance of the IO instruction for restart than the guest of the HW restart. This is because at this point, the channel may become busy again due to the IO instruction issued by another guest.
このように,OSリスタートのゲストのリスタート処理が滞りタイムアウトが発生すると,例えば,業務システムでは端末装置での処理が停止したりするなど,深刻な障害となる。 As described above, when the restart process of the guest for OS restart is delayed and a timeout occurs, for example, in the business system, the processing in the terminal device is stopped, which causes a serious failure.
チャネルを共用する各ゲストを,チャネルビジーになった順番でリスタートさせるように制御キューを導入したチャネル制御の場合には,各ゲストのIO命令の発行頻度に対応した順序で制御することができず,結果として,高速なゲストが,低速なゲストの影響を受けてしまい,全体としての処理効率を低下させるという問題が生じる。 In the case of channel control in which a control queue is introduced so that each guest sharing a channel is restarted in the order of channel busy, the guest can be controlled in the order corresponding to the frequency of IO instruction issued by each guest. As a result, there is a problem that the high-speed guest is affected by the low-speed guest and the overall processing efficiency is lowered.
さらに,チャネルビジーはデバイスビジーと異なり,マルチパス,すなわちIO命令の実行を他のチャネルを選択して処理できる機能を持つゲストの場合には,ビジーとなったチャネル以外のチャネルにより処理できるため,チャネルビジーを認識したゲストのリスタートが無駄になるという問題がある。 Furthermore, channel busy is different from device busy, and in the case of guests with multipath, that is, a guest with a function that can select and process the execution of IO instructions, it can be processed by a channel other than the busy channel. There is a problem that restarting guests who recognize channel busy is wasted.
本願において開示されるチャネル制御装置の目的は,異なるアーキテクチャの仮想マシンがチャネルを共用する場合でも,効率よく共用できるチャネル制御を実現することである。 The purpose of the channel control device disclosed in the present application is to realize channel control that can be shared efficiently even when virtual machines of different architectures share the channel.
本願において開示されるチャネル制御装置は,複数の仮想マシンの入出力処理をチャネル制御するチャネル制御装置であって,記憶部と,仮想マシンの入出力処理のチャネル制御を行うリスタート制御部とを備える。 The channel control device disclosed in the present application is a channel control device that performs channel control of input / output processing of a plurality of virtual machines, and includes a storage unit and a restart control unit that performs channel control of input / output processing of the virtual machine. Prepare.
前記チャネル制御装置のリスタート制御部は,チャネルを共用する仮想マシン各々の入出力処理およびチャネル制御の状態を示す制御情報を前記記憶部に書き込む処理と,前記チャネルを共用する複数の仮想マシンのいずれかからIO命令を受け付けた場合に,前記チャネルがビジーであるときは,前記制御情報をもとに,該チャネルのビジー解除時にリスタートする仮想マシンの順序を決定する処理と,前記順序にもとづきリスタートする仮想マシンが,ビジー解除の通知を受けてIO命令を再発行するOSリスタートをするものであるときは,該仮想マシンへのビジー解除の通知時から該仮想マシンから受け付けたIO命令の処理完了時までの間,前記チャネルを共用する他の仮想マシンに対するビジー解除およびIO命令の処理を抑止し,前記リスタートする仮想マシンが,チャネルがビジーとなったIO命令を再発行しないハードウェア・リスタートをするものであるときは,該チャネルのビジー解除前に受け付けていたIO命令の処理を実行する。 The restart control unit of the channel control device includes a process of writing control information indicating a state of input / output processing and channel control of each virtual machine sharing a channel to the storage unit, and a plurality of virtual machines sharing the channel. If the channel is busy when an IO command is received from any one of them, a process for determining the order of virtual machines to be restarted when the channel is released from the busy state based on the control information; If the virtual machine to be restarted is an OS restart that receives a busy release notification and reissues an IO command, the IO received from the virtual machine from the time of the busy release notification to the virtual machine is received. Until the completion of instruction processing, busy cancellation and IO instruction processing for other virtual machines sharing the channel are suppressed. When the virtual machine to be restarted is a hardware restart that does not reissue an IO instruction whose channel is busy, the processing of the IO instruction that was accepted before releasing the busy of the channel is executed. To do.
また,本発明の別の態様として開示するチャネル制御方法は,上記チャネル制御装置で実行される処理を実現する処理ステップを有する。 A channel control method disclosed as another aspect of the present invention includes processing steps for realizing processing executed by the channel control device.
異なるアーキテクチャの仮想マシンがチャネルを共用する場合でも,効率よく共用できるチャネル制御を実現することができる。 Even when virtual machines with different architectures share channels, it is possible to achieve channel control that can be shared efficiently.
図1は,本発明の一実施の形態として開示されるチャネル制御装置の構成例を示す図である。 FIG. 1 is a diagram illustrating a configuration example of a channel control device disclosed as an embodiment of the present invention.
チャネル制御装置10は,演算装置(CPU)および一時記憶装置(図示しない),入出力装置2,チャネル3を備えるコンピュータシステム1に備えられる。
The
コンピュータシステム1では,ホストシステム上に異なるアーキテクチャの仮想マシン(ゲスト)4を構築する環境を実現している。
The
チャネル3は,入出力装置2へまたは入出力装置2からデータを転送する経路機構であって,ゲスト4と入出力装置2とのインタフェースを司る機構である。チャネル3は,複数のゲスト4で共用することができる。
The
入出力装置2は,例えば,外部記憶媒体,例えば,ストレージ,レイド等の外部記憶装置である。
The input /
チャネル制御装置10は,入出力装置2に対応するチャネル3をゲスト4のOS(ゲストOS)に割り当て,ゲストOSが発行したIO命令の処理を制御する。
The
より詳しくは,チャネル制御装置10は,ゲスト4が発行したIO命令がチャネルビジーの場合に,そのチャネルビジー解除後に,ビジー解除にかかるIO命令の入力処理をリスタートさせる。
More specifically, when the IO command issued by the
チャネル制御装置10が制御するリスタートは,「OSリスタート」または「HWリスタート」のいずれかである。HWリスタートは,チャネルビジーの解除後に,チャネル制御装置10が,ビジー解除されたチャネル3によるIO命令の入出力処理を再開する処理である。OSリスタートは,チャネルビジーの解除後に,ゲスト4のOSがチャネルビジーとなったIO命令を再発行し,チャネル制御装置10が再発行されたIO命令を受け付けて入出力処理を実行する処理である。なお,チャネル制御装置10はが,再発行されたIO命令を受け付けてその入出力処理を制御する。
The restart controlled by the
チャネル制御装置10は,リスタート制御部11,制御情報記憶部13,およびリスタートタイマ部15を備える。
The
リスタート制御部11は,チャネル制御装置10内で,チャネル3のチャネルビジーおよびチャネルビジー解除により,ゲスト4が発行したIO命令による,チャネル3を用いる入出力処理を制御する。
The
より具体的には,リスタート制御部11は,チャネル3を共用するゲスト4各々から,発行されたIO命令を受け付け,受け付けたIO命令による入出力処理およびチャネル3の制御状態を示す制御情報を制御情報記憶部13に格納する。
More specifically, the
そして,リスタート制御部11は,共用する複数のゲスト4のいずれかからIO命令を受け付けたチャネル3がビジーである場合に,制御情報記憶部13の制御情報にもとづいて,ゲスト4のリスタートがOSリスタートであるかHWリスタートであるかを判断し,チャネル3のビジー解除時にリスタートさせるゲスト4の順序を決定する。
The
リスタート制御部11は,ゲスト4のリスタートがOSリスタートであるときは,そのゲスト4へビジー解除を通知し,ゲスト4から受け付けたIO命令の処理を行う一方,ビジー解除の通知時からIO命令の処理完了時までの間,チャネル3を共用する他のゲスト4に対するビジー解除およびIO命令の処理を抑止する。リスタート制御部11は,リスタートするゲスト4が,HWリスタートを行うときは,チャネル3のビジー解除前に受け付けていた,そのゲスト4のIO命令を処理する。
When the restart of the
制御情報記憶部13は,各チャネルの制御情報を記憶する。 The control information storage unit 13 stores control information for each channel.
図2は,チャネルごとの制御情報である制御情報テーブルの構成例を示す図である。 FIG. 2 is a diagram illustrating a configuration example of a control information table that is control information for each channel.
図2に示す制御情報テーブルは,チャネルの識別情報(チャネルa),ビジー解除開始時間,および各ゲストのゲスト情報を含む。 The control information table shown in FIG. 2 includes channel identification information (channel a), busy release start time, and guest information of each guest.
ビジー解除開始時間は,後述するリスタートのタイプがOS型であるゲスト4が,ビジー解除を開始した時刻,すなわち,ビジー解除通知時刻を示す。
The busy release start time indicates the time when the
ゲスト情報は,ゲストID,リスタート,パス,再開可能数,再開済数,状態,処理数の各項目を有する。 The guest information includes items of guest ID, restart, path, resumable number, resumed number, state, and processing number.
ゲストIDは,ゲスト4を識別する番号である。
The guest ID is a number for identifying the
リスタートは,ゲスト4の入出力処理のリスタート方法を示す。“OS”は,OSリスタートを示し,“HW”は,HWリスタートを示す。
“Restart” indicates a restart method of the input / output processing of the
パスは,ゲスト4のチャネルの利用形態を示す。“マルチパス”は,ゲスト4が入出力装置2へのパスとして他のチャネルを選択できることを示し,“シングルパス”は,ゲスト4が1つのチャネルのみ利用することを示す。
The path indicates the usage mode of the
再開可能数は,一定間隔における入出力処理の再開(リスタート)可能な数を示す。例えば,以下の式により求められる。 The resumable number indicates the number of I / O processes that can be restarted (restarted) at regular intervals. For example, it is obtained by the following formula.
再開可能数=1+((ゲスト数×3)×(本ゲストの「処理数」÷全ゲストの「処理数」の合計))
また,再開可能数は,ゲスト4のパスの利用形態に応じた重み付けをして,例えば,以下の式により求められるようにしてもよい。
Number of resumables = 1 + ((number of guests x 3) x ("number of processes" for this guest ÷ total number of "processes" for all guests)))
Further, the resumable number may be obtained by weighting according to the usage mode of the
再開可能数=1+((ゲスト数×3)×(本ゲストの「処理数」÷全ゲストの「処理数」の合計))+(本ゲストの「パス」がシングルの場合=1,マルチの場合=0)
再開済数は,一定間隔における入出力処理の再開(リスタート)実施の数を示す。
Number of resumables = 1 + ((Number of guests x 3) x (Number of processes for this guest ÷ Total number of processes for all guests)) + (If the "path" of this guest is single = 1, multi Case = 0)
The restarted number indicates the number of restarts (restarts) of input / output processing at a fixed interval.
状態は,チャネルビジーに関する現在の状態を示す。“フリー”は,ゲスト4がチャネルを使用していない状態,“ビジー”は,チャネル3がIO命令を処理中であることを示す。“ビジー解除中”は,ビジー解除の実行中であることを示す。
The status indicates the current status regarding channel busy. “Free” indicates that the
処理数は,一定間隔における入出力処理の数を示す。 The number of processes indicates the number of input / output processes at regular intervals.
ゲスト情報は,ゲスト4が開設された時または運用中のゲスト4にチャネル3が割り当てられた時に生成される。
The guest information is generated when the
リスタートタイマ部15は,リスタートするゲスト4に対するビジー解除通知時から,所定時間の経過を示すタイムアウトを検出する。
The
リスタートタイマ部15が,制御情報テーブルのビジー解除時間の時刻設定を検出してタイマ処理を行うことにより,OSリスタートのゲスト4がリスタートの対象に選択されている場合に,通知したゲスト4のゲストOSがビジー解除通知に反応するまで他のゲスト4のビジー解除を抑止し,その一方で,ゲスト4がビジー解除通知を認識せず入出力処理が再開されない場合には,リスタートの対象を他のゲスト4へ切り替えることが可能となる。
When the
チャネル制御装置10のリスタート制御部11は,以下のように処理を行う。
The
処理ステップ1: リスタート制御部11は,チャネル3(3b)を共用しているゲスト4の数と,各ゲスト4(4a,4b)のリスタートが,“OS”であるか“HW”であるかを判断して,制御情報テーブルに書き込む。さらに,リスタート制御部11は,各ゲスト4(4a,4b)のパスの利用形態(シングルパス,マルチパス)を書き込む。
Processing Step 1: The
処理ステップ2: リスタート制御部11は,制御情報テーブルを参照して,各ゲスト4(4a,4b)のチャネル3の利用回数を計測する。
Processing Step 2: The
処理ステップ3: チャネル3bで,複数のゲスト4がチャネルビジーになった場合に,チャネル3bの利用回数と利用形態(シングルパス・マルチパス)に応じて,ビジー解除時のリスタートするゲストの順番を決定する。
Processing Step 3: When
図3に示すように,2つのゲスト4a,4bがチャネル3bを共用している場合に,例えば,HWリスタートのゲスト4aが,ゲスト4bに比べて入出力処理の頻度が多く,シングルパスである場合は,リスタートするゲストの順序を,ゲスト4a,ゲスト4bと決定する。
As shown in FIG. 3, when two guests 4a and 4b share the
チャネルの利用形態(シングルパス・マルチパス)を,リスタートの順序決定に用いる理由は,マルチパスの機能を有するゲスト4は,他のチャネルを利用してIO命令が実行される可能性が高いためである。
The reason for using the channel usage mode (single-path / multi-path) to determine the restart order is that the
例えば,図3に示すゲスト4aがマルチパスである場合には,チャネル3bがチャネルビジーであれば,他のチャネル3aを選択して入出力装置2への入出力処理を行うことができるとする。この場合には,チャネル3bのチャネル制御において,ゲスト4aのリスタートの順序を下位としても,チャネル3aを用いてIO命令の処理が実行される可能性が高く,全体としてはチャネルの使用効率がよくなるからである。
For example, when the guest 4a shown in FIG. 3 is multipath, if the
リスタート制御部11は,決定した順序に従って,ゲスト4aのリスタートr1を処理し,その処理完了後に,ゲスト4bのリスタートr2を実行する。
The
一方,リスタート制御部11は,制御情報テーブルの情報から,リスタートするゲストの順序を,ゲスト4b,4aと決定した場合には,OSリスタートのゲスト4bへビジー解除を通知する。そして,リスタート制御部11は,ビジー解除時に,ゲスト4bへビジー解除を通知し,ゲスト4bのリスタート用のIO命令を受け付けて,入出力処理を再開する。リスタート制御部11は,ビジー解除の通知から,ゲスト4bのゲストOSが反応するまで,他のゲスト4aのビジー解除とIO命令の実行を抑止する。
On the other hand, when the order of the guests to be restarted is determined to be guests 4b and 4a from the information in the control information table, the
これにより,ビジー解除を通知したゲスト4bのゲストOSが発行するリスタート用のIO命令の実行を保証する。 This guarantees the execution of the restart IO instruction issued by the guest OS of the guest 4b that has notified the busy release.
そして,ゲスト4bが発行したリスタート用のIO命令により,リスタートr2が完了したら,リスタート制御部11は,ゲスト4aのリスタートr1を実行する。
When the restart r2 is completed by the restart IO command issued by the guest 4b, the
ゲスト4bへビジー解除を通知したが,ゲスト4bのゲストOSが他の処理により一定時間反応しない場合(リスタート用のIO命令の発行がない場合),リスタート制御部11は,ゲスト4bのリスタートr2を中止して,次の順序に決定されたゲスト4aのリスタートr1を実行する。ビジー解除通知後の一定時間の経過は,リスタートタイマ部15が監視する。
When the guest 4b is notified of the release of busy, but the guest OS of the guest 4b does not react for a certain time due to other processing (when no restart IO instruction is issued), the
以下,チャネル制御装置10の処理をより詳細に説明する。
Hereinafter, the processing of the
図4は,IO命令発行時の処理フロー例を示す図である。 FIG. 4 is a diagram illustrating an example of a processing flow when an IO instruction is issued.
リスタート制御部11は,ゲスト4xが発行したIO命令を受け付けると,以下の処理を行う。
When the
リスタート制御部11は,IO命令を発行したゲスト4xが割り当てられているチャネル3を選択して(ステップS10),選択したチャネル3の制御情報テーブルを参照して,チャネルビジーであるかを判断する(ステップS11)。
The
チャネルビジーではない場合には(ステップS11のN),リスタート制御部11は,制御情報テーブルの「状態」が“ビジー解除中”であるゲストが存在するかを判断する(ステップS12)。チャネルビジーである場合(ステップS11のY)または制御情報テーブルの「状態」が“ビジー解除中”であるゲストが存在する場合には(ステップS12のY),リスタート制御部11は,制御情報テーブル中のゲスト4xの「状態」をビジーにする(ステップS13)。
If the channel is not busy (N in step S11), the
さらに,リスタート制御部11は,ゲスト4xの「リスタート」がHWであるかを判断して(ステップS14),ゲスト4xの「リスタート」がHWであれば(ステップS14のY),チャネル制御装置10で受け付けたIO命令の実行を保留して(ステップS15),処理を終了する。
Further, the
ゲスト4xの「リスタート」がHWでなければ(ステップS14のN),リスタート制御部11は,ゲスト4xのゲストOSへチャネルビジーを通知して(ステップS16),処理を終了する。
If the “restart” of the guest 4x is not HW (N in step S14), the
制御情報テーブルの「状態」が“ビジー解除中”であるゲストが存在しない場合には(ステップS12のN),リスタート制御部11は,制御情報テーブルのゲスト4xの「処理数」を1加算し,「状態」をフリーにし,「ビジー解除開始時間」を初期化して(ステップS17),さらに,受け付けたIO命令による入出力処理を開始して(ステップS18),処理を終了する。
If there is no guest whose “status” in the control information table is “busy being released” (N in step S12), the
図5は,ビジー解除時の処理フロー例を示す図である。 FIG. 5 is a diagram illustrating an example of a processing flow when busy is canceled.
リスタート制御部11は,チャネル3でビジーが解消された場合に,以下の処理を行う。
The
リスタート制御部11は,チャネル3の制御情報テーブルの「状態」がビジーであるゲストが存在するかを判断する(ステップS20)。
The
「状態」がビジーであるゲストが存在する場合には(ステップS20のY),リスタート制御部11は,さらに,制御情報テーブルの「状態」がビジーであって,かつ,「再開済数」<「再開可能数」に該当するゲストが存在するかを判断する(ステップS21)。
When there is a guest whose “status” is busy (Y in step S20), the
「状態」がビジーであって,かつ,「再開済数」<「再開可能数」に該当するゲストが存在しなければ,すなわち,すべてのゲストが「再開済数」=「再開可能数」である場合(ステップS21のN),リスタート制御部11は,制御情報テーブルの再設定処理を行って(ステップS22),ステップS23の処理へ進む。
If "Status" is busy and there is no guest corresponding to "Restarted count" <"Resumable count", that is, all guests are "Restarted count" = "Resumable count" If there is any (N in Step S21), the
「状態」がビジーであって,かつ,「再開済数」<「再開可能数」に該当するゲストが存在する場合に(ステップS21のY),リスタート制御部11は,制御情報テーブルの「再開済数÷再開可能数」が最小であるゲストを選択し(ステップS23),制御情報テーブルの選択したゲスト4yの「再開済数」を1加算する(ステップS24)。
When the “status” is busy and there is a guest corresponding to “restarted number” <“restartable number” (Y in step S21), the
そして,リスタート制御部11は,ゲスト4yの「リスタート」がHWであるかを判断する(ステップS25)。ゲスト4yの「リスタート」がHWであれば(ステップS25のY),リスタート制御部11は,制御情報テーブルのゲスト4yの「状態」をフリーにし(ステップS26),入出力処理を開始して(ステップS27),処理を終了する。
The
選択したゲストの「リスタート」がHWでなければ(ステップS25のN),リスタート制御部11は,制御情報テーブルのゲスト4yの「状態」をビジー解除中にして,「ビジー解除開始時間」に現処理時刻を設定する(ステップS28)。さらに,リスタート制御部11は,選択したゲスト4yのゲストOSへ,ビジー解除を通知して(ステップS29),処理を終了する。
If the “restart” of the selected guest is not HW (N in step S25), the
図6は,図5に示す処理フローの制御情報テーブル再設定処理(ステップS22)の,より詳細な処理フローを示す図である。 FIG. 6 is a diagram showing a more detailed processing flow of the control information table resetting process (step S22) of the processing flow shown in FIG.
リスタート制御部11は,チャネル3を共用するゲスト4を1つ選択して(ステップS220),所定の式によって,制御情報テーブルの「再開可能数」を算出し,算出した値を整数化した後,制御情報テーブルへ設定する(ステップS221)。さらに,リスタート制御部11は,制御情報テーブルの「再開数」,「処理数」を初期化する(ステップS222)。
The
処理したゲスト4がチャネル3を共用している最後のゲストであるかを調べて,最後のゲストであれば(ステップS223のY),リスタート制御部11は,処理を終了する。最後のゲストでなければ(ステップS223のN),リスタート制御部11は,ステップS220の処理へ戻り,次のゲストを選択する(ステップS220)。
It is checked whether or not the processed
図7は,リスタートタイマ部15の処理フロー例を示す図である。
FIG. 7 is a diagram illustrating a processing flow example of the
リスタートタイマ部15は,制御情報テーブルのビジー解除時間の設定イベントを検出するパトロール処理を行う(ステップS30)。リスタートタイマ部15は,制御情報テーブルの「ビジー解除開始時間」が設定されているかを判断する(ステップS31)。制御情報テーブルの「ビジー解除開始時間」が設定されていれば(ステップS31のY),リスタートタイマ部15は,さらに,現時点で,設定されているビジー解除開始時間から一定時間経過しているかを調べる(ステップS32)。
The
ビジー解除開始時間から一定時間経過するかをチェックし,ビジー解除開始時間から一定時間が経過していたら(ステップS32のY),制御情報テーブルの「状態」をフリーにして,「ビジー解除開始時間」を初期化して(ステップS33),ビジー解除時の処理(ステップS20〜S29)へ進む(ステップS34)。 It is checked whether or not a fixed time has elapsed from the busy release start time. If the fixed time has elapsed from the busy release start time (Y in step S32), the “status” in the control information table is set free, and the “busy release start time” Is initialized (step S33), and the process proceeds to the busy release processing (steps S20 to S29) (step S34).
リスタートタイマ部15は,制御情報テーブルの「ビジー解除開始時間」が設定されていなければ(ステップS31のN),または,まだビジー解除開始時間から一定時間が経過していなければ(ステップS32のN),処理を終了する。
The
上記の実施例では,チャネル制御装置10を,専用ハードウェアとする構成例をもとに説明した。別の実施例として,チャネル制御装置10のリスタート制御部11は,チャネル制御装置10にインストールされるソフトウェアとして構成されてもよい。
The above embodiment has been described based on the configuration example in which the
以上の説明したように,開示したチャネル制御装置10によれば,次のような効果がある。
As described above, the disclosed
・ チャネル制御装置10では,複数のゲストが共用するチャネルで,チャネルビジーが生じた場合に,ビジー解除時にリスタートするゲストの順序を各ゲストの入出力処理回数にもとづいて求めた再開可能数により決定する。よって,各ゲストのチャネル利用回数を考慮して効率的なビジー解除を行うことができる。
-In the
・ チャネル制御装置10では,ゲストのリスタートの方式に応じたビジー解除およびリスタートを行う。特に,ビジー解除の対象とするゲストが「OSリスタート」をするものである場合に,チャネル制御装置10は,ビジー解除からIO命令の再処理完了までの間,他のゲストのビジー解除を抑止する。これにより,リスタート完了までの処理時間がより長いゲストに対してもリスタート機会を確保することができる。
The
・ チャネル制御装置10では,リスタートするゲストがOSリスタートである場合に,そのゲストが,ビジー解除通知を認識せず,一定時間内にリスタート用のIO命令を発行しなかったときは,そのリスタートを中止して,リスタートの対象を他のゲストに切り替える。これにより,リスタート未完了の状態を終了させて,チャネルの使用効率の低下を防ぐことができる。
In the
・ チャネル制御装置10では,リスタートするゲストの順序を,各ゲストのIO命令発行の状態を考慮して決定することができる。これにより,効率的なビジー解除を行うことができる。
The
したがって,本発明の一態様として開示されたチャネル制御装置によれば,複数の仮想マシンが共用するチャネルでチャネルビジーが生じた場合に,ビジー解除時にリスタートする仮想マシンの順序を,各仮想マシンの入出力処理の状態にもとづいて決定することができるため,各ゲストの入出力処理を考慮した効率的なビジー解除を行うことができる。 Therefore, according to the channel control device disclosed as one aspect of the present invention, when channel busy occurs in a channel shared by a plurality of virtual machines, the order of virtual machines to be restarted when busy is released is determined for each virtual machine. Since it can be determined based on the state of the input / output process of each guest, it is possible to efficiently cancel the busy state in consideration of the input / output process of each guest.
また,チャネル制御装置によれば,仮想マシンのリスタートの方式,例えばハードウェア・リスタートまたはOSリスタートなどに応じて,ビジー解除およびリスタートの処理を行うことができるため,各ゲストの処理方式に対応して効率的なビジー解除を行うことができる。 Also, according to the channel control device, the busy release and restart processing can be performed according to the restart method of the virtual machine, for example, hardware restart or OS restart. It is possible to cancel the busy state efficiently corresponding to the method.
よって,異なるアーキテクチャの仮想マシンが共用するチャネルにおける効率的なチャネル使用を実現することができる。 Therefore, efficient channel use can be realized in channels shared by virtual machines of different architectures.
以上のように,チャネル制御装置は,異なるアーキテクチャの仮想マシンがチャネルを共用する場合に,効率的な共用を実現することができる。 As described above, the channel control device can realize efficient sharing when virtual machines of different architectures share a channel.
1 コンピュータシステム
2 入出力装置
3 チャネル
4 仮想マシン(ゲスト)
10 チャネル制御装置
11 リスタート制御部
13 制御情報記憶部(制御情報テーブル)
15 リスタートタイマ部
1
10
15 Restart timer section
Claims (6)
仮想マシンの入出力処理のチャネル制御を行うリスタート制御部とを備えて,
前記リスタート制御部は,
チャネルを共用する仮想マシン各々の入出力処理およびチャネル制御の状態を示す制御情報を前記記憶部に書き込み,
前記チャネルを共用する複数の仮想マシンのいずれかからIO命令を受け付けた場合に,前記チャネルがビジーであるときは,前記制御情報にもとづいて,該チャネルのビジー解除時にリスタートする仮想マシンの順序を決定し,
前記順序にもとづきリスタートする仮想マシンが,ビジー解除の通知を受けてIO命令を再発行するOSリスタートをするものであるときは,該仮想マシンへのビジー解除の通知から該仮想マシンから受け付けたIO命令の処理完了までの間,前記チャネルを共用する他の仮想マシンに対するビジー解除およびIO命令の処理を抑止し,前記リスタートする仮想マシンが,チャネルがビジーとなったIO命令を再発行しないハードウェア・リスタートをするものであるときは,該チャネルのビジー解除前に該仮想マシンから受け付けていたIO命令の処理を実行する
ことを特徴とするチャネル制御装置。 A storage unit for storing control information;
A restart control unit that controls the channel of I / O processing of the virtual machine,
The restart control unit
Write control information indicating the status of input / output processing and channel control of each virtual machine sharing the channel to the storage unit,
When an IO command is received from any of a plurality of virtual machines sharing the channel and the channel is busy, the order of virtual machines to be restarted when the channel is released busy based on the control information Determine
When a virtual machine that is restarted based on the above order is an OS restart that receives a busy release notification and reissues an IO command, the virtual machine accepts from the busy release notification to the virtual machine. Until the completion of the processing of the IO instruction, the busy cancellation and the processing of the IO instruction to other virtual machines sharing the channel are suppressed, and the restarting virtual machine reissues the IO instruction whose channel is busy When the hardware restart is not performed, the processing of the IO instruction received from the virtual machine before the busy release of the channel is executed.
前記リスタート制御部は,前記タイムアウトの検出を受け付けた場合に,前記順序にもとづきスタートした仮想マシンの次の順序の仮想マシンを特定して,該特定された仮想マシンが発行したIO命令の処理を実行する
ことを特徴とする請求項1記載のチャネル制御装置。 When a virtual machine that restarts based on the order is one that restarts an OS, a restart timer unit is provided for detecting a timeout indicating a lapse of a predetermined time or more from the time of notification of the busy release to the virtual machine. And
When the restart control unit receives the detection of the timeout, the restart control unit identifies a virtual machine in the next order of the virtual machines started based on the order, and processes an IO instruction issued by the identified virtual machine The channel control device according to claim 1, wherein:
前記リスタート制御部は,前記リスタートさせる仮想マシンの順序を決定する処理において,前記制御情報の仮想マシンの入出力処理回数をもとに前記チャネルを共用する仮想マシン各々のIO命令処理が再開される可能性を示す再開可能数を計算し,前記入出力処理回数および前記再開可能数をもとに,前記リスタートする仮想マシンの順序を決定する
ことを特徴とする請求項1または請求項2に記載のチャネル制御装置。 When control information including the number of input / output processes of each virtual machine sharing the channel is stored in the control information storage unit,
In the process of determining the order of the virtual machines to be restarted, the restart control unit restarts IO command processing of each virtual machine sharing the channel based on the number of input / output processes of the virtual machine in the control information. The restartable number indicating the possibility of being restarted is calculated, and the order of the restarted virtual machines is determined based on the number of I / O processes and the restartable number. 3. The channel control device according to 2.
ことを特徴とする請求項1ないし請求項3のいずれか一項に記載のチャネル制御装置。 In the process of determining the order of virtual machines to be restarted, the restart control unit determines a restartable number of virtual machines when a virtual machine sharing the channel restarts an OS. The channel control device according to any one of claims 1 to 3, wherein the calculation is performed by weighting
ことを特徴とする請求項1ないし請求項4のいずれか一項に記載のチャネル制御装置。 In the process of determining the order of virtual machines to be restarted, the restart control unit, when a virtual machine sharing the channel can select and use another channel as a path, The channel control device according to any one of claims 1 to 4, wherein the resumable number of is calculated with a predetermined weight.
チャネルを共用する仮想マシン各々の入出力処理およびチャネル制御の状態を示す制御情報を前記記憶部に書き込む処理ステップと,
前記チャネルを共用する複数の仮想マシンのいずれかからIO命令を受け付けた場合に,前記チャネルがビジーであるときは,前記制御情報にもとづいて,該チャネルのビジー解除時にリスタートする仮想マシンの順序を決定する処理ステップと,
前記順序にもとづきリスタートする仮想マシンが,ビジー解除の通知を受けてIO命令を再発行するOSリスタートをするものであるときは,該仮想マシンへのビジー解除の通知時から該仮想マシンから受け付けたIO命令の処理完了時までの間,前記チャネルを共用する他の仮想マシンに対するビジー解除およびIO命令の処理を抑止し,前記リスタートする仮想マシンが,チャネルがビジーとなったIO命令を再発行しないハードウェア・リスタートをするものであるときは,該チャネルのビジー解除前に該仮想マシンから受け付けていたIO命令の処理を実行する処理ステップとを,実行する
ことを特徴とするチャネル制御方法。
A channel controller with a storage unit
A processing step of writing control information indicating the state of input / output processing and channel control of each virtual machine sharing a channel to the storage unit;
When an IO command is received from any of a plurality of virtual machines sharing the channel and the channel is busy, the order of virtual machines to be restarted when the channel is released busy based on the control information Processing steps for determining
When the virtual machine that is restarted based on the order is to perform OS restart that receives a busy release notification and reissues an IO instruction, the virtual machine starts from the time of the busy release notification to the virtual machine. Until the processing of the accepted IO instruction is completed, busy release to other virtual machines sharing the channel and processing of the IO instruction are suppressed, and the restarting virtual machine receives an IO instruction whose channel is busy. A hardware restart that does not reissue, and a processing step that executes the processing of the IO instruction received from the virtual machine before the busy release of the channel is executed. Control method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010224610A JP5533526B2 (en) | 2010-10-04 | 2010-10-04 | Channel control apparatus and method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010224610A JP5533526B2 (en) | 2010-10-04 | 2010-10-04 | Channel control apparatus and method |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2012079143A true JP2012079143A (en) | 2012-04-19 |
JP5533526B2 JP5533526B2 (en) | 2014-06-25 |
Family
ID=46239294
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2010224610A Expired - Fee Related JP5533526B2 (en) | 2010-10-04 | 2010-10-04 | Channel control apparatus and method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5533526B2 (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2021506037A (en) * | 2018-09-20 | 2021-02-18 | 中興通訊股▲ふん▼有限公司Zte Corporation | Network cards, time synchronization methods and devices, and computer storage media |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH07334455A (en) * | 1994-06-14 | 1995-12-22 | Mitsubishi Electric Corp | Data transferring method through bus |
JPH08180007A (en) * | 1994-12-22 | 1996-07-12 | Hitachi Ltd | Input/output processing system |
JPH1031630A (en) * | 1996-04-09 | 1998-02-03 | Internatl Business Mach Corp <Ibm> | Operation method and system for missing interruption handler |
JP2004005727A (en) * | 2003-07-24 | 2004-01-08 | Fujitsu Ltd | Input/output control unit, and input/output control method |
-
2010
- 2010-10-04 JP JP2010224610A patent/JP5533526B2/en not_active Expired - Fee Related
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH07334455A (en) * | 1994-06-14 | 1995-12-22 | Mitsubishi Electric Corp | Data transferring method through bus |
JPH08180007A (en) * | 1994-12-22 | 1996-07-12 | Hitachi Ltd | Input/output processing system |
JPH1031630A (en) * | 1996-04-09 | 1998-02-03 | Internatl Business Mach Corp <Ibm> | Operation method and system for missing interruption handler |
JP2004005727A (en) * | 2003-07-24 | 2004-01-08 | Fujitsu Ltd | Input/output control unit, and input/output control method |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2021506037A (en) * | 2018-09-20 | 2021-02-18 | 中興通訊股▲ふん▼有限公司Zte Corporation | Network cards, time synchronization methods and devices, and computer storage media |
US11609598B2 (en) | 2018-09-20 | 2023-03-21 | Zte Corporation | Network card, time synchronization methods and devices, and computer storage media |
Also Published As
Publication number | Publication date |
---|---|
JP5533526B2 (en) | 2014-06-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4603583B2 (en) | Processor, apparatus, and method | |
JP5405320B2 (en) | Virtual machine control device, virtual machine control method, and virtual machine control program | |
JP5469940B2 (en) | Computer system, virtual machine monitor, and virtual machine monitor scheduling method | |
JP3952992B2 (en) | Information processing apparatus, process control method, and computer program | |
JP2008186209A (en) | I/o device failure processing method for virtual computer system | |
RU2437144C2 (en) | Method to eliminate exception condition in one of nuclei of multinuclear system | |
TWI498820B (en) | Processor with second jump execution unit for branch misprediction | |
US9389923B2 (en) | Information processing device and method for controlling information processing device | |
TW200825923A (en) | Task processing device | |
US10379931B2 (en) | Computer system | |
JPWO2009150815A1 (en) | Multiprocessor system | |
JP5533526B2 (en) | Channel control apparatus and method | |
WO2006030564A1 (en) | Processor | |
CN105474174B (en) | Controlling time-intensive instructions | |
US8997111B2 (en) | System and method for deterministic context switching in a real-time scheduler | |
TWI549054B (en) | Enabling and disabling a second jump execution unit for branch misprediction | |
US20110231637A1 (en) | Central processing unit and method for workload dependent optimization thereof | |
JP2008204011A (en) | Multi-thread system and thread operation failure detecting method | |
JP2010015364A (en) | Multiprocessor system and information processor | |
JP5332716B2 (en) | Startup control method, information processing apparatus, and program | |
WO2022180893A1 (en) | Control device and control method | |
US20160364260A1 (en) | Event router and routing method for symmetric multiprocessor virtual machine using queue | |
US8069338B2 (en) | Data processing device and control method for preventing an exception caused by an instruction sent to a peripheral device by a branch source program from occurring during execution of a branch destination program or interrupt program | |
EP3276489A1 (en) | Parallel processing system | |
JP2007323256A (en) | Interruption control method and information processor |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20130805 |
|
TRDD | Decision of grant or rejection written | ||
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20140319 |
|
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20140401 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5533526 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20140414 |
|
LAPS | Cancellation because of no payment of annual fees |