https://wiki.openvz.org/api.php?action=feedcontributions&user=Alien&feedformat=atomOpenVZ Virtuozzo Containers Wiki - User contributions [en]2024-03-28T12:52:30ZUser contributionsMediaWiki 1.31.1https://wiki.openvz.org/index.php?title=Disk_quota&diff=7457Disk quota2009-08-06T15:17:34Z<p>Alien: /* Filesystem dependency */ reiserfs is also broken (user: alien)</p>
<hr />
<div>Basic disk quota management:<br />
<br />
<br />
To set disk space, run the following commands:<br />
<pre><br />
vzctl set CTID --diskspace $SoftLimit$:$HardLimit$ --save<br />
</pre><br />
<br />
<br />
Example:<br />
<pre><br />
[host-node]# vzctl set 101 --diskspace 6G:7G --save<br />
</pre><br />
<br />
You could verify the space available with this command (ie : CTID =101)<br />
<pre><br />
[host-node]# vzctl exec 101 df -h<br />
</pre><br />
<br />
If you want remove disk quota:<br />
<pre><br />
DISK_QUOTA=no<br />
</pre><br />
<br />
== Filesystem dependency ==<br />
If your host filesystem is not ext2/3 (like ''XFS'' or ''reiserfs'') the disk quotas will not work inside containers.<br />
<br />
[[Category: Disk quota]]</div>Alienhttps://wiki.openvz.org/index.php?title=Porting_the_kernel&diff=6795Porting the kernel2008-12-14T23:16:54Z<p>Alien: added a link about kir's arm port</p>
<hr />
<div>OpenVZ kernel supports x86, x86_64, IA64, power64, [http://community.livejournal.com/openvz/24651.html arm] and [[sparc]] architectures as of now. Below are the quick and dirty information about how to port the kernel to yet another architecture.<br />
<br />
* UBC: need to account any platform specific VMAs created by hand in arch specific code. i.e. if there are calls of <code>insert_vm_struct()</code> this should be accounted with <code>ub_memory_charge()</code>. Didn't find such thing on sparc64.<br />
<br />
* If there are user triggerable <code>printk()</code>'s (related to the user, not the system as a whole) better replace them with <code>ve_printk()</code>. Otherwise user can flood (DoS). minor actually.<br />
<br />
* Call to functions <code>find_task_by_pid()</code>, <code>for_each_process()</code> and <code>do_each_thread()</code>/<code>while_each_thread()</code> should be replaced with it's counterparts - <code>find_task_by_pid_XXX()</code>, <code>for_each_process_XXX()</code> and <code>do_each_thread_XXX()</code>/<code>while_each_thread_XXX()</code>, where <code>XXX</code> is either <code>all</code> or <code>ve</code>. Here <code>all</code> means that all system processes in the system will be scanned, while <code>ve</code> means that only the [[container]] accessible from this task (current context - <code>get_exec_env()</code>) will be visible. So you need to decide whether the code in question is about system or user context.<br />
<br />
* <code>task->pid</code> should be changed with <code>virt_pid(task)</code> in some places. The rule is simple: user should see only virtual pids, while kernel operate on global pids. e.g. in signals, virtual pid should be delivered to app.<br />
<br />
* In interrupt handlers one need to set global host ([[CT0]]) context. i.e. <code>set_exec_env()</code>, <code>set_exec_ub()</code>. i.e. interrupt handlers are running in CT0 context.<br />
<br />
* In <code>kernel_thread()</code> one needs to prohibit kernel threads in container. Mostly security related...<br />
<br />
* Extend <code>show_registers()</code> (or <code>show_regs()</code>) to show current container.<br />
<br />
* <code>utsname</code> should be virtualized. This mostly means that <code>system_utsnames</code> should be replaced with <code>ve_utsname</code>. See any arch code for this.<br />
<br />
* Some exports will be required. e.g. <code>show_mem()</code> and probably <code>cpu_khz</code>. Easy.<br />
<br />
* Everything else are bugfixes.<br />
<br />
All these are straightforward and really simple, so it should take a few hours to do.<br />
<br />
== External links ==<br />
* [http://forum.openvz.org/index.php?t=msg&goto=3338&&srch=sparc#msg_num_5 Original forum post]<br />
<br />
[[Category: Kernel internals]]<br />
[[Category: Development]]</div>Alienhttps://wiki.openvz.org/index.php?title=Template_talk:Contributed_templates_info&diff=6740Template talk:Contributed templates info2008-11-26T20:10:01Z<p>Alien: provided an up-to-date Centos4 with yum template</p>
<hr />
<div>* Up-to-date (built every 2x/week from a current Portage tree) Gentoo Linux OpenVZ templates for 32-bit and 64-bit are available at [http://www.funtoo.org/linux/openvz/].<br />
<br />
* I have modified the default CentOS 4 template to include yum and then I updated to the latest version (as of November 26th 2008) using yum update. You can fetch it from http://users.utcluj.ro/~mcristi/centos-4-i386-yum.tar.gz (Cristi Măgherușan - cristi.magherusan at net.utcluj.ro)</div>Alienhttps://wiki.openvz.org/index.php?title=Talk:Install_yum&diff=6739Talk:Install yum2008-11-26T19:44:39Z<p>Alien: New page: ==On centos 4== gmp,readline and expat are already installed, and elfutils-0.97.1-5.i386 needs elfutils-libelf-0.97.1-5 to be installed</p>
<hr />
<div>==On centos 4==<br />
gmp,readline and expat are already installed, and elfutils-0.97.1-5.i386 needs elfutils-libelf-0.97.1-5 to be installed</div>Alien