Damian Krzeminski wrote:
I committed a series of MRTG patches from Andrei (thanks!). MRTG now
installs its own configuration files in /etc/sipxpbx/mrtg as a part of the
sipxconfig-mrtg RPM.
http://sipxecs.sipfoundry.org/ViewVC/sipXecs?view=rev&rev=13365
http://sipxecs.sipfoundry.org/ViewVC/sipXecs?view=rev&rev=13366
It's a big improvement over generate and overwriting the default
configuration file.
I made a typo in the patch for XCF-2400. You can find attached the fix
for it.
There are still couple of things that could be done to make MRTG
integration even less error-prone.
MRTG service installation should not be in any way related to sipXconfig.
New service (sipXmrtg) would be better. It could install all the
configuration files and scripts that are needed to make MRTG manageable and
configuratble form sipx. It should also provide a real prcess descriptor so
that sipxsupervisor can start/stop and report on MRTG.
I haven't tried with the new process definition the sipXsupervisor uses.
It might work with that.
Once it's done there are sipXconfig changes to implement: configuration
files can not be written directly to the disk, but pushed through XML/RPC
like everything else.
And when reviewing the patch I realized that there is little value in
parsing the template mrtg file. If we want to keep somehow a list of
potential targets template file is the least convenient way of doing that.
Devising simple XML schema or reusing setting file format should work match
better.
Since after those changes sipXconfig will be fully in charge of managing
MRTG we could stop parsing the configuration file itself (and we could
remove the mrtg parser entirely - yay!). Instead the list of targets for
all the servers should be just kept in SIPXCONFIG database and used to
re-generate configuration files whenever they are need.
Let me know if it makes sense,
Damian
There is an automated tool for generating mrtg.cfg files. It's called
cfgmaker. It could be an option to use that.
Andrei
>From aca0d5a934c89d0624b5e707c1127be1b900a208 Mon Sep 17 00:00:00 2001
From: Andrei <[EMAIL PROTECTED]>
Date: Thu, 11 Sep 2008 17:37:37 +0300
Subject: [PATCH] typo in build.xml file
---
sipXconfig/neoconf/build.xml | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/sipXconfig/neoconf/build.xml b/sipXconfig/neoconf/build.xml
index 1deb7ec..5fbcdf8 100644
--- a/sipXconfig/neoconf/build.xml
+++ b/sipXconfig/neoconf/build.xml
@@ -150,12 +150,12 @@
<!-- mrtg configuration files -->
<replace file="${dest.dir}${sipxpbx.conf.dir}/mrtg/mrtg.cfg"
propertyfile="${top.build.dir}/build.properties">
- <replacefilter token="@sipxpbx.var.dir@" property="sipxpbx.conf.dir" />
+ <replacefilter token="@sipxpbx.var.dir@" property="sipxpbx.var.dir" />
</replace>
<replace file="${dest.dir}${sipxpbx.conf.dir}/mrtg/mrtg-t.cfg"
propertyfile="${top.build.dir}/build.properties">
- <replacefilter token="@sipxpbx.var.dir@" property="sipxpbx.conf.dir" />
+ <replacefilter token="@sipxpbx.var.dir@" property="sipxpbx.var.dir" />
</replace>
<!-- copy jars and war -->
--
1.5.2.4
_______________________________________________
sipx-dev mailing list
[email protected]
List Archive: http://list.sipfoundry.org/archive/sipx-dev
Unsubscribe: http://list.sipfoundry.org/mailman/listinfo/sipx-dev