[libvirt] [PATCH] virsh: update man page for cpu_shares parameter

Daniel Veillard veillard at redhat.com
Thu Sep 29 00:36:12 UTC 2011


On Wed, Sep 28, 2011 at 10:54:52AM -0600, Eric Blake wrote:
> On 09/27/2011 09:06 PM, Daniel Veillard wrote:
> >The man page suggest that the cpu_shares parameter of schedinfo
> >allows values 0-262144, but the kernel remaps values 0 and 1 to
> >the minimum 2, just document that behaviour:
> >
> >[root at test ~]# cat /cgroup/cpu/libvirt/qemu/cpu.shares
> >1024
> >[root at test ~]# echo 0>  /cgroup/cpu/libvirt/qemu/cpu.shares
> >[root at test ~]# cat /cgroup/cpu/libvirt/qemu/cpu.shares
> >2
> >[root at test ~]# echo 1>  /cgroup/cpu/libvirt/qemu/cpu.shares
> >[root at test ~]# cat /cgroup/cpu/libvirt/qemu/cpu.shares
> >2
> >[root at test ~]#
> >
> >* tools/virsh.pod: update description of the cpu_shares parameter
> >   to indicate the values 0 and 1 are automatically changed by the
> >   kernel to minimal value 2
> >
> >diff --git a/tools/virsh.pod b/tools/virsh.pod
> >index a01d723..6e3febb 100644
> >--- a/tools/virsh.pod
> >+++ b/tools/virsh.pod
> >@@ -914,7 +914,9 @@ If I<--current>  is specified, affect the current guest state.
> >
> >  B<Note>: The cpu_shares parameter has a valid value range of 0-262144; Negative
> >  values are wrapped to positive, and larger values are capped at the maximum.
> >-Therefore, -1 is a useful shorthand for 262144.
> >+Therefore, -1 is a useful shorthand for 262144. The values 0 and 1 seems to
> >+also be automatically changed by the Linux kernel to 2 which consider this
> >+the minimal value.
> 
> Awkward reading to a native English speaker.  How about:
> 
> On the Linux kernel, the values 0 and 1 are automatically converted
> to a minimal value of 2.

  Ah, yes that's way better even for me :-), I guess I rewrote that
sentence a bit too many times !

> ACK with that tweak.

  okay, will push,

   thanks !

Daniel

-- 
Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
daniel at veillard.com  | Rpmfind RPM search engine http://rpmfind.net/
http://veillard.com/ | virtualization library  http://libvirt.org/




More information about the libvir-list mailing list