JP2009258798A - Virtual machine system, host computer, i/o card, virtual machine construction method, and program - Google Patents
Virtual machine system, host computer, i/o card, virtual machine construction method, and program Download PDFInfo
- Publication number
- JP2009258798A JP2009258798A JP2008103914A JP2008103914A JP2009258798A JP 2009258798 A JP2009258798 A JP 2009258798A JP 2008103914 A JP2008103914 A JP 2008103914A JP 2008103914 A JP2008103914 A JP 2008103914A JP 2009258798 A JP2009258798 A JP 2009258798A
- Authority
- JP
- Japan
- Prior art keywords
- virtual machine
- host computer
- card
- virtual
- functions
- 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
本発明は、ホスト計算機上で動作する仮想マシンに関し、特にホスト計算機上で動作する複数の仮想マシンでのI/Oカードの使用に関する。 The present invention relates to a virtual machine that operates on a host computer, and more particularly to the use of an I / O card in a plurality of virtual machines that operate on a host computer.
コンピュータの仮想化技術は、ホスト計算機上に仮想的なコンピュータ(仮想マシン、Virtual Machine)をソフトウェア的に構築する技術である。しかしながら、仮想マシンから、ホスト計算機に物理的に接続されたグラフィックカード、浮動小数点演算アクセラレータ、生化学シミュレータのような拡張機器(以後I/Oカードという)を、複数の仮想マシンにおいて共有して利用したい用途もある。 The computer virtualization technology is a technology for constructing a virtual computer (virtual machine) on a host computer by software. However, an expansion device (hereinafter referred to as an I / O card) such as a graphic card, a floating point arithmetic accelerator, or a biochemical simulator that is physically connected to the host computer is shared by a plurality of virtual machines. There are also uses that you want to do.
仮想マシンからI/Oカードを利用する技術として、以下のような技術文献がある。特許文献1には、実行されるプログラムについてプログラム実行解釈部が使用禁止テーブルの内容を解釈して、使用が禁止されている機能が実行されないようにするという技術が記載されている。この技術は仮想マシンにおいても適用可能であるとされている。特許文献2には、複数の物理あるいは論理サーバがI/Oカードを共有する際に、アクセス要求に埋め込まれたサーバ識別子を用いてアクセス制御を行う方法が記載されている。
The following technical documents are available as a technology for using an I / O card from a virtual machine.
特許文献3には、I/Oカードを用いるための物理アドレスを仮想マシンに対して通知することにより、仮想マシンが仮想マシンモニタや特権仮想マシンのような別のプロセスを経由することなくホストのI/Oカードを使用できるという技術が記載されている。特許文献4には、あるコンピュータで実行されている仮想マシンを別の仮想マシンにマイグレーションする方法が記載されている。
In
特許文献5には、物理マシンと仮想マシンとの間でI/Oカードを共有するため、仮想I/Oアドレスと物理I/Oアドレスとの対応を割り当ててその情報を保持するという技術が記載されている。特許文献6には、複数の機能を持つI/Oカードで、仮想アドレスを物理アドレスに対応させて該I/Oカードの複数の機能を共有するという技術が記載されている。 Patent Document 5 describes a technique of assigning a correspondence between a virtual I / O address and a physical I / O address and holding the information in order to share an I / O card between a physical machine and a virtual machine. Has been. Patent Document 6 describes a technique of sharing a plurality of functions of an I / O card by associating a virtual address with a physical address in an I / O card having a plurality of functions.
I/Oカードが複数の区分に分けられる複数の機能を持つ場合、同一のホスト計算機上で動作する仮想マシンであっても、たとえばある仮想マシンからは該I/Oカードの全ての機能を使用可能とする一方で、別の仮想マシンからは該I/Oカードの特定の機能のみを使用可能としてその他の機能は使用不可能としたい場合がある。 When an I / O card has a plurality of functions that are divided into a plurality of sections, even if the virtual machine operates on the same host computer, for example, all the functions of the I / O card are used from a certain virtual machine On the other hand, there is a case where only a specific function of the I / O card can be used from another virtual machine and other functions cannot be used.
このような場合、特許文献1および2にあるように、特定の機能に対してアクセスが生じた場合に、該機能に対するアクセスが許可されているか否かをホスト計算機のCPUもしくは専用の判定回路が判断する技術はある。しかしながら、該機能に対するアクセスが生じるたびにCPUがそのような判断を行うようにすると、ただでさえ複数の仮想マシンに関する高負荷な処理を行っているCPUに対して、さらに負荷を増大させることとなる。また、専用のハードウェアである判定回路を追加することは、機器のコスト上昇につながる。
In such a case, as described in
特許文献3の方法では、I/Oカードを仮想マシンに割り当てる際にアクセスが可能であるかの判断を行っているが、単一のI/Oカードに対して占有させるか否かという程度の制御しか行えない。特許文献4〜6、さらには特許文献1〜6の全てを組み合わせた技術では、CPUの負荷およびその他のハードウェアのコストを増大させずに、仮想マシンごとおよびI/Oカードの機能ごとに使用の可否を制御できるようにするという技術は記載されていない。
In the method of
本発明の目的は、CPUの負荷およびその他のハードウェアのコストを増大させずに、仮想マシンごとおよびI/Oカードの機能ごとに使用の可否を制御できる仮想マシンシステム、ホスト計算機、I/Oカード、仮想マシンモニタ方法およびプログラムを提供することにある。 An object of the present invention is to provide a virtual machine system, a host computer, and an I / O capable of controlling the use of each virtual machine and each function of an I / O card without increasing the CPU load and other hardware costs. It is to provide a card, a virtual machine monitoring method, and a program.
上記目的を達成するため、本発明に係る仮想マシンシステムは、複数の仮想マシンが動作するホスト計算機と、ホスト計算機に接続されて該ホスト計算機に複数の機能を提供するI/Oカードとを備える仮想マシンシステムであって、I/Oカードが、複数の仮想マシンに対応し、各々が複数の機能の各々に対応する複数のページを有する複数の仮想マシンインタフェースを有し、各々の仮想マシンが、仮想マシン上における物理アドレスと、ホスト計算機上における仮想マシンインタフェースおよびページの物理アドレスとを変換するアドレス変換部を有することを特徴とする。 To achieve the above object, a virtual machine system according to the present invention includes a host computer on which a plurality of virtual machines operate, and an I / O card that is connected to the host computer and provides a plurality of functions to the host computer. A virtual machine system, wherein an I / O card corresponds to a plurality of virtual machines, each having a plurality of virtual machine interfaces having a plurality of pages corresponding to a plurality of functions, and each virtual machine And an address conversion unit that converts a physical address on the virtual machine and a physical address of the virtual machine interface and page on the host computer.
上記目的を達成するため、本発明に係るホスト計算機は、複数の仮想マシンが動作し、複数の仮想マシンに対応し、各々が複数の機能の各々に対応する複数のページを有する複数の仮想マシンインタフェースを有するI/Oカードを接続可能なホスト計算機であって、各々の仮想マシンが、仮想マシン上における物理アドレスと、ホスト計算機上における仮想マシンインタフェースおよびページの物理アドレスとを変換するアドレス変換部を有することを特徴とする。 To achieve the above object, a host computer according to the present invention has a plurality of virtual machines on which a plurality of virtual machines operate, correspond to a plurality of virtual machines, and each have a plurality of pages corresponding to a plurality of functions. Host computer to which an I / O card having an interface can be connected, and each virtual machine converts a physical address on the virtual machine and a virtual machine interface and page physical address on the host computer It is characterized by having.
上記目的を達成するため、本発明に係るI/Oカードは、複数の仮想マシンが動作するホスト計算機に接続されて該ホスト計算機に複数の機能を提供するI/Oカードであって、複数の仮想マシンに対応し、各々が複数の機能の各々に対応する複数のページを有する複数の仮想マシンインタフェースを有することを特徴とする。 To achieve the above object, an I / O card according to the present invention is an I / O card that is connected to a host computer on which a plurality of virtual machines operate and provides a plurality of functions to the host computer. It has a plurality of virtual machine interfaces each having a plurality of pages corresponding to each of a plurality of functions corresponding to a virtual machine.
上記目的を達成するため、本発明に係る仮想マシン構築方法は、複数の仮想マシンに対応し、各々が複数の機能の各々に対応する複数のページを有する複数の仮想マシンインタフェースを有するI/Oカードが接続されているホスト計算機で複数の仮想マシンを構築する方法であって、仮想マシン上における物理アドレスと、ホスト計算機上における仮想マシンインタフェースおよびページの物理アドレスとを変換するアドレス変換部を仮想マシンに提供するアドレス変換部提供工程と、各々の仮想マシンがアドレス変換部を利用してページにアクセスするアクセス工程とを有することを特徴とする。 In order to achieve the above object, a virtual machine construction method according to the present invention corresponds to a plurality of virtual machines, each of which has a plurality of virtual machine interfaces each having a plurality of pages corresponding to a plurality of functions. A method of constructing a plurality of virtual machines on a host computer to which a card is connected, in which an address conversion unit that converts a physical address on the virtual machine and a virtual machine interface and page physical address on the host computer is virtualized. An address conversion unit providing step to be provided to a machine, and an access step in which each virtual machine accesses a page using the address conversion unit.
上記目的を達成するため、本発明に係る仮想マシン構築プログラムは、複数の仮想マシンに対応し、各々が複数の機能の各々に対応する複数のページを有する複数の仮想マシンインタフェースを有するI/Oカードが接続されているホスト計算機に、ホスト計算機が備える複数の仮想マシンの各々に対する機能の各々の使用可否に関する情報を読み込む使用可否読み取り処理と、使用可否読み取り工程で使用可能である旨の情報が読み取られた機能について、仮想マシン上における物理アドレスとホスト計算機上における仮想マシンインタフェースおよびページの物理アドレスとを変換するアドレス変換部に仮想マシンインタフェースの物理アドレスを書き込むアドレス変換部書き込み処理とを実行させることを特徴とする。 To achieve the above object, a virtual machine construction program according to the present invention corresponds to a plurality of virtual machines, each of which has a plurality of virtual machine interfaces each having a plurality of pages corresponding to a plurality of functions. Information indicating that the host computer to which the card is connected can read the information on the availability of each of the functions for each of the plurality of virtual machines included in the host computer, and information that it can be used in the availability reading step. For the read function, the address conversion unit for writing the physical address of the virtual machine interface is executed in the address conversion unit that converts the physical address on the virtual machine and the virtual machine interface and the physical address of the page on the host computer. It is characterized by that.
本発明は、各々の仮想マシンが、仮想マシン上とホスト計算機上における物理アドレスとを変換するアドレス変換部を有するように構成したので、仮想マシンからI/Oカードの特定の機能に対するアクセスが生じるたびにCPUが各々の仮想マシンの各々の機能に対するアクセス権限を判断する必要はない。これによって、CPUの負荷およびその他のハードウェアのコストを増大させずに、仮想マシンごとおよびI/Oカードの機能ごとに使用の可否を制御できるという、従来にない優れた仮想マシンシステム、ホスト計算機、I/Oカード、仮想マシンモニタ方法およびプログラムを提供することができる。 In the present invention, each virtual machine is configured to have an address translation unit that translates physical addresses on the virtual machine and on the host computer, so that access to a specific function of the I / O card occurs from the virtual machine. It is not necessary for the CPU to determine the access authority for each function of each virtual machine each time. This makes it possible to control whether or not each virtual machine and each I / O card function can be used without increasing the CPU load and other hardware costs. , An I / O card, a virtual machine monitoring method, and a program can be provided.
[第1の実施の形態]
図1は、本発明の第1の実施の形態に係る仮想マシンシステム1の構成を示すブロック図である。仮想マシンシステム1は、ホスト計算機2にI/Oカード40が接続されてなる。ホスト計算機2は一般的なコンピュータ装置であり、CPU11、RAM12、およびブリッジ13を備える。CPU11およびRAM12は、いずれもコンピュータ装置においては一般的な演算装置および記憶装置であるが、各々が複数個備えられているものとしてもよい。
[First Embodiment]
FIG. 1 is a block diagram showing the configuration of the
ブリッジ13は拡張機器を接続してCPU11との間を中継する装置であり、CPU11はRAM12上で実行されているソフトウェアからの命令に基づいてブリッジ13を介して拡張機器を操作し、その結果を該ソフトウェアに対して出力することができる。なお、コンピュータ装置を構成するためにはこれら以外の要素も必要であるが、それらは当業者には公知であり、本実施の形態を説明する上では特に言及する必要はないので図示していない。
The
ブリッジ13には、I/Oカード40が接続される。I/Oカード40は、I/Oパケット転送部41と、複数の仮想マシンインタフェース42a〜42nから構成される。複数の仮想マシンインタフェース42a〜42nは各々、後述する複数台の仮想マシン30a〜30nに対応する。I/Oカード40は、他のデバイスからブリッジ13を介して受けた要求に応じて処理を行った後に、ブリッジ13を経由して出力を返戻する。
An I / O card 40 is connected to the
RAM12では、CPU11によって仮想マシンモニタ20が実行されている。仮想マシンモニタ20は、ホスト計算機2上に複数台の仮想マシン30a〜30nを構築するソフトウェアであり、後述するアドレス変換管理部21、I/O管理部22、仮想マシンインタフェース情報記憶部23、および仮想マシンI/Oサービス管理部24を備える。
In the
仮想マシンモニタ20に構築される複数台の仮想マシンのうちの1つである仮想マシン30aは、アプリケーション31a、OS32a、デバイスドライバ33a、および仮想マシンアドレス変換部34aを備え、OS32aによる制御でアプリケーション31aを実行する仮想的な計算機である。
A virtual machine 30a that is one of a plurality of virtual machines constructed in the virtual machine monitor 20 includes an application 31a, an
アプリケーション31aがブリッジ13に接続されているI/Oカード40を使用する場合、まずOS32aに対してそのことを要求する。OS32aは、アプリケーション31aからの要求に応じて、ハードウェア資源要求をデバイスドライバ33aに出力する。デバイスドライバ33aは、OS32aからの要求に応じて、仮想マシンモニタ20に対してハードウェア使用要求を出力する。仮想マシンモニタ20がデバイスドライバ33aからの要求に応じてI/Oカード40を使用して動作結果を得ると、その動作結果はデバイスドライバ33aとOS32aとを経由してアプリケーション31aに返される。
When the application 31a uses the I / O card 40 connected to the
仮想マシンアドレス変換部34aは、仮想マシン30a内で用いる物理アドレスと、ホスト計算機2で用いる物理アドレスとを対応させる対応表である。仮想マシンアドレス変換部34aは、仮想マシンモニタ20によって書き換えが行われ、仮想マシン30aからは読み出しのみが可能である。
The virtual machine
仮想マシンモニタ20に構築されるその他の仮想マシン30b〜30nの構成および機能も、仮想マシン30aの構成と同一である。以後、たとえば仮想マシン30bはアプリケーション31b、OS32b、デバイスドライバ33b、および仮想マシンアドレス変換部34bを備える…などのように、各仮想マシンの構成要素を表記する。 The configurations and functions of the other virtual machines 30b to 30n constructed in the virtual machine monitor 20 are also the same as the configuration of the virtual machine 30a. Hereinafter, for example, the virtual machine 30b includes the application 31b, the OS 32b, the device driver 33b, the virtual machine address conversion unit 34b, and so on, and the like, and the like.
仮想マシンモニタ20で、アドレス変換管理部21は、I/O管理部22が保持する情報を元に、各仮想マシン30a〜30n内で保持されている仮想マシンアドレス変換部34a〜34nの情報を書き換える。I/O管理部22は、アドレス変換管理部21からの指示によって、仮想マシンインタフェース情報記憶部23と、仮想マシンI/Oサービス管理部24から、ホスト計算機2の物理アドレス空間に対し、I/Oカード40の仮想マシンインタフェース42a〜42nをどのようにマップされるべきかの情報を読み込む。
In the virtual machine monitor 20, the address
アドレス変換管理部21は、仮想マシン30a〜30nのうちいずれかが起動する際、I/Oカード40がブリッジ13に接続される際、もしくは仮想マシンインタフェース情報記憶部23および仮想マシンI/Oサービス管理部24のうち少なくともいずれかに保持された情報が変更された際に動作し、仮想マシンアドレス変換部34a〜34nの中で起動される仮想マシンに該当するものを書き換える。なお、仮想マシンインタフェース情報記憶部23および仮想マシンI/Oサービス管理部24に保持された情報を変更する手段および方法については任意である。
The address
仮想マシンインタフェース情報記憶部23は、I/Oカード40の仮想マシンインタフェース42a〜42nの機能と領域の対応関係に関する情報を保持する。仮想マシンI/Oサービス管理部24は、仮想マシン30b〜30nに対し、I/Oカード40の機能のどの部分を使用することが可能であるかの設定情報を保持する。なお、仮想マシンインタフェース情報記憶部23と、仮想マシンI/Oサービス管理部24とに記憶される情報は、あらかじめ設定されているものとする。
The virtual machine interface
以下、仮想マシンモニタ20の管理下で仮想マシン30aおよび30bという2台の仮想マシンが動作している場合の一例に基づいて、各動作部が記憶しているデータの内容およびホスト計算機2で行われる動作の内容を説明する。また、この例ではホスト計算機2は1つのみのブリッジ13を備え、ブリッジ13に1つのみのI/Oカード40が接続され、I/Oカード40の持つ機能は基本機能と拡張機能という2種類の区分に分かれているものとする。
Hereinafter, based on an example in which two virtual machines 30a and 30b are operating under the control of the virtual machine monitor 20, the contents of data stored in each operation unit and the
図2は、図1で示したI/Oカード40が有する仮想マシンインタフェース42aおよび42bの構成を示す概念図である。仮想マシンインタフェース42aおよび42bは、それぞれ仮想マシン30aおよび30bに対応するものであり、それぞれRAM12のメモリページシステム3ページ相当の大きさを持つ。以後、仮想マシンインタフェース42aの持つページはページ101a1〜a3、仮想マシンインタフェース42bの持つページはページ101b1〜b3とのように表記する。
FIG. 2 is a conceptual diagram showing the configuration of the
図3は、図1で示した仮想マシンインタフェース情報記憶部23が保持する情報の内容の一例を示す概念図である。仮想マシンインタフェース情報記憶部23は、対象となるデバイスを表すデバイス名111と、RAM12のメモリページシステム上の何ページ目かを表すページ112と各ページが表す機能113といったデータを含む。
FIG. 3 is a conceptual diagram showing an example of the content of information held by the virtual machine interface
ここでは、デバイス名111がI/Oカード40で、ページ112の1〜2ページ目で機能113が「基本機能」、ページ112の3ページ目で機能113が「拡張機能」を表している。これは、図2で示した仮想マシンインタフェース42aおよび42bにおいて、1ページ目と2ページ目が基本機能、3ページ目が拡張機能を実現するものであることを意味する。
Here, the
図4は、図1で示した仮想マシンI/Oサービス管理部24が保持する情報の内容の一例を示す概念図である。仮想マシンI/Oサービス管理部24は、対象となる仮想マシンおよびI/Oカードを表す仮想マシン名121およびI/Oカード名122と、基本機能および拡張機能の別を表す機能区分123と、各々の機能に対するアクセス権124といったデータを含む。
FIG. 4 is a conceptual diagram showing an example of the content of information held by the virtual machine I / O
ここでは、仮想マシン30aは、I/Oカード40の基本機能のみの使用が許可され、拡張機能の使用は不許可である。そして仮想マシン30bは、I/Oカード40の基本機能および拡張機能の両方の使用が許可される。以上の旨を示すデータが、仮想マシンI/Oサービス管理部24に記憶されている。
Here, the virtual machine 30a is permitted to use only the basic functions of the I / O card 40 and is not permitted to use the extended functions. The virtual machine 30b is permitted to use both basic functions and extended functions of the I / O card 40. Data indicating the above is stored in the virtual machine I / O
I/O管理部22は、仮想マシンインタフェース情報記憶部23に保持されたI/Oカード40についての情報と、仮想マシンI/Oサービス管理部24に保持された仮想マシン毎のアクセス権情報を元に、RAM12上の物理メモリアドレス空間と仮想マシンインタフェース42aおよび42bのマッピングを行う。
The I /
図5は、図1で示したRAM12上のアドレス空間200における仮想マシンインタフェース42aおよび42bのマッピングの様子を示す概念図である。アドレス空間200は、仮想マシンインタフェース42aおよび42bのためにRAM12上に確保されている。
FIG. 5 is a conceptual diagram showing how the
前述のように、仮想マシン30aは、I/Oカード40の基本機能のみの使用が許可され、拡張機能の使用は不許可であるとする情報が仮想マシンI/Oサービス管理部24に記憶されている。このため、I/O管理部22は仮想マシンインタフェース情報記憶部23を参照して、仮想マシンインタフェース42aはページ101a1〜a2が基本機能に該当し、ページ101a3が拡張機能に該当するとの情報を得る。これに基づいてアドレス変換管理部21は、基本機能に該当するページ101a1〜a2のみをアドレス空間200内にマッピングする。拡張機能に該当するページ101a3はマッピングしない。仮想マシンインタフェース42bはページ101b1〜b3に該当する基本機能および拡張機能の両方の使用が許可されるので、ページ101b1〜b3の全てがアドレス空間200内にマッピングされる。
As described above, the virtual machine 30a is stored in the virtual machine I / O
図5に示した例では、アドレス空間200の中で、物理アドレス0x10000に仮想マシンインタフェース42aのページ101a1、物理アドレス0x11000に仮想マシンインタフェース42aのページ101a2がマッピングされる。また物理アドレス0x25000に仮想マシンインタフェース42bのページ101b1、物理アドレス0x26000に仮想マシンインタフェース42bのページ101b2、物理アドレス0x27000に仮想マシンインタフェース42bのページ101b3がそれぞれマッピングされる。このアドレス空間200上のマッピングに基づいて、仮想マシン30aおよび30bは各々、仮想マシンインタフェース42aおよび42bとのデータ交換を行うことができる。
In the example shown in FIG. 5, in the
図6は、図1で示したアドレス変換管理部21によって作成される仮想マシンアドレス変換部34aおよび34bの内容の一例を示す概念図である。また図7は、図1で示したアドレス変換管理部21が図6に示した仮想マシンアドレス変換部34aおよび34bを作成する動作を表すフローチャートである。
FIG. 6 is a conceptual diagram showing an example of the contents of the virtual
アドレス変換管理部21は、仮想マシン30aもしくは30bが動作開始する際、ブリッジ13にI/Oカード40が接続される際、もしくは仮想マシンインタフェース情報記憶部23および仮想マシンI/Oサービス管理部24に保持された情報が変更された際に動作を開始して、仮想マシンインタフェース情報記憶部23に保持されたI/Oカード40についての情報と、仮想マシンI/Oサービス管理部24に保持された仮想マシン毎のアクセス権情報とを、I/O管理部22を介して読み込む(ステップS301〜2)。そしてアドレス空間200内にマッピングされた各ページについての情報も読み込む(ステップS303)。
The address
アドレス変換管理部21は、以上で読み込んだ情報に基づいて、仮想マシンI/Oサービス管理部24で起動される仮想マシンの仮想マシン名121、I/Oカード名122および機能区分123のうちのいずれかに対して、対応するアクセス権124について判断する(ステップS304〜305)。アクセス権124が「許可」であれば、該当する仮想マシン名121の仮想マシンアドレス変換部34aもしくは34bに、該当する情報を書き込む(ステップS306)。アクセス権124が「不許可」であれば書き込まない。
Based on the information read above, the address
アドレス変換管理部21は、ステップS305〜306の処理を、該当する仮想マシン名121、I/Oカード名122および機能区分123の全てに対して行ったかを判断し(ステップS307)、完了していなければ他の仮想マシン名121、I/Oカード名122および機能区分123に移動してステップS305からの処理を繰り返す(ステップS308)。ステップS307で「完了した」と判断されれば、アドレス変換管理部21は該当する仮想マシンの動作を開始させ(ステップS309)、自らの動作を終了する。
The address
図6に示される各仮想マシンの仮想マシンアドレス変換部34aもしくは34bには、I/Oカード名122および機能区分123ごとに、対応するアドレス空間200内のアドレス131と、仮想マシン30aもしくは30bのアドレス空間210の物理アドレス132とが書き込まれる。その際、アクセス権124が「許可」である機能区分123についてのみ書き込まれ、アクセス権124が「不許可」であれば書き込まれない。
The virtual machine
図6(a)は、仮想マシン30aの仮想マシンアドレス変換部34aである。アプリケーション31aがI/Oカード40の基本機能にアクセスしたい場合、仮想マシン30aのアドレス空間210の物理アドレス0x00000にアクセスすると、デバイスドライバ33aは仮想マシンアドレス変換部34aを参照して、RAM12のアドレス空間200のアドレス0x10000にアクセスすることができる。ただしI/Oカード40の拡張機能に対応するエントリは仮想マシンアドレス変換部34aには存在しないので、仮想マシン30aにとってはI/Oカード40の拡張機能はそもそも存在しないのと同じことになり、もちろんアクセスすることはできない。
FIG. 6A illustrates the virtual machine
図6(b)は、仮想マシン30bの仮想マシンアドレス変換部34bである。アプリケーション31aがI/Oカード40の基本機能にアクセスしたい場合、仮想マシン30bのアドレス空間210の物理アドレス0x00000にアクセスすると、デバイスドライバ33bは仮想マシンアドレス変換部34bを参照して、RAM12のアドレス空間200のアドレス0x25000にアクセスする。同様に、アプリケーション31aがI/Oカード40の拡張機能にアクセスしたい場合、仮想マシン30bのアドレス空間210の物理アドレス0x02000にアクセスすると、デバイスドライバ33bは仮想マシンアドレス変換部34bを参照して、RAM12のアドレス空間200のアドレス0x27000にアクセスする。これによって仮想マシン30bは、I/Oカード40の基本機能と拡張機能の両方にアクセスできる。
FIG. 6B illustrates the virtual machine address conversion unit 34b of the virtual machine 30b. When the application 31a wants to access the basic function of the I / O card 40, when accessing the physical address 0x00000 in the
これによって、I/Oカード40上の基本機能には仮想マシン30aおよび30bの両方からのアクセスを許可し、拡張機能には仮想マシン30bからのアクセスのみを許可して仮想マシン30aからのアクセスを遮断するという動作が可能となった。 As a result, access from both the virtual machines 30a and 30b is permitted to the basic function on the I / O card 40, and access from the virtual machine 30b is permitted to the extended function, and access from the virtual machine 30a is permitted. The operation of blocking is now possible.
図7に示した動作は、仮想マシン30aもしくは30bが動作開始する際、ブリッジ13にI/Oカード40が接続される際、もしくは仮想マシンインタフェース情報記憶部23および仮想マシンI/Oサービス管理部24のうち少なくともいずれかに保持された情報が変更された際にのみ行われ、通常動作時においてCPU11に常駐するものではない。従って、各々の仮想マシンからI/Oカード40を使用する要求があるたびにCPU11がそれらのアクセス権限について判断する必要はないので、通常動作時におけるCPU11に対する負荷を増大させることはない。
The operation shown in FIG. 7 is performed when the virtual machine 30a or 30b starts operating, when the I / O card 40 is connected to the
本実施の形態では、以上に述べたように仮想マシンアドレス変換部34aおよび34bを備えることによって、通常動作時におけるCPU11に対する負荷を増大させることなく、複数の仮想マシンの各々に対して異なるサービスレベルを提供することができる。この動作は、各々のソフトウェアをわずかに改変するだけで実施でき、ハードウェアの変更を必要とはしない。
In the present embodiment, as described above, by providing the virtual machine
以上に述べた動作は、3台以上の仮想マシンの場合、ブリッジ13に複数のI/Oカード40が接続されている場合、およびI/Oカード40の機能が3つ以上の区分に分かれる場合にも容易に拡張できる。もちろん、I/Oカード40の機能が実際には何であるかについても不問である。
The operations described above are for three or more virtual machines, when a plurality of I / O cards 40 are connected to the
[第2の実施の形態]
図8は、本発明の第2の実施の形態に係る仮想マシンシステム1bの構成を示すブロック図である。仮想マシンシステム1bは、ホスト計算機2bにI/Oカード40bが接続されてなる。ホスト計算機2bに含まれる仮想マシンモニタ20bは、第1の実施の形態に係るホスト計算機2に含まれる仮想マシンモニタ20と比べて、仮想マシンインタフェース情報記憶部23が省略されている。そのかわりI/Oカード40bは、第1の実施の形態に係るI/Oカード40と比べて、仮想マシンインタフェース情報記憶部43が追加されている。これ以外は、仮想マシンシステム1bの構成は第1の実施の形態に係る仮想マシンシステム1と同一であるので、これ以上の説明を省略する。
[Second Embodiment]
FIG. 8 is a block diagram showing the configuration of the
仮想マシンインタフェース情報記憶部43は、第1の実施の形態に係る仮想マシンインタフェース情報記憶部23と同じく、仮想マシンインタフェース42a〜42nの機能と領域の対応関係に関する情報を保持する。そして仮想マシンインタフェース情報記憶部43に記憶された情報は、仮想マシンモニタ20bのI/O管理部22から参照可能である。
Similar to the virtual machine interface
図9は、図8で示した仮想マシンインタフェース情報記憶部43が保持する情報の内容の一例を示す概念図である。仮想マシンインタフェース情報記憶部43は、各々のI/Oカード40についてのみの情報を保持する。従って、第1の実施の形態に係る仮想マシンインタフェース情報記憶部23と比べてデバイス名111が省略され、ページ112と機能113などのデータを含んでいる。
FIG. 9 is a conceptual diagram showing an example of the content of information held by the virtual machine interface
このようにしても、第2の実施の形態に係る仮想マシンシステム1bは、第1の実施の形態に係る仮想マシンシステム1と同一の動作を行うことができ、同一の効果を得ることができる。よって、これ以上の構成および動作についての説明を省略する。
Even in this case, the
[その他の実施の形態]
以上で説明した第1および第2の実施の形態以外にも、次に示すような変形が考えられる。たとえば、CPUをブリッジを介してI/Oカードと接続するかわりに、CPUとI/Oカードとを直結するようにしてもよい。また、I/Oカードをホスト計算機と接続するI/Oパケット転送部のかわりに、バスインタフェースを利用して接続するようにしてもよい。
[Other embodiments]
In addition to the first and second embodiments described above, the following modifications are possible. For example, instead of connecting the CPU to the I / O card via a bridge, the CPU and the I / O card may be directly connected. Further, instead of the I / O packet transfer unit that connects the I / O card to the host computer, it may be connected using a bus interface.
さらに、仮想マシン上のアプリケーションがOSおよびデバイスドライバを介してアクセス要求を行うかわりに、OSとデバイスドライバのうちの両方あるいは片方を省略して、アプリケーションがより直接的に仮想マシンに対してアクセス要求を行うようにすることもできる。当然ながら、以上に述べた実施の形態およびその変形を、相互に組み合わせて実施することもできる。 Further, instead of the application on the virtual machine making an access request via the OS and the device driver, both or one of the OS and the device driver is omitted, and the application requests the virtual machine more directly. It is also possible to perform. Of course, the above-described embodiment and its modifications can be implemented in combination with each other.
これまで本発明について図面に示した特定の実施の形態をもって説明してきたが、本発明は図面に示した実施の形態に限定されるものではなく、本発明の効果を奏する限り、これまで知られたいかなる構成であっても採用することができることは言うまでもないことである。 Although the present invention has been described with the specific embodiments shown in the drawings, the present invention is not limited to the embodiments shown in the drawings, and is known so far as long as the effects of the present invention are achieved. It goes without saying that any configuration can be adopted.
複数の仮想マシンを構築して動作する計算機において利用可能である。 It can be used in a computer that operates by constructing a plurality of virtual machines.
1、1b 仮想マシンシステム
2、2b ホスト計算機
11 CPU
12 RAM
13 ブリッジ
20、20b 仮想マシンモニタ
21 アドレス変換管理部
22 I/O管理部
23、43 仮想マシンインタフェース情報記憶部
24 仮想マシンI/Oサービス管理部
30a〜n 仮想マシン
31a〜n アプリケーション
32a〜n OS
33a〜n デバイスドライバ
34a〜n 仮想マシンアドレス変換部
40a〜n I/Oカード
41 I/Oパケット転送部
42a〜n 仮想マシンインタフェース
1, 1b
12 RAM
13 Bridge 20, 20b Virtual machine monitor 21 Address conversion management unit 22 I /
33a-
Claims (19)
前記I/Oカードが、前記複数の仮想マシンに対応し、各々が前記複数の機能の各々に対応する複数のページを有する複数の仮想マシンインタフェースを有し、
各々の前記仮想マシンが、前記仮想マシン上における物理アドレスと、前記ホスト計算機上における前記仮想マシンインタフェースおよび前記ページの物理アドレスとを変換するアドレス変換部を有することを特徴とする仮想マシンシステム。 A virtual machine system comprising a host computer on which a plurality of virtual machines operate, and an I / O card connected to the host computer and providing a plurality of functions to the host computer,
The I / O card has a plurality of virtual machine interfaces corresponding to the plurality of virtual machines, each having a plurality of pages corresponding to each of the plurality of functions;
Each of the virtual machines has an address conversion unit that converts a physical address on the virtual machine and a physical address of the virtual machine interface and the page on the host computer.
前記複数の仮想マシンの各々に対する前記機能の各々の使用可否に関する情報を保持する仮想マシンI/Oサービス管理部と、
各々の前記複数の仮想マシンの前記アドレス変換部に、使用可能である旨の情報を前記仮想マシンI/Oサービス管理部が保持している前記機能について前記仮想マシンインタフェースの物理アドレスを書き込むアドレス変換管理部と
を有することを特徴とする、請求項1に記載の仮想マシンシステム。 The host computer is
A virtual machine I / O service management unit that holds information about availability of each of the functions for each of the plurality of virtual machines;
Address conversion for writing the physical address of the virtual machine interface for the function held by the virtual machine I / O service management unit to the address conversion unit of each of the plurality of virtual machines. The virtual machine system according to claim 1, further comprising a management unit.
各々の前記仮想マシンが、前記仮想マシン上における物理アドレスと、前記ホスト計算機上における前記仮想マシンインタフェースおよび前記ページの物理アドレスとを変換するアドレス変換部を有することを特徴とするホスト計算機。 Host computer capable of connecting an I / O card having a plurality of virtual machine interfaces on which a plurality of virtual machines operate, corresponding to the plurality of virtual machines, each having a plurality of pages corresponding to each of the plurality of functions Because
Each of the virtual machines includes an address conversion unit that converts a physical address on the virtual machine and a physical address of the virtual machine interface and the page on the host computer.
各々の前記複数の仮想マシンの前記アドレス変換部に、使用可能である旨の情報を前記仮想マシンI/Oサービス管理部が保持している前記機能について前記仮想マシンインタフェースの物理アドレスを書き込むアドレス変換管理部と
を有することを特徴とする、請求項7に記載のホスト計算機。 A virtual machine I / O service management unit that holds information about availability of each of the functions for each of the plurality of virtual machines;
Address conversion for writing the physical address of the virtual machine interface for the function held by the virtual machine I / O service management unit to the address conversion unit of each of the plurality of virtual machines. The host computer according to claim 7, further comprising a management unit.
前記複数の仮想マシンに対応し、各々が前記複数の機能の各々に対応する複数のページを有する複数の仮想マシンインタフェースを有することを特徴とするI/Oカード。 An I / O card that is connected to a host computer on which a plurality of virtual machines operate and provides a plurality of functions to the host computer,
An I / O card comprising a plurality of virtual machine interfaces corresponding to the plurality of virtual machines, each having a plurality of pages corresponding to each of the plurality of functions.
前記仮想マシン上における物理アドレスと、前記ホスト計算機上における前記仮想マシンインタフェースおよび前記ページの物理アドレスとを変換するアドレス変換部を前記仮想マシンに提供するアドレス変換部提供工程と、
各々の前記仮想マシンが前記アドレス変換部を利用して前記ページにアクセスするアクセス工程と
を有することを特徴とする仮想マシン構築方法。 Method of constructing a plurality of virtual machines by a host computer to which an I / O card having a plurality of virtual machine interfaces corresponding to a plurality of virtual machines and having a plurality of pages each corresponding to each of a plurality of functions is connected Because
An address conversion unit providing step for providing the virtual machine with an address conversion unit for converting a physical address on the virtual machine and a physical address of the virtual machine interface and the page on the host computer;
Each virtual machine includes an access step of accessing the page by using the address conversion unit.
前記ホスト計算機が備える前記複数の仮想マシンの各々に対する前記機能の各々の使用可否に関する情報を読み込む使用可否読み取り工程と、
前記使用可否読み取り工程で使用可能である旨の情報が読み取られた前記機能について、各々の前記複数の仮想マシンの前記アドレス変換部に前記仮想マシンインタフェースの物理アドレスを書き込むアドレス変換部書き込み工程と
を含むことを特徴とする、請求項15に記載の仮想マシン構築方法。 The address conversion unit providing step includes:
An availability reading step of reading information on availability of each of the functions for each of the plurality of virtual machines included in the host computer;
An address conversion unit writing step of writing a physical address of the virtual machine interface to the address conversion unit of each of the plurality of virtual machines for the function for which the information indicating that it can be used is read in the availability reading step. The virtual machine construction method according to claim 15, further comprising:
前記ホスト計算機もしくは前記I/Oカードが備える前記複数のページの各々が前記複数の機能のうちのいずれに対応するかに関する情報を読み込むページ情報読み取り工程を有することを特徴とする、請求項16に記載の仮想マシン構築方法。 The address conversion unit providing step includes:
The page information reading step of reading information on which of the plurality of functions each of the plurality of pages included in the host computer or the I / O card corresponds to. The described virtual machine construction method.
前記ホスト計算機が備える前記複数の仮想マシンの各々に対する前記機能の各々の使用可否に関する情報を読み込む使用可否読み取り処理と、
前記使用可否読み取り工程で使用可能である旨の情報が読み取られた前記機能について、前記仮想マシン上における物理アドレスと前記ホスト計算機上における前記仮想マシンインタフェースおよび前記ページの物理アドレスとを変換するアドレス変換部に前記仮想マシンインタフェースの物理アドレスを書き込むアドレス変換部書き込み処理と
を実行させることを特徴とする仮想マシン構築プログラム。 To a host computer to which an I / O card having a plurality of virtual machine interfaces corresponding to a plurality of virtual machines and having a plurality of pages each corresponding to each of a plurality of functions is connected,
An availability read process for reading information on availability of each of the functions for each of the plurality of virtual machines included in the host computer;
Address conversion for converting the physical address on the virtual machine and the virtual machine interface and the physical address of the page on the host computer for the function for which the information indicating that it can be used is read in the availability reading step. A virtual machine construction program that causes an address conversion unit writing process to write a physical address of the virtual machine interface to the unit.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008103914A JP5104501B2 (en) | 2008-04-11 | 2008-04-11 | Virtual machine system, host computer, virtual machine construction method and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008103914A JP5104501B2 (en) | 2008-04-11 | 2008-04-11 | Virtual machine system, host computer, virtual machine construction method and program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2009258798A true JP2009258798A (en) | 2009-11-05 |
JP5104501B2 JP5104501B2 (en) | 2012-12-19 |
Family
ID=41386163
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2008103914A Expired - Fee Related JP5104501B2 (en) | 2008-04-11 | 2008-04-11 | Virtual machine system, host computer, virtual machine construction method and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5104501B2 (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2011117955A1 (en) * | 2010-03-20 | 2011-09-29 | 株式会社Pfu | Virtual machine management device, virtual machine management system, virtual machine management method, and program |
JP2012021711A (en) * | 2010-07-15 | 2012-02-02 | Fujitsu Ltd | System and method for controlling air conditioning |
JP2015069524A (en) * | 2013-09-30 | 2015-04-13 | 富士通株式会社 | Information processor, storage control device, and program |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS60142429A (en) * | 1983-12-28 | 1985-07-27 | Hitachi Ltd | Method and apparatus for executing input/output of virtual computer system |
JPS62171066A (en) * | 1986-01-17 | 1987-07-28 | インタ−ナショナル ビジネス マシ−ンズ コ−ポレ−ション | Virtual memory/virtual computer type data processing system having co-processor |
JP2002041170A (en) * | 2000-07-27 | 2002-02-08 | Matsushita Electric Ind Co Ltd | Program performance controller |
JP2005322242A (en) * | 2004-04-30 | 2005-11-17 | Microsoft Corp | Provision of direct access from virtual environment to hardware |
JP2007148621A (en) * | 2005-11-25 | 2007-06-14 | Hitachi Ltd | Computer system |
JP2007518160A (en) * | 2003-12-18 | 2007-07-05 | サンディスク コーポレイション | Multi-module circuit card with direct memory access between modules |
JP2008033449A (en) * | 2006-07-26 | 2008-02-14 | Nec Corp | System and method for sharing input/output transfer device and program |
-
2008
- 2008-04-11 JP JP2008103914A patent/JP5104501B2/en not_active Expired - Fee Related
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS60142429A (en) * | 1983-12-28 | 1985-07-27 | Hitachi Ltd | Method and apparatus for executing input/output of virtual computer system |
JPS62171066A (en) * | 1986-01-17 | 1987-07-28 | インタ−ナショナル ビジネス マシ−ンズ コ−ポレ−ション | Virtual memory/virtual computer type data processing system having co-processor |
JP2002041170A (en) * | 2000-07-27 | 2002-02-08 | Matsushita Electric Ind Co Ltd | Program performance controller |
JP2007518160A (en) * | 2003-12-18 | 2007-07-05 | サンディスク コーポレイション | Multi-module circuit card with direct memory access between modules |
JP2005322242A (en) * | 2004-04-30 | 2005-11-17 | Microsoft Corp | Provision of direct access from virtual environment to hardware |
JP2007148621A (en) * | 2005-11-25 | 2007-06-14 | Hitachi Ltd | Computer system |
JP2008033449A (en) * | 2006-07-26 | 2008-02-14 | Nec Corp | System and method for sharing input/output transfer device and program |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2011117955A1 (en) * | 2010-03-20 | 2011-09-29 | 株式会社Pfu | Virtual machine management device, virtual machine management system, virtual machine management method, and program |
JP5403446B2 (en) * | 2010-03-20 | 2014-01-29 | 株式会社Pfu | Virtual machine management apparatus, virtual machine management system, virtual machine management method, and program |
JP2012021711A (en) * | 2010-07-15 | 2012-02-02 | Fujitsu Ltd | System and method for controlling air conditioning |
JP2015069524A (en) * | 2013-09-30 | 2015-04-13 | 富士通株式会社 | Information processor, storage control device, and program |
Also Published As
Publication number | Publication date |
---|---|
JP5104501B2 (en) | 2012-12-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP2929439B1 (en) | Using a logical to physical map for direct user space communication with a data storage device | |
JP5735070B2 (en) | Guest address to host address translation for devices to access memory in partitioned systems | |
EP2929438B1 (en) | Using a virtual to physical map for direct user space communication with a data storage device | |
US8112610B2 (en) | Partition bus | |
US8595723B2 (en) | Method and apparatus for configuring a hypervisor during a downtime state | |
US8151275B2 (en) | Accessing copy information of MMIO register by guest OS in both active and inactive state of a designated logical processor corresponding to the guest OS | |
US20170123996A1 (en) | Direct Mapped Files in Virtual Address-Backed Virtual Machines | |
EP1628215A2 (en) | Systems and methods for running a legacy 32-bit X86 virtual machine on a 64-bit X86 processor | |
CN105830026A (en) | Apparatus and method for scheduling graphics processing unit workloads from virtual machines | |
EP3594807A1 (en) | Virtual disk file format conversion method and device | |
CN103034524A (en) | Paravirtualized virtual GPU | |
US9146879B1 (en) | Virtual memory management for real-time embedded devices | |
JP2007183952A (en) | Method by which guest is accessing memory converted device and apparatus | |
US10671419B2 (en) | Multiple input-output memory management units with fine grained device scopes for virtual machines | |
WO2013088818A1 (en) | Virtual computer system, virtualization mechanism, and data management method | |
US8566479B2 (en) | Method and system to allow logical partitions to access resources | |
US7389398B2 (en) | Methods and apparatus for data transfer between partitions in a computer system | |
JP5104501B2 (en) | Virtual machine system, host computer, virtual machine construction method and program | |
CN112330229B (en) | Resource scheduling method, device, electronic equipment and computer readable storage medium | |
US11150928B2 (en) | Hypervisor translation bypass | |
US10185679B2 (en) | Multi-queue device assignment to virtual machine groups | |
JP2019164661A (en) | Information processing device, information processing method and program | |
GB2568301A (en) | Address space access control | |
US8813075B2 (en) | Virtual computer system and method of installing virtual computer system | |
CN117857253A (en) | Inter-domain communication method based on jailhouse smmu |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20110315 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20120608 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20120619 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20120809 |
|
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: 20120904 |
|
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20120917 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5104501 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20151012 Year of fee payment: 3 |
|
LAPS | Cancellation because of no payment of annual fees |