From cf3e41c6b33f6e13a52c6485e35964b7d2b0b122 Mon Sep 17 00:00:00 2001 From: des Date: Thu, 9 Aug 2007 17:11:35 +0000 Subject: [PATCH] Add some text about the cli + the munin / nagios / webmin plugins, and some greek to help the document validate. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@1822 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- varnish-doc/en/inside-varnish/article.xml | 136 +++++++++++++++++++++- 1 file changed, 135 insertions(+), 1 deletion(-) diff --git a/varnish-doc/en/inside-varnish/article.xml b/varnish-doc/en/inside-varnish/article.xml index 64f83689..f5836fd4 100644 --- a/varnish-doc/en/inside-varnish/article.xml +++ b/varnish-doc/en/inside-varnish/article.xml @@ -177,6 +177,9 @@ man + + Additional man pages. + @@ -206,16 +209,61 @@
Principles of operation + Lorem ipsum dolor sit amet
Subsystems +
+ The management interface + + The management interface allows a person or process to + control certain aspects of the accelerator while it is + running, such as inspecting and setting run-time parameters, + starting and stopping the child process, and purging + objects. + + The commands accepted by the management interface fall + in two categories: management commands and child commands. + The former are handled by the management (parent) process, + while the latter are passed unmodified to the child process + and handled there. + + The management interface uses an extremely simple + text-based protocol described below. + + The user sends a single line of text consisting of one + or more words separated by linear whitespace, terminated by a + newline character. Words which contain linear whitespace must + be placed in double quotes; newline characters must be sent as + \n, backslash characters as + \\ and double quote characters as + \". + + The first word sent by the client is the command name, + and subsequent words are command arguments. + + The management process responds with a line consisting + of a three-digit status code, linear whitespace, a byte count, + and a newline character. If the byte count is non-zero, this + line is followed by that many bytes of additional data, plus a + newline character. + + Status code 200 indicates success; all other codes + indicate some kind of failure. Status codes between 100 and + 199 indicate a syntax error, an unknown command, or issues + with the number or nature of the arguments. Status codes + between 300 and 399 indicate a failure to carry out the + requested operation. The status code 400 indicates a + communications error. +
Data structures + Lorem ipsum dolor sit amet
@@ -225,11 +273,13 @@
varnishlog + Lorem ipsum dolor sit amet
varnishncsa + Lorem ipsum dolor sit amet
@@ -239,44 +289,125 @@
varnishstat + Lorem ipsum dolor sit amet
varnishhist + Lorem ipsum dolor sit amet
varnishtop + Lorem ipsum dolor sit amet
The test framework + Lorem ipsum dolor sit amet
Plugins - The trunk/varnish-tools directory in + The trunk/varnish-tools/ directory in the Varnish repository contains Varnish plugins for several popular system monitoring and administration frameworks.
Munin + Munin, named for one of the two ravens that in Norse + tradition sit on the shoulders of Odin, father of the gods, is a + monitoring and graphing tool built on top of Tobi Oetiker's + RRDtool and maintained largely by Linpro. + + The Varnish Munin plugin is written in Perl and resides in + trunk/varnish-tools/munin/. It can report + on any statistic (called aspects) stored in + the shared memory log, and can easily be extended to also report + values computed from these statistics (derived + aspects). + + When run, the plugin first invokes + varnishstat. Using the first column as keys, + it registers each available statistic in the + %ASPECTS hash, and stores their values in the + %varnishstat hash. It then verifies that the + requested aspect matches one of the items in + %ASPECTS, i.e. one of the statistics reported + by varnishstat or a predefined derived + aspect. Finally, it either looks up or computes the requested + value, and prints it to stdout in the format + expected by Munin. + + Aspects are of one of three types: + count (a monotonically increasing counter), + gauge (an instantaneous measurement) and + percent (a fraction expressed as a + percentage). The first two are used for automatically created + aspects (i.e. everything varnishstat + reports), while the third is used only for predefined derived + aspects. + + A count or gauge + aspect has a value which is either a key in + %varnishstat or a reference to an array + representing an expression; the first element of the array is an + arithmetic operator, and subsequent elements are the terms + (which can themselves be references to expression + arrays). + + A percent aspect has one or more + values; if it has more than one, Munin will stack them. Each + value has a numerator and a + denominator, each of which is, as above, + either a key in %varnishstat or an + expression. + + When adding or modifying derived aspects, care should be + taken not to create unnecessary inconsistencies between this + plugin and the Nagios plugin described in the next + section.
Nagios + Nagios is a web-based host and network monitoring tool. + The major difference between Nagios and Munin is that while + Munin records statistics and creates graphs, Nagios primarily + wants to know whether a particular part of the system has failed + or is about to fail. + + The Varnish Nagios plugin is written in C and resides in + trunk/varnish-tools/nagios/. It can report + any statistic stored in the shared memory log. It can also + fairly easily be extended to report computed statistics. + + + + When adding or modifying parameters, care should be taken + not to create unnecessary inconsistencies between this plugin + and the Munin plugin described in the previous section.
Webmin + Webmin is a web-based system configuration and + administration tool for Unix-like systems. + + The Varnish Webmin plugin is written in Perl and resides + in trunk/varnish-tools/webmin/. It can + perform all of the functions that are available through the + management process's command-line interface. + +
@@ -286,16 +417,19 @@
varnishadm + Lorem ipsum dolor sit amet
varnishreplay + Lorem ipsum dolor sit amet
fetcher + Lorem ipsum dolor sit amet
-- 2.39.5