Open main menu

OpenVZ Virtuozzo Containers Wiki β

Changes

Using vzpkg and vzyum on x86 64

996 bytes added, 18:48, 29 April 2009
added step 12 (bind mounts to share vzyum cache), small corrections and updates to step 3
:<code>cachedir=/var/cache/yum-cache</code>
{{Note| <b>1)</b> With this these changes, vzyum is not going to won´t be able to use a common cache directory to all [[container]]s as it was used to do. Each [[container]] will have it's its own cache directory.To avoid to have a directory named /vz/template/centos/4/x86_64/yum-cache in each [[container]], it is preferable to use the correct cache directory /var/cache/yum-cache.}}
<b>2)</b> To set up a common cache directory, you can use the autofs/automounter daemon together with [[Bind_mounts]] as described in <b>step 12</b>. Using a shared cache may save a lot of network traffic when installing new VPSs.}}
===== STEP 12 =====
 
To share the vzyum cache directory between various [[containers]], <b>after all is set up</b>, edit your /etc/auto.master to include the following:
:<code>/vz/root/{vpsid}/var/cache/yum-cache /etc/auto.vzyum</code>
Include one line for each installed or planned VPS, replacing {vpsid} with the adequate value.
 
Then, create a /etc/auto.vzyum file with only this line:
:<code>* -bind,ro,nosuid,nodev :/var/cache/yum-cache/&</code>
This file won´t need to be changed, even after you add more containers.
Restart the automounter daemon.
 
{{Note| Make sure these changes won´t interfere with other automounts you may already have set up. If you don´t already use autofs/automount, it is safe to comment out other settings in auto.master.}}
== TESTING THE NEW CODE ==
1
edit