----- Original Message ----- > From: "Jan Chaloupka" <jchal...@redhat.com> > To: libcg-devel@lists.sourceforge.net > Cc: jchal...@redhat.com, varek...@redhat.com > Sent: Thursday, July 24, 2014 8:20:59 AM > Subject: [PATCH 2/2] cgrules.d: new man page > > This patch contains new man page for cgrules.d directory and corresponding > update of existing man pages. It describes the way additional configuration > files should be created and potential conflicts resulting from an arbitrary > order or reading files in the directory. > > Changelog: > * line wrapping (max to 80 characters) > * hiearchy typo corrected > * diffrent typo corrected > * succesfully typo corrected > * /etc/cgconfig.conf added into FILES section > * formulation of advice for creating rules updated. Is it enough or > still confusing? If so, can you be more specific? > * reformulation of the first and the second paragraph > > Signed-off-by: Jan Chaloupka <jchal...@redhat.com> Acked-by: Ivana Hutarova Varekova <varek...@redhat.com> > --- > doc/man/cgrules.conf.5 | 14 ++++++++++--- > doc/man/cgrules.d.5 | 50 > ++++++++++++++++++++++++++++++++++++++++++++++++ > doc/man/cgrulesengd.8 | 20 ++++++++++++++----- > 3 files changed, 75 insertions(+), 9 deletions(-) > create mode 100644 doc/man/cgrules.d.5 > > diff --git a/doc/man/cgrules.conf.5 b/doc/man/cgrules.conf.5 > index 7a89fb5..2d434e7 100644 > --- a/doc/man/cgrules.conf.5 > +++ b/doc/man/cgrules.conf.5 > @@ -85,7 +85,7 @@ configuration file. See (\fBcgconfig.conf\fR (5)). > If the template definition is not found there created group have default > kernel setting. > > - > +To create a hierarchy of configuration files, use \fB/etc/cgrules.d\fR > directory. > > .SH EXAMPLES > .nf > @@ -136,13 +136,19 @@ process. > .PD .1v > .TP 20 > .B /etc/cgrules.conf > -.TP > +.RS 6 > default libcgroup configuration file > -.PD . > +.RE > +.TP 20 > +.B /etc/cgrules.d > +.RS 6 > +default libcgroup configuration files directory > +.RE > +.PD > > > .SH SEE ALSO > -cgconfig.conf (5), cgclassify (1), cgred.conf (5) > +cgconfig.conf (5), cgclassify (1), cgred.conf (5), cgrules.d (5) > > .SH BUGS > > diff --git a/doc/man/cgrules.d.5 b/doc/man/cgrules.d.5 > new file mode 100644 > index 0000000..37717de > --- /dev/null > +++ b/doc/man/cgrules.d.5 > @@ -0,0 +1,50 @@ > +.\" Copyright (C) 2014 Red Hat, Inc. All Rights Reserved. > +.\" Written by Jan Chaloupka <jchal...@redhat.com> > + > +.TH CGRULES.D 5 2014-07-14 "Linux" "libcgroup Manual" > +.SH NAME > +cgrules.d \- libcgroup configuration files directory > +.SH DESCRIPTION > +.B "cgrules.d" > +configuration files directory is used by > +.B libcgroups > +and contains additional configuration files with the same syntax as > +\fBcgconfig.conf\fR (5). > + > +Files are parsed in an arbitrary order. > +If the cache is disabled, the searching algorithm of \fBcgrulesengd\fR (8) > +tries the first match. > +If there are two rules which match the criteria for a given process, > +and each rule is in a separate file, then there is no guarantee which one > +is chosen. If you want to control the given order of the rules, put them > +in one configuration file. > + > + > +\fB/etc/cgconfig.conf\fR is parsed as the first file. After success, > +all files from /etc/cgconfig.d are parsed as well (in an arbitrary order). > +If some file from the directory ends up with a parsing error, > +the process is stopped. With cache enabled, all successfully processed > +rules > +are kept in the cache. With cache disabled, > +matching is stopped and ends with a 'not found' result. > + > +If \fB/etc/cgrules.d\fR is empty, \fBcgrulesengd\fR (8) acts > +in a backwards compatibility mode. > + > +.SH FILES > +.LP > +.PD .1v > +.TP 20 > +.B /etc/cgrules.d > +.RS 4 > +default libcgroup configuration files directory > +.RE > +.B /etc/cgconfig.conf > +.RS 4 > +default libcgroup configuration file > +.RE > +.PD . > + > + > +.SH SEE ALSO > +cgconfig.conf (5), cgrulesengd (8) > diff --git a/doc/man/cgrulesengd.8 b/doc/man/cgrulesengd.8 > index 749b6fc..ba654b9 100644 > --- a/doc/man/cgrulesengd.8 > +++ b/doc/man/cgrulesengd.8 > @@ -10,10 +10,11 @@ cgrulesengd \- control group rules daemon > .SH DESCRIPTION > \fBcgrulesengd\fR is a daemon, which distributes processes to control > groups. When > any process changes its effective UID or GID, \fBcgrulesengd\fR inspects the > list > -of rules loaded from the \fIcgrules.conf\fR file and moves the process to > -the appropriate control group. > +of rules loaded from the \fIcgrules.conf\fR file and files in > \fIcgrules.d\fR > +(see \fBcgrules.d\fR (5) for potential conflicts) directory > +and moves the process to the appropriate control group. > > -The list of rules is read during the daemon startup is are cached in the > daemon's memory. > +The list of rules is read during the daemon startup and cached in the > daemon's memory. > The daemon reloads the list of rules when it receives SIGUSR2 signal. > The daemon reloads the list of templates when it receives SIGUSR1 signal. > > @@ -67,14 +68,23 @@ controls verbosity of the tool. Allowed values are > \fBDEBUG\fR, > .PD .1v > .TP > .B /etc/cgrules.conf > -.TP > +.RS 6 > the default libcgroup configuration file > +.RE > +.B /etc/cgrules.d > +.RS 6 > +the default libcgroup configuration files directory > +.RE > .TP > .B /etc/cgconfig.conf > +.RS 6 > the default templates file > +.RE > .TP > .B /etc/cgconfig.d/ > +.RS 6 > the default templates directory > +.RE > > .SH SEE ALSO > -cgrules.conf (5) > +cgrules.conf (5), cgrules.d (5) > >
------------------------------------------------------------------------------ Infragistics Professional Build stunning WinForms apps today! Reboot your WinForms applications with our WinForms controls. Build a bridge from your legacy apps to the future. http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk _______________________________________________ Libcg-devel mailing list Libcg-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libcg-devel