Thu Jul 5 13:52:08 PDT 2007
- Previous message: [Slony1-commit] slony1-engine/tools mkmediawiki.pl
- Next message: [Slony1-commit] slony1-engine/src/slon runtime_config.c
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Update of /home/cvsd/slony1/slony1-engine/doc/adminguide In directory main.slony.info:/tmp/cvs-serv10795/doc/adminguide Modified Files: monitoring.sgml Log Message: Add in [[Category:foo]] support for automagic indexing to mkmediawiki.pl script Index: monitoring.sgml =================================================================== RCS file: /home/cvsd/slony1/slony1-engine/doc/adminguide/monitoring.sgml,v retrieving revision 1.37 retrieving revision 1.38 diff -C2 -d -r1.37 -r1.38 *** monitoring.sgml 11 Jun 2007 16:02:50 -0000 1.37 --- monitoring.sgml 5 Jul 2007 20:52:06 -0000 1.38 *************** *** 95,98 **** --- 95,133 ---- Options[db_replication_lagtime]: gauge,nopercent,growright </programlisting> + + <para> Alternatively, Ismail Yenigul points out how he managed to + monitor slony using <application>MRTG</application> without installing + <application>SNMPD</application>.</para> + + <para> Here is the mrtg configuration</para> + + <programlisting> + Target[db_replication_lagtime]:`/bin/snmpReplicationLagTime.sh 2` + MaxBytes[db_replication_lagtime]: 400000000 + Title[db_replication_lagtime]: db: replication lag time + PageTop[db_replication_lagtime]: <H1>db: replication lag time</H1> + Options[db_replication_lagtime]: gauge,nopercent,growright + </programlisting> + + <para> and here is the modified version of the script</para> + + <programlisting> + # cat /bin/snmpReplicationLagTime.sh + #!/bin/bash + + output=`/usr/bin/psql -U slony -h 192.168.1.1 -d endersysecm -qAt -c + "select cast(extract(epoch from st_lag_time) as int8) FROM _mycluster.sl_status WHERE st_received = $1"` + echo $output + echo $output + echo + echo + # end of script# + </programlisting> + + + <note><para> MRTG expects four lines from the script, and since there + are only two lines provided, the output must be padded to four + lines. </para> </note> + </sect2> *************** *** 194,198 **** <filename>tools</filename>, may be used to generate a cluster summary compatible with the popular <ulink url="http://www.mediawiki.org/"> ! MediaWiki </ulink> software. </para> <para> The gentle user might use the script as follows: </para> --- 229,239 ---- <filename>tools</filename>, may be used to generate a cluster summary compatible with the popular <ulink url="http://www.mediawiki.org/"> ! MediaWiki </ulink> software. Note that the ! <option>--categories</option> permits the user to specify a set of ! (comma-delimited) categories with which to associate the output. If ! you have a series of &slony1; clusters, passing in the option ! <option>--categories=&slony1;</option> leads to the MediaWiki instance ! generating a category page listing all &slony1; clusters so ! categorized on the wiki. </para> <para> The gentle user might use the script as follows: </para> *************** *** 201,205 **** ~/logtail.en> mvs login -d mywiki.example.info -u "Chris Browne" -p `cat ~/.wikipass` -w wiki/index.php Doing login with host: logtail and lang: en ! ~/logtail.en> perl $SLONYHOME/tools/mkmediawiki.pl --host localhost --database slonyregress1 --cluster slony_regress1 > Slony_replication.wiki ~/logtail.en> mvs commit -m "More sophisticated generated Slony-I cluster docs" Slony_replication.wiki Doing commit Slony_replication.wiki with host: logtail and lang: en --- 242,246 ---- ~/logtail.en> mvs login -d mywiki.example.info -u "Chris Browne" -p `cat ~/.wikipass` -w wiki/index.php Doing login with host: logtail and lang: en ! ~/logtail.en> perl $SLONYHOME/tools/mkmediawiki.pl --host localhost --database slonyregress1 --cluster slony_regress1 --categories=Slony-I > Slony_replication.wiki ~/logtail.en> mvs commit -m "More sophisticated generated Slony-I cluster docs" Slony_replication.wiki Doing commit Slony_replication.wiki with host: logtail and lang: en
- Previous message: [Slony1-commit] slony1-engine/tools mkmediawiki.pl
- Next message: [Slony1-commit] slony1-engine/src/slon runtime_config.c
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-commit mailing list