Difference between revisions of "Example-update-rootfs"

From VNUML-WIKI
Jump to: navigation, search
(New page: <div id="object1" style="position: absolute; visibility: show; left: 5px; top: 30px; z-index: 5"> {| width="160" cellspacing="1" cellpadding="5" | class="menutitlebig" bgcolor="#6699FF" |...)
 
Line 1: Line 1:
<div id="object1" style="position: absolute; visibility: show; left: 5px; top: 30px; z-index: 5">
+
{{Title|Update Root-Filesystem Example}}
  
{| width="160" cellspacing="1" cellpadding="5"
+
<big>
| class="menutitlebig" bgcolor="#6699FF" |
+
Authors:
<center>''' [#top Update Root-Filesystem Example]'''</center>
+
'''Ferm&iacute;n Gal&aacute;n (galan at dit.upm.es)'''
|-
+
  '''David Fern&aacute;ndez (david at dit.upm.es)'''
| class="menu" bgcolor="#99FFFF" |
+
'''version 1.7, February 15th, 2007'''
[#scenario  Scenario]<br />
+
</big>
|-
 
| class="menu" bgcolor="#99FFFF" |
 
[#description VNUML Description]<br />
 
|-
 
| class="menu" bgcolor="#99FFFF" |
 
[#old_releases  Old Releases]<br />
 
|-
 
| class="menutitle" bgcolor="#6699FF" |
 
<center>''' [http://www.dit.upm.es/vnuml/index.html Back to VNUML Home]'''</center>
 
|}
 
  
</div><div align="left">
+
__TOC__
  
{| style="text-align: left; width: 760px" cellspacing="2"
+
 
|- align="center"
+
 
| style="vertical-align: top; text-align: right" colspan="1" width="446" height="225" |
+
== Scenario ==
==Update Root-Filesystem Example<br /> version 1.7.0=====Author:<br /> Fermín Galán ([mailto:galan at dit.upm.es galan at dit.upm.es])=======November 21st, 2006====<br /><br />
+
This is a simple example useful to install or update applications inside a UML root filesystem. It just creates a virtual machine with external network access by means of a new subinterface configured in the host machine network interface. Once started you can use typical applications like dselect or apt-get in Debian to update the filesystem.<font color="red">'''Important notes:'''</font>
| style="text-align: right; vertical-align: top" width="208" |
 
[http://www.dit.upm.es/vnuml [[Image:vnuml.png|Virtual Network User Mode Linux]]]
 
|-
 
| class="title" colspan="2" | Scenario
 
|-
 
| colspan="2" |
 
<br />This is a simple example useful to install or update applications inside a UML root filesystem. It just creates a virtual machine with external network access by means of a new subinterface configured in the host machine network interface. Once started you can use typical applications like dselect or apt-get in Debian to update the filesystem.<font color="red">'''Important notes:'''</font>
 
 
* As this example interacts with the host machine network interface, an incorrect use of it '''can let the host unaccesible'''. Even if correctly used, the host will be unaccesible during short periods of time while the simulation starts/stops. So, it is recomended to execute it from the host console (at least not being far from it :).
 
* As this example interacts with the host machine network interface, an incorrect use of it '''can let the host unaccesible'''. Even if correctly used, the host will be unaccesible during short periods of time while the simulation starts/stops. So, it is recomended to execute it from the host console (at least not being far from it :).
 
* If you are experiencing problems with the conventional xterm, we recommend you to uncomment the [../../1.7/reference/index.html#xterm <xterm>] tag in each virtual machine, in order to use gnome-terminal, that seems to be more stable. Of course, you will need the gnome-terminal installed in your system.
 
* If you are experiencing problems with the conventional xterm, we recommend you to uncomment the [../../1.7/reference/index.html#xterm <xterm>] tag in each virtual machine, in order to use gnome-terminal, that seems to be more stable. Of course, you will need the gnome-terminal installed in your system.
Line 38: Line 21:
 
* Router address: 192.168.11.254
 
* Router address: 192.168.11.254
 
* Subnet Mask: 255.255.255.0 (/24) You can download the simulation file from [update-fs.xml here].
 
* Subnet Mask: 255.255.255.0 (/24) You can download the simulation file from [update-fs.xml here].
|-
+
 
| class="title" colspan="2" | VNUML Description
+
 
|-
+
== VNUML Description ==
| colspan="2" |
+
 
 +
 
 
<br />  
 
<br />  
 +
<pre>
 
  <?xml version="1.0" encoding="UTF-8"?>
 
  <?xml version="1.0" encoding="UTF-8"?>
 
  <!DOCTYPE vnuml SYSTEM "/usr/share/xml/vnuml/vnuml.dtd">
 
  <!DOCTYPE vnuml SYSTEM "/usr/share/xml/vnuml/vnuml.dtd">
Line 77: Line 62:
 
     </host>
 
     </host>
 
  </vnuml>
 
  </vnuml>
 +
</pre>
 
<br />
 
<br />
|-
 
| class="title" colspan="2" | Old Releases
 
|-
 
| colspan="2" |
 
<br />
 
* [1.3/update-fs.html 1.3]
 
* [1.6/update-fs.html 1.6]<br />
 
|-
 
| colspan="2" |
 
----
 
<center><font face="Tahoma">''Last update: <br />''</font><br /><center>[http://validator.w3.org/check/referer [[Image:valid-html401.png|Valid HTML 4.01!]]]</center></center>
 
|}
 
  
</div>
+
Old Releases
 +
 
 +
* [http://jungla.dit.upm.es/~vnuml/doc/examples/update-fs/1.3/update-fs.html l 1.3]
 +
* [http://jungla.dit.upm.es/~vnuml/doc/examples/update-fs/1.6/update-fs.html 1.6]

Revision as of 19:50, 11 February 2007

Update Root-Filesystem Example

Authors:
Fermín Galán (galan at dit.upm.es)
David Fernández (david at dit.upm.es)
version 1.7, February 15th, 2007


Scenario

This is a simple example useful to install or update applications inside a UML root filesystem. It just creates a virtual machine with external network access by means of a new subinterface configured in the host machine network interface. Once started you can use typical applications like dselect or apt-get in Debian to update the filesystem.Important notes:

  • As this example interacts with the host machine network interface, an incorrect use of it can let the host unaccesible. Even if correctly used, the host will be unaccesible during short periods of time while the simulation starts/stops. So, it is recomended to execute it from the host console (at least not being far from it :).
  • If you are experiencing problems with the conventional xterm, we recommend you to uncomment the [../../1.7/reference/index.html#xterm <xterm>] tag in each virtual machine, in order to use gnome-terminal, that seems to be more stable. Of course, you will need the gnome-terminal installed in your system.
  • Note the use of [../../1.7/reference/index.html#filesystem <filesystem type="direct">] in order to make the changes in the filesystem (e.g., installed software) permantent. If you were using for example type="cow" changes won't be stored in the /usr/share/vnuml/filesystems/root_fs_tutorial file. More information about installing software in the [../../1.7/user/index.html#installing_software_UML User Manual].
    update rootfilesystem
    To configure this example, you need an aditional IP network address from the subnet where the host is connected. The relevant data used in the example follows:
  • Host address: 192.168.11.16
  • Virtual Machine address: 192.168.11.30
  • Router address: 192.168.11.254
  • Subnet Mask: 255.255.255.0 (/24) You can download the simulation file from [update-fs.xml here].


VNUML Description


 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE vnuml SYSTEM "/usr/share/xml/vnuml/vnuml.dtd">
 <vnuml>
 
    <global>
       <version>1.7</version>
       <simulation_name>update-fs</simulation_name>
       <ssh_key>/root/.ssh/identity.pub</ssh_key>
       <automac offset="0"/>
       <vm_mgmt type="none" network="192.168.0.0" mask="24" offset="0"/>
    </global>
    
    <net name="Net0" mode="virtual_bridge" external="eth0" />
    
    <vm name="vm1">
       <filesystem type="direct">/usr/share/vnuml/filesystems/root_fs_tutorial</filesystem>
       <mem>64M</mem>
       <kernel>/usr/share/vnuml/kernels/linux</kernel>
       <console id="0">xterm</console>
       <!--xterm>gnome-terminal,-t,-x</xterm-->      
       <if id="1" net="Net0">
          <ipv4 mask="255.255.255.0">192.168.11.30</ipv4>
       </if>
       <route type="ipv4" gw="192.168.11.254">default</route>
    </vm>
    
    <host>
       <hostif net="Net0">
          <ipv4 mask="255.255.255.0">192.168.11.16</ipv4>
       </hostif>
       <physicalif name="eth0" type="ipv4" ip="192.168.11.16" mask="255.255.255.0" gw="172.16.0.1"/>
       <route type="ipv4" gw="192.168.11.254">default</route>
    </host>
 </vnuml>


Old Releases