sipXecs

sipx-mrtg subsystem should not use hardcoded path

Details

  • Type: Improvement Improvement
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Won't Fix
  • Affects Version/s: None
  • Fix Version/s: None
  • Component/s: None
  • Rank:
    5725   
  • Labels:
  • Description:
    The attached patch includes changes necessary on FreeBSD to adjust th path for the sipx mrtg subsystem. The patch needs to be reviewed and might not work as posted.
  1. sipx-mrtg.patch
    (4 kB)
    Martin Steinmann
    2008-01-08 14:53

Issue Links

Activity

Hide
Al Campbell added a comment - 2008-01-10 14:28
Could you please review this to ensure it will won't make existing functionality not work.
Show
Al Campbell added a comment - 2008-01-10 14:28 Could you please review this to ensure it will won't make existing functionality not work.
Hide
Martin Steinmann added a comment - 2008-01-11 20:37
> Would you mind having a quick look at the patch below? On FreeBSD
the
> path for the mrtg executable is /usr/local/bin and I am wondering
> whether the parameter ${sysdir.bin} would work in a Java file.
>
>
>

No it would not. It has to be injected from the spring file, but even
then {sysdir.bin} is probably not what you are looking for since it
{sysdir.bin} is influenced by prefix and location of mrtg probably
should not be.
I think we need an issue for that - I missed the fact that MRTG location

is hardcoded. Looks like it should be configure variable.

D.
Show
Martin Steinmann added a comment - 2008-01-11 20:37 > Would you mind having a quick look at the patch below? On FreeBSD the > path for the mrtg executable is /usr/local/bin and I am wondering > whether the parameter ${sysdir.bin} would work in a Java file. > > > No it would not. It has to be injected from the spring file, but even then {sysdir.bin} is probably not what you are looking for since it {sysdir.bin} is influenced by prefix and location of mrtg probably should not be. I think we need an issue for that - I missed the fact that MRTG location is hardcoded. Looks like it should be configure variable. D.
Hide
Lih-Shyng Tzeng added a comment - 2008-01-21 22:46
Move this to 4.0 since it is a minor improvement and since we are reaching the end of the 3.10 cycle.
Show
Lih-Shyng Tzeng added a comment - 2008-01-21 22:46 Move this to 4.0 since it is a minor improvement and since we are reaching the end of the 3.10 cycle.
Hide
Martin Steinmann added a comment - 2008-02-01 18:55
This is another hard coded path that required patching for FreeBSD:

Index: MRTGConfig.java
===================================================================
--- MRTGConfig.java (revision 11839)
+++ MRTGConfig.java (working copy)
@@ -41,7 +41,7 @@
     private static final String LOG_FORMAT_TOKEN = "LogFormat";
     private static final String PATH_ADD_TOKEN = "PathAdd";
     private static final String DEFAULT_LOG_FORMAT = "rrdtool";
- private static final String DEFAULT_PATH_ADD = "/usr/bin";
+ private static final String DEFAULT_PATH_ADD = "/usr/local/bin";

     private static final String COMMA = ",";
     private static final String POUND = "#";
Show
Martin Steinmann added a comment - 2008-02-01 18:55 This is another hard coded path that required patching for FreeBSD: Index: MRTGConfig.java =================================================================== --- MRTGConfig.java (revision 11839) +++ MRTGConfig.java (working copy) @@ -41,7 +41,7 @@      private static final String LOG_FORMAT_TOKEN = "LogFormat";      private static final String PATH_ADD_TOKEN = "PathAdd";      private static final String DEFAULT_LOG_FORMAT = "rrdtool"; - private static final String DEFAULT_PATH_ADD = "/usr/bin"; + private static final String DEFAULT_PATH_ADD = "/usr/local/bin";      private static final String COMMA = ",";      private static final String POUND = "#";
Hide
Andrei Niculae added a comment - 2008-03-11 10:31
Because of the changes introduced by XCF-2348, most of the issues regarding paths under FreeBSD should be resolved.
However, there is still this one: MIBS_DIR=@PREFIX@/share/snmp/mibs which should not look like this, because the MIBS_DIR should be realative to the snmp prefix, not to sipx prefix.
Also, regarding the last comment by Martin:
I believe DEFAULT_PATH_ADD should remain /usr/bin, since this will eventually be overwritten by the setting from the mrtg template configuration.
In the patch for XCF-2348, I've created a way to change this according to the platform, so it should be easy.

After XCF-2348 enters the mainline, I'll remake the patch posted here, but since I cannot test it, I'm going to need some help.

Regards,
Andrei

Show
Andrei Niculae added a comment - 2008-03-11 10:31 Because of the changes introduced by XCF-2348, most of the issues regarding paths under FreeBSD should be resolved. However, there is still this one: MIBS_DIR=@PREFIX@/share/snmp/mibs which should not look like this, because the MIBS_DIR should be realative to the snmp prefix, not to sipx prefix. Also, regarding the last comment by Martin: I believe DEFAULT_PATH_ADD should remain /usr/bin, since this will eventually be overwritten by the setting from the mrtg template configuration. In the patch for XCF-2348, I've created a way to change this according to the platform, so it should be easy. After XCF-2348 enters the mainline, I'll remake the patch posted here, but since I cannot test it, I'm going to need some help. Regards, Andrei

People

Dates

  • Created:
    2008-01-08 14:53
    Updated:
    2010-08-22 15:27
    Resolved:
    2010-04-20 07:33