Blame SOURCES/libcgroup-0.41-add-examples-to-man-pages.patch

4b3140
From d58a95615a146f868106411aecd61af182d7c7e2 Mon Sep 17 00:00:00 2001
4b3140
From: Jan Chaloupka <jchaloup@redhat.com>
4b3140
Date: Sun, 21 Sep 2014 12:05:11 +0200
4b3140
Subject: [PATCH] add examples to man pages
4b3140
4b3140
---
4b3140
 doc/man/cgclassify.1     | 18 ++++++++++++++++++
4b3140
 doc/man/cgclear.1        | 21 ++++++++++++++++++++-
4b3140
 doc/man/cgconfig.conf.5  |  5 +----
4b3140
 doc/man/cgconfigparser.8 | 14 ++++++++++++++
4b3140
 doc/man/cgcreate.1       |  9 ++++++++-
4b3140
 doc/man/cgdelete.1       |  8 +++++++-
4b3140
 doc/man/cgred.conf.5     |  2 +-
4b3140
 doc/man/cgrulesengd.8    |  3 ---
4b3140
 doc/man/cgset.1          | 11 +++++++++++
4b3140
 doc/man/cgsnapshot.1     | 15 ++++++++++++++-
4b3140
 doc/man/lscgroup.1       | 15 +++++++++++++++
4b3140
 11 files changed, 109 insertions(+), 12 deletions(-)
4b3140
4b3140
diff --git a/doc/man/cgclassify.1 b/doc/man/cgclassify.1
4b3140
index db4e086..1facd2b 100644
4b3140
--- a/doc/man/cgclassify.1
4b3140
+++ b/doc/man/cgclassify.1
4b3140
@@ -57,7 +57,25 @@ controls verbosity of the tool. Allowed values are \fBDEBUG\fR,
4b3140
 .TP
4b3140
 .B /etc/cgrules.conf
4b3140
 default libcgroup configuration file
4b3140
+.TP
4b3140
+.B /etc/cgrules.d
4b3140
+default libcgroup configuration files directory
4b3140
+
4b3140
+.SH EXAMPLES
4b3140
+.TP
4b3140
+.B cgclassify -g cpu:student 1234
4b3140
+moves process with pid number 1234 to control group student in cpu hierarchy.
4b3140
 
4b3140
+.TP
4b3140
+.B cgclassify 1234
4b3140
+moves process with pid number 1234 to control groups based on
4b3140
+\fB/etc/cgrules.conf\fR configuration file.
4b3140
+
4b3140
+.TP
4b3140
+.B cgclassify --sticky -g cpu:/student 1234
4b3140
+moves process with pid number 1234 to control group student in cpu hierarchy.
4b3140
+The daemon of service cgred does not change cgroups of pid 1234 and its children
4b3140
+(based on \fB/etc/cgrules.conf\fR).
4b3140
 
4b3140
 .SH SEE ALSO
4b3140
 cgrules.conf (5), cgexec (1)
4b3140
diff --git a/doc/man/cgclear.1 b/doc/man/cgclear.1
4b3140
index 318c925..241a095 100644
4b3140
--- a/doc/man/cgclear.1
4b3140
+++ b/doc/man/cgclear.1
4b3140
@@ -43,5 +43,24 @@ option works only with \fB-l\fR or \fB-L\fR options.
4b3140
 controls verbosity of the tool. Allowed values are \fBDEBUG\fR,
4b3140
 \fBINFO\fR, \fBWARNING\fR or \fBERROR\fR.
4b3140
 
4b3140
+.SH FILES
4b3140
+.TP
4b3140
+.B /etc/cgconfig.conf
4b3140
+default templates file
4b3140
+.TP
4b3140
+.B /etc/cgconfig.d/
4b3140
+default templates files directory
4b3140
+.RE
4b3140
+
4b3140
+
4b3140
+.SH EXAMPLES
4b3140
+.TP
4b3140
+.B cgclear
4b3140
+unload the whole cgroup filesystem
4b3140
+
4b3140
+.TP
4b3140
+.B cgclear -l /etc/cgconfig.conf
4b3140
+unload a subsystem of cgroup filesystem based on \fB/etc/cgconfig.conf\fR definition.
4b3140
+
4b3140
 .SH SEE ALSO
4b3140
-cgconfigparser(1)
4b3140
+cgconfigparser(1), cgconfig.conf(5)
4b3140
diff --git a/doc/man/cgconfig.conf.5 b/doc/man/cgconfig.conf.5
4b3140
index a7d9935..f3a4ba9 100644
4b3140
--- a/doc/man/cgconfig.conf.5
4b3140
+++ b/doc/man/cgconfig.conf.5
4b3140
@@ -784,15 +784,12 @@ better to explicitly specify all groups and all controllers
4b3140
 related to them.
4b3140
 
4b3140
 .SH FILES
4b3140
-.LP
4b3140
-.PD .1v
4b3140
 .TP
4b3140
 .B /etc/cgconfig.conf
4b3140
-.TP
4b3140
 default libcgroup configuration file
4b3140
+.TP
4b3140
 .B /etc/cgconfig.d/
4b3140
 default libcgroup configuration files directory
4b3140
-.PD 
4b3140
 
4b3140
 .SH SEE ALSO
4b3140
 cgconfigparser (8)
4b3140
diff --git a/doc/man/cgconfigparser.8 b/doc/man/cgconfigparser.8
4b3140
index 0a20f95..8fff95f 100644
4b3140
--- a/doc/man/cgconfigparser.8
4b3140
+++ b/doc/man/cgconfigparser.8
4b3140
@@ -74,5 +74,19 @@ of this group have write access to the file.
4b3140
 controls verbosity of the tool. Allowed values are \fBDEBUG\fR,
4b3140
 \fBINFO\fR, \fBWARNING\fR or \fBERROR\fR.
4b3140
 
4b3140
+.SH FILES
4b3140
+.TP
4b3140
+.B /etc/cgconfig.conf
4b3140
+default libcgroup configuration file
4b3140
+.TP
4b3140
+.B /etc/cgconfig.d/
4b3140
+default libcgroup configuration files directory
4b3140
+
4b3140
+.SH EXAMPLES
4b3140
+.TP
4b3140
+.B cgconfigparser -l /etc/cgconfig.conf
4b3140
+setup control group file system based on \fB/etc/cgconfig.conf\fR configuration file
4b3140
+
4b3140
+
4b3140
 .SH SEE ALSO
4b3140
 cgconfig.conf (5)
4b3140
diff --git a/doc/man/cgcreate.1 b/doc/man/cgcreate.1
4b3140
index 557b5ae..17c33d8 100644
4b3140
--- a/doc/man/cgcreate.1
4b3140
+++ b/doc/man/cgcreate.1
4b3140
@@ -70,7 +70,14 @@ The default value is the same as has the parent cgroup.
4b3140
 controls verbosity of the tool. Allowed values are \fBDEBUG\fR,
4b3140
 \fBINFO\fR, \fBWARNING\fR or \fBERROR\fR.
4b3140
 
4b3140
-.SH FILES
4b3140
+.SH EXAMPLES
4b3140
+.TP
4b3140
+.B cgcreate -g *:student -g devices:teacher
4b3140
+create control group student in all mounted hierarchies and create
4b3140
+control group teacher in hierarchy containing controller devices.
4b3140
+
4b3140
+
4b3140
+
4b3140
 
4b3140
 .SH SEE ALSO
4b3140
 cgrules.conf (5)
4b3140
diff --git a/doc/man/cgdelete.1 b/doc/man/cgdelete.1
4b3140
index 025a799..9572287 100644
4b3140
--- a/doc/man/cgdelete.1
4b3140
+++ b/doc/man/cgdelete.1
4b3140
@@ -16,7 +16,7 @@ program removes all specified control groups.
4b3140
 
4b3140
 .TP
4b3140
 .B [-g] <controllers>:<path>
4b3140
-Defines the control group to delete. Multiple control groups nay be
4b3140
+Defines the control group to delete. Multiple control groups may be
4b3140
 specified.
4b3140
 .B -g
4b3140
 is optional.
4b3140
@@ -35,5 +35,11 @@ Recursively remove all subgroups.
4b3140
 controls verbosity of the tool. Allowed values are \fBDEBUG\fR,
4b3140
 \fBINFO\fR, \fBWARNING\fR or \fBERROR\fR.
4b3140
 
4b3140
+.SH EXAMPLES
4b3140
+.TP
4b3140
+.B cgdelete -g cpu,devices:/test
4b3140
+remove control group test from hierarchies containing cpu and device controllers
4b3140
+
4b3140
+
4b3140
 .SH SEE ALSO
4b3140
 cgcreate (1), lscgroup (1), cgclear (1)
4b3140
diff --git a/doc/man/cgred.conf.5 b/doc/man/cgred.conf.5
4b3140
index 3fe760f..1c0922f 100644
4b3140
--- a/doc/man/cgred.conf.5
4b3140
+++ b/doc/man/cgred.conf.5
4b3140
@@ -42,7 +42,7 @@ default libcgroup configuration file
4b3140
 
4b3140
 .SH SEE ALSO
4b3140
 cgrules.conf (5),
4b3140
-cgconfig.conf (5)
4b3140
+cgconfig.conf (5), cgrules.d (5)
4b3140
 
4b3140
 
4b3140
 
4b3140
diff --git a/doc/man/cgrulesengd.8 b/doc/man/cgrulesengd.8
4b3140
index 749b6fc..2810aa5 100644
4b3140
--- a/doc/man/cgrulesengd.8
4b3140
+++ b/doc/man/cgrulesengd.8
4b3140
@@ -63,11 +63,8 @@ controls verbosity of the tool. Allowed values are \fBDEBUG\fR,
4b3140
 \fBINFO\fR, \fBWARNING\fR or \fBERROR\fR.
4b3140
 
4b3140
 .SH FILES
4b3140
-.LP
4b3140
-.PD .1v
4b3140
 .TP
4b3140
 .B /etc/cgrules.conf
4b3140
-.TP
4b3140
 the default libcgroup configuration file
4b3140
 .TP
4b3140
 .B /etc/cgconfig.conf
4b3140
diff --git a/doc/man/cgset.1 b/doc/man/cgset.1
4b3140
index be886c6..b05473f 100644
4b3140
--- a/doc/man/cgset.1
4b3140
+++ b/doc/man/cgset.1
4b3140
@@ -36,5 +36,16 @@ copied to the input cgroup.
4b3140
 controls verbosity of the tool. Allowed values are \fBDEBUG\fR,
4b3140
 \fBINFO\fR, \fBWARNING\fR or \fBERROR\fR.
4b3140
 
4b3140
+.SH EXAMPLES
4b3140
+.TP
4b3140
+.B cgset -r cpuset.cpus=0-1 student
4b3140
+set variable cpus in control group student (controller cpuset) to 0-1
4b3140
+
4b3140
+.TP
4b3140
+.B cgset --copy-from group1/ group2/
4b3140
+copy all parameters of group group1 to group group2
4b3140
+(for all path where both cgroups are defined)
4b3140
+
4b3140
+
4b3140
 .SH SEE ALSO
4b3140
 cgrules.conf (1), cgcreate (1), cgget (1)
4b3140
diff --git a/doc/man/cgsnapshot.1 b/doc/man/cgsnapshot.1
4b3140
index 03c85f6..48a038e 100644
4b3140
--- a/doc/man/cgsnapshot.1
4b3140
+++ b/doc/man/cgsnapshot.1
4b3140
@@ -8,7 +8,7 @@ cgsnapshot \- generate the configuration file for given controllers
4b3140
 
4b3140
 .SH SYNOPSIS
4b3140
 \fBcgsnapshot\fR [\fB-h\fR] [\fB-s\fR] [\fB-t\fR] [\fB-b\fR \fIfile\fR]
4b3140
-[\fB-w\fR \fIfile\fR] [\fB-f\fR \fIoutput_file\fR]  [\fBcontroller\fR] [...]
4b3140
+[\fB-w\fR \fIfile\fR] [\fB-f\fR \fIoutput_file\fR] [\fBcontroller\fR] [...]
4b3140
 
4b3140
 .SH DESCRIPTION
4b3140
 \fBcgsnapshot\fR
4b3140
@@ -96,5 +96,18 @@ default whitelist
4b3140
 .B /etc/cgconfig.conf
4b3140
 default libcgroup configuration file
4b3140
 
4b3140
+.SH EXAMPLES
4b3140
+.TP
4b3140
+.B cgsnapshot -s -f /etc/cgconfig.conf.cgsnapshot
4b3140
+create configuration file which contains all mounted controllers and all
4b3140
+control groups which are on the actual system
4b3140
+
4b3140
+.TP
4b3140
+.B cgsnapshot -s -f /etc/cgconfig.conf.cgsnapshot cpu
4b3140
+create configuration file which contains hierarchy containing cpu controller and all its
4b3140
+control groups on the actual system
4b3140
+
4b3140
+
4b3140
+
4b3140
 .SH SEE ALSO
4b3140
 cgconfig.conf (5)
4b3140
diff --git a/doc/man/lscgroup.1 b/doc/man/lscgroup.1
4b3140
index 693fbbc..124379e 100644
4b3140
--- a/doc/man/lscgroup.1
4b3140
+++ b/doc/man/lscgroup.1
4b3140
@@ -26,6 +26,21 @@ list all existing cgroups.
4b3140
 controls verbosity of the tool. Allowed values are \fBDEBUG\fR,
4b3140
 \fBINFO\fR, \fBWARNING\fR or \fBERROR\fR.
4b3140
 
4b3140
+.SH EXAMPLES
4b3140
+.TP
4b3140
+.B lscgroup -g cpu:/
4b3140
+list all cgroups which are in hierarchy containing cpu controller
4b3140
+
4b3140
+.TP
4b3140
+.B lscgroup -g cpu:/student
4b3140
+list all cgroups which are in hierarchy containing cpu controller
4b3140
+in subgroup student
4b3140
+
4b3140
+.TP
4b3140
+.B lscgroup
4b3140
+list all cgroups which in all hierarchies
4b3140
+
4b3140
+
4b3140
 .SH SEE ALSO
4b3140
 lssubsys (1), cgcreate (1), cgdelete (1),
4b3140
 cgconfig.conf (5)
4b3140
-- 
4b3140
1.9.3
4b3140