<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<htmlxmlns="http://www.w3.org/1999/xhtml"><head><metahttp-equiv="Content-Type"content="text/html; charset=ISO-8859-1"/><linkrel="stylesheet"type="text/css"href="libvir.css"/><title>libvir architecture</title></head><body><divid="container"><divid="intro"><divid="adjustments"></div><divid="pageHeader"></div><divid="content2"><h1class="style1">libvir architecture</h1><p>In a Xen environment, programs using libvir have to execute in "Domain 0",
which is the primary Linux OS loaded on the machine. That OS kernel provides
most if not all of the actual drivers used by the set of domains. It also
runs the Xen Store, a database of informations shared by the hypervisor, the
kernels, the drivers and the xen daemon. Xend, the xen daemon, also runs in
Domain0 and supervise the control and execution of the sets of domains. The
hypervisor, drivers, kernels and daemons communicate though a shared system
bus implemented in the hypervisor. The figure below tries to provide a view
of this environment:</p><imgsrc="architecture.gif"alt="The Xen architecture"/><p>The library can be initialized in 2 ways depending on the level of
<htmlxmlns="http://www.w3.org/1999/xhtml"><head><metahttp-equiv="Content-Type"content="text/html; charset=ISO-8859-1"/><linkrel="stylesheet"type="text/css"href="libvir.css"/><title>libvir architecture</title></head><body><divid="container"><divid="intro"><divid="adjustments"></div><divid="pageHeader"></div><divid="content2"><h1class="style1">libvir architecture</h1><p>When running in a Xen environment, programs using libvir have to execute
in "Domain 0", which is the primary Linux OS loaded on the machine. That OS
kernel provides most if not all of the actual drivers used by the set of
domains. It also runs the Xen Store, a database of informations shared by the
hypervisor, the kernels, the drivers and the xen daemon. Xend. The xen daemon
supervise the control and execution of the sets of domains. The hypervisor,
drivers, kernels and daemons communicate though a shared system bus
implemented in the hypervisor. The figure below tries to provide a view of
this environment:</p><imgsrc="architecture.gif"alt="The Xen architecture"/><p>The library can be initialized in 2 ways depending on the level of
priviledge of the embedding program. If it runs with root access,
virConnectOpen() can be used, it will use three different ways to connect to
the Xen infrastructure:</p><ul><li>a connection to the Xen Daemon though an HTTP RPC layer</li>
<li>a read/write connection to the Xen Store</li>
<li>use Xen Hypervisor calls</li>
</ul><p> If it runs without root access virConnectOpenReadOnly() should be used,
it will try to open the read-only socket
</ul><p>The library will usually interract with the Xen daemon for any operation
changing the state of the system, but for performance and accuracy reasons
may talk directly to the hypervisor when gathering state informations at
least when possible (i.e. when the running program using libvir has root
priviledge access). </p><p> If it runs without root access virConnectOpenReadOnly() should be used to
connect to initialize the library. It will try to open the read-only socket
<code>/var/run/xenstored/socket_ro</code> to connect to the Xen Store and
also try to use the RPC to the Xen daemon. In this case use of hypervisor
calls and write to the Xen Store will not be possible, restraining the amount
@@ -6,5 +6,5 @@ archive</a>. Please subscribe to this list before posting by visiting the <a hre
page and follow the instructions. Patches with explanations and provided as
attachments are really appreciated and will be discussed on the mailing list.
If possible generate the patches by using cvs diff -u in a CVS checkout.</p><p>We expect to use <ahref="https://bugzilla.redhat.com/">Red Hat
Bugzilla</a> to track bugs for libvir, though there isn't yet a libvir
software module.</p></div></div><divclass="linkList2"><divclass="llinks2"><h3class="links2"><span>main menu</span></h3><ul><li><ahref="index.html">Home</a></li><li><ahref="news.html">Releases</a></li><li><ahref="intro.html">Introduction</a></li><li><ahref="architecture.html">libvir architecture</a></li><li><ahref="downloads.html">Downloads</a></li><li><ahref="FAQ.html">FAQ</a></li><li><ahref="bugs.html">Reporting bugs and getting help</a></li><li><astyle="font-weight:bold"href="html/index.html">API Menu</a></li><li><ahref="ChangeLog.html">Recent Changes</a></li></ul></div><divclass="llinks2"><h3class="links2"><span>related links</span></h3><ul><li><ahref="https://www.redhat.com/archives/libvir-list/">Mail archive</a></li><li><ahref="http://www.cl.cam.ac.uk/Research/SRG/netos/xen/index.html">Xen project</a></li><li><formaction="search.php"enctype="application/x-www-form-urlencoded"method="get"><inputname="query"type="text"size="12"value="Search..."/><inputname="submit"type="submit"value="Go"/></form></li><li><ahref="http://xmlsoft.org/"><imgsrc="Libxml2-Logo-90x34.gif"alt="Made with Libxml2 Logo"/></a></li></ul></div></div><divid="bottom"><pclass="p1"></p></div></div></body></html>
Bugzilla</a> to track bugs for libvir, though there isn't a libvir software
module defined yet, in the meantime use the mailing-list, thanks !.</p></div></div><divclass="linkList2"><divclass="llinks2"><h3class="links2"><span>main menu</span></h3><ul><li><ahref="index.html">Home</a></li><li><ahref="news.html">Releases</a></li><li><ahref="intro.html">Introduction</a></li><li><ahref="architecture.html">libvir architecture</a></li><li><ahref="downloads.html">Downloads</a></li><li><ahref="FAQ.html">FAQ</a></li><li><ahref="bugs.html">Reporting bugs and getting help</a></li><li><astyle="font-weight:bold"href="html/index.html">API Menu</a></li><li><ahref="ChangeLog.html">Recent Changes</a></li></ul></div><divclass="llinks2"><h3class="links2"><span>related links</span></h3><ul><li><ahref="https://www.redhat.com/archives/libvir-list/">Mail archive</a></li><li><ahref="http://www.cl.cam.ac.uk/Research/SRG/netos/xen/index.html">Xen project</a></li><li><formaction="search.php"enctype="application/x-www-form-urlencoded"method="get"><inputname="query"type="text"size="12"value="Search..."/><inputname="submit"type="submit"value="Go"/></form></li><li><ahref="http://xmlsoft.org/"><imgsrc="Libxml2-Logo-90x34.gif"alt="Made with Libxml2 Logo"/></a></li></ul></div></div><divid="bottom"><pclass="p1"></p></div></div></body></html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<htmlxmlns="http://www.w3.org/1999/xhtml"><head><metahttp-equiv="Content-Type"content="text/html; charset=ISO-8859-1"/><linkrel="stylesheet"type="text/css"href="libvir.css"/><title>Introduction</title></head><body><divid="container"><divid="intro"><divid="adjustments"></div><divid="pageHeader"></div><divid="content2"><h1class="style1">Introduction</h1><p>Libvir is a C toolkit to interract with the virtualization capabilities of
recent versions of Linux (and other OSes), but ibvir won't try to provide all
possible interfaces for interacting with the virtualization features of a set
of Linux (or other OS) system.</p><p>To avoid ambiguity about the terms used here here are the definitions for
possible interfaces for interacting with the virtualization features.</p><p>To avoid ambiguity about the terms used here here are the definitions for
soem of the specific terms used in libvir documentation:</p><ul><li>a <strong>node</strong> is a single physical machine</li>
<li>an <strong>hypervisor</strong> is a layer of software allowing to
virtualize a node in a set of virtual machines with possibly different
configurations than the node itself</li>
<li>a <strong>domain</strong> is an instance of an operating system running
on a virtualized machine</li>
</ul><p>Now we can define the goal of libvir: to provide the lowest possible
</ul><pstyle="text-align: center"><imgalt="Hypervisor and domains running on a node"src="node.gif"/></p><p>Now we can define the goal of libvir: to provide the lowest possible
generic and stable layer to manage domains on a node.</p><p>This implies the following:</p><ul><li>the API should not be targetted to a single virtualization environment
though Xen is the current default, which also means that some very
specific capabilities which are not generic enough may not be provided as
...
...
@@ -26,4 +25,6 @@ generic and stable layer to manage domains on a node.</p><p>This implies the fol
</ul><p>So libvir should be a building block for higher level management tools or
for applications focusing on virtualization on a single node (the only
exception being domain migration between node capabilities which may need to
be added at the libvir level)</p><p></p><p></p></div></div><divclass="linkList2"><divclass="llinks2"><h3class="links2"><span>main menu</span></h3><ul><li><ahref="index.html">Home</a></li><li><ahref="news.html">Releases</a></li><li><ahref="intro.html">Introduction</a></li><li><ahref="architecture.html">libvir architecture</a></li><li><ahref="downloads.html">Downloads</a></li><li><ahref="FAQ.html">FAQ</a></li><li><ahref="bugs.html">Reporting bugs and getting help</a></li><li><astyle="font-weight:bold"href="html/index.html">API Menu</a></li><li><ahref="ChangeLog.html">Recent Changes</a></li></ul></div><divclass="llinks2"><h3class="links2"><span>related links</span></h3><ul><li><ahref="https://www.redhat.com/archives/libvir-list/">Mail archive</a></li><li><ahref="http://www.cl.cam.ac.uk/Research/SRG/netos/xen/index.html">Xen project</a></li><li><formaction="search.php"enctype="application/x-www-form-urlencoded"method="get"><inputname="query"type="text"size="12"value="Search..."/><inputname="submit"type="submit"value="Go"/></form></li><li><ahref="http://xmlsoft.org/"><imgsrc="Libxml2-Logo-90x34.gif"alt="Made with Libxml2 Logo"/></a></li></ul></div></div><divid="bottom"><pclass="p1"></p></div></div></body></html>
be added at the libvir level). Where possible libvir should be extendable to
be able to provide the same API for remote nodes, however this is not the
case at the moment, the code currently handle only local node access.</p></div></div><divclass="linkList2"><divclass="llinks2"><h3class="links2"><span>main menu</span></h3><ul><li><ahref="index.html">Home</a></li><li><ahref="news.html">Releases</a></li><li><ahref="intro.html">Introduction</a></li><li><ahref="architecture.html">libvir architecture</a></li><li><ahref="downloads.html">Downloads</a></li><li><ahref="FAQ.html">FAQ</a></li><li><ahref="bugs.html">Reporting bugs and getting help</a></li><li><astyle="font-weight:bold"href="html/index.html">API Menu</a></li><li><ahref="ChangeLog.html">Recent Changes</a></li></ul></div><divclass="llinks2"><h3class="links2"><span>related links</span></h3><ul><li><ahref="https://www.redhat.com/archives/libvir-list/">Mail archive</a></li><li><ahref="http://www.cl.cam.ac.uk/Research/SRG/netos/xen/index.html">Xen project</a></li><li><formaction="search.php"enctype="application/x-www-form-urlencoded"method="get"><inputname="query"type="text"size="12"value="Search..."/><inputname="submit"type="submit"value="Go"/></form></li><li><ahref="http://xmlsoft.org/"><imgsrc="Libxml2-Logo-90x34.gif"alt="Made with Libxml2 Logo"/></a></li></ul></div></div><divid="bottom"><pclass="p1"></p></div></div></body></html>