<?xml version="1.0" encoding="UTF-8"?>

<rss version="2.0"
 xmlns:blogChannel="http://backend.userland.com/blogChannelModule"
>

<channel>
<title>Parallels knowledgebase (KB)</title>
<link>http://kb.parallels.com/</link>
<description>Parallels knowledgebase (KB)</description>
<language>en</language>
<copyright>Copyright 2008 Parallels</copyright>
<pubDate>Wed, 10 Sep 2008 00:00:00 +0600</pubDate>
<lastBuildDate>Wed, 10 Sep 2008 00:00:00 +0600</lastBuildDate>
<webMaster>rt-team@parallels.com</webMaster>

<item>
<title><![CDATA[How do I mount an ISO image in Virtuozzo container?]]></title>
<link>http://kb.parallels.com/en/4628</link>
<description><![CDATA[<div id="article">
	




	<div id="kb" class="kb">
		<div class="article-container">
			<h2 class="title">How do I mount an ISO image in Virtuozzo container?</h2>
			<div class="ab-frame"><div class="bl"><div class="br"><div class="tl"><div class="tr"><!-- frame -->
				<div class="articleProperty">
					<div>Article ID: 4628&nbsp;</div>
					<div>Last Review: Aug,4 2009</div>
					<tr>
						<td>Author: </td>
						<td>Kolomoets Alexey</td>
					</tr>
					<br/>
					<tr>
						<td>Last updated by: </td>
						<td>Kolomoets Alexey</td>
					</tr>
					<strong>APPLIES TO:</strong>
					<div class="articleApplies">
						<ul>
							<li>Virtuozzo Containers for Linux 4.0</li>
						</ul>
					</div>
				</div><!-- articleProperty -->
			</div></div></div></div></div><!-- frame -->

			<div class="article-internal-flag"></div>

			<div id="article-content">
				<div class="article-part">
					<h2>Resolution</h2>
					In Parallels Virtuozzo Containers 4.0 you may use FUSE (filesystem in userspace) to mount ISO image inside a container.<br /><br /><strong>1. </strong>Make sure that '<strong>fuse</strong>' module is loaded on hardware node:<br /><br /><div class="commandline"><code>~# lsmod | grep fuse</code></div><br />If it is not there, use:<br /><br /><div class="commandline"><code>~# modprobe fuse<br />~# lsmod|grep fuse<br />fuse&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 45320&nbsp; 0</code></div><br />In case you would like to load '<strong>fuse</strong>' module automatically before starting the service '<strong>vz</strong>' please implement init script '<strong>/etc/rc.modules</strong>' on your node, as described in the article:<br /><br /><span style='font-family: courier new,courier;font-size: 12px;'>---8&lt;---<br /><a href="http://kb.parallels.comhttp://kb.parallels.com/en/696">http://kb.parallels.com/en/696</a><br />...<br />In order to automate modules loading before Virtuozzo services are started you may install 'openvpn' package from Virtuozzo distrib (in HW/RPMS directory) and enable it in default runlevel (use 'chkconfig' utility to do that). Please also use instructions on automated module loading suitable for base OS installed on hardware node.<br />Just for example, for&nbsp; RedHat-based systems (such as Fedora Core, RedHat AS3/AS4, CentOS 3/4) it should be enough to add 'modprobe tun' command into /etc/rc.modules file and make it executable:<br /><br /># chmod a+rx /etc/rc.modules<br />--->8---</span><br /><br />and then put the command '<strong>modprobe fuse</strong>' inside the file.<br /><br />After that please restart the hardware node to make sure that '<strong>fuse</strong>' module is loaded correctly before the service '<strong>vz</strong>'.<br /><br /><strong>2. </strong>Grant a container #101 the permission to work with <strong>/dev/fuse</strong> character device and create corresponding device inside a container (run these commands on Virtuozzo server):<br /><br /><div class="commandline"><code>~# vzctl set 101 --devices c:10:229:rw --save <br />~# vzctl exec 101 mknod -m 666 /dev/fuse c 10 229 <br />~# vzctl exec 101 cp -a /dev/fuse&nbsp; /lib/udev/devices/</code></div><br /><br />In case the file <strong><span style="font-family:Courier New;">/dev/fuse</span></strong> already exist please make sure it has proper access permissions. Also if the directory '<strong><span style="font-family:Courier New;">/lib/udev/devices</span></strong>' does not exist, please create it and set correct access permissions:<br /><br /><div class="commandline"><code> # vzctl exec 101 mkdir /lib/udev/devices<br />&nbsp;# vzctl exec 101 chmod 755 /lib/udev/devices/</code></div><br /><br /><br />Check these files:<br /><br /><div class="commandline"><code>~# vzctl exec 101 ls -l /lib/udev/devices/fuse<br />crw-rw-rw- 1 root root 10, 229 Oct 25 19:37 /lib/udev/devices/fuse <br /><br /># vzctl exec 101 ls -l /dev/fuse<br />crw-rw-rw- 1 root root 10, 229 Oct 25 19:37 /dev/fuse</code></div><br /><br /><strong>3. </strong>Install packages fuseiso and fuse into container. Names of packages may be different on different Linux distributions: for Debian and Ubuntu install fuseiso and fuse-utils packages (available in repository) for RHEL/CentOS 3/4/5 use DAG's packages fuse-iso and fuse for Fedora 7/8 both fuseiso and fuse are available from the main/updates repositories for Fedora 6, fuse is available from extras repo, use dries for fuse-iso To mount an ISO image run the command inside a container:<br /><br /><div class="commandline"><code>~# fuseiso IMAGE.iso /mnt</code></div><br />Replace IMAGE.iso in the command above with the exact name of ISO image (including path) on filesystem, replace <strong>/mnt</strong> with path where you want ISO image to be mounted.<br /><br />To umount image use this command:<br /><br /><div class="commandline"><code>~# fusermount -u /mnt</code></div><br />Again - replace <strong>/mnt</strong> with exact path where ISO image was mounted. <br />
				</div>
				<div class="keywords"><strong>Keywords:</strong> mount ISO image FUSE</div>
			</div>
		</div><!-- article-container -->


			<br/><br/>

			<div id="SubscriptionLink24Article" class="subscriptionLink2">
<a href="http://kb.parallels.com/subscriptions/index.html?Type=Article&ArticleID=4628&ArticleLanguage=en&Product=&Category="><img src="http://kb.parallels.com/images/mail.png" width="15" height="15" alt="Subscription for changes to this article"></a>
<a href="http://kb.parallels.com/subscriptions/index.html?Type=Article&ArticleID=4628&ArticleLanguage=en&Product=&Category=">Subscription for changes to this article</a>

<script type="text/javascript">

$(document).ready(function() {
	$('#SubscriptionLink24Article a').each(function(){
		$(this).click(function(event) {
			event.preventDefault();
			MainPageContentHide();
			$('#subscription').html('');
			$.get('/Stuff/Subscription', {
													'Type' : 'Article',
													'ArticleID' : '4628',
													'ArticleLanguage' : 'en',
													'Product' : '',
													'Category' : ''
												}, function(data) {
																	$('#subscription').html(data);
																	$('#subscription').show();
																	SUBbuildsubmenus_product();
																});
		});
	});
});

</script>

</div>





	</div><!-- kb -->

</div><!-- article -->


]]></description>
<author>Kolomoets Alexey</author>
<guid isPermaLink="false">4266 LastUpdated: 2009-08-04 09:28:12</guid>
<pubDate>2008-03-28 08:51:54</pubDate>
</item>
</channel>
</rss>



