Uploaded image for project: 'OpenNMS'
  1. OpenNMS
  2. NMS-8775

RRDtool 1.6 doesn't like vames called ds

    Details

      Description

      For some unknown reason this doesn't affect Horizon 18, but Meridian 16 using RRDtool 1.6.0 complains when naming a vname "ds".

      For example:

      [root@onms-meridian rrd]# /usr/bin/rrdtool graph /opt/opennms/data/tmp/opennms.rrdtool.3343676518579722860.png --start=1475085900 --end=1475172300 DEF:ds="snmp/4/Se3_0_201/ifOutOctets.rrd":ifOutOctets:AVERAGE PRINT:ds:MIN:"%le" PRINT:ds:AVERAGE:"%le" PRINT:ds:MAX:"%le"
      ERROR: undefined vname ds
      

      But, if I rename it to something else like "ds1":

      [root@onms-meridian rrd]# /usr/bin/rrdtool graph /opt/opennms/data/tmp/opennms.rrdtool.3343676518579722860.png --start=1475085900 --end=1475172300 DEF:ds1="snmp/4/Se3_0_201/ifOutOctets.rrd":ifOutOctets:AVERAGE PRINT:ds1:MIN:"%le" PRINT:ds1:AVERAGE:"%le" PRINT:ds1:MAX:"%le"
      0x0
      6.625783e+01
      6.669313e+01
      6.719437e+01
      

      Because of this error, the summary report obtained through an URL like the following is not working on Meridian (but works on Horizon):

      curl -u admin:admin "http://localhost:8980/opennms/summary/results.htm?filterRule=ipaddr%3D%2712.0.0.2%27&startTime=1475085900&endTime=1475172300&attributeSieve=if(In|Out)Octets"
      

      The command is generated inside the DefaultRrdDao.java (to be more precise, the method named getPrintValues):

      Caused by: org.opennms.netmgt.rrd.RrdException: Can't execute command /usr/bin/rrdtool graph /opt/opennms/data/tmp/opennms.rrdtool.8634894254809112395.png --start=1475085900 --end=1475172300 DEF:ds="snmp/4/Se3_0_201/ifOutOctets.rrd":ifOutOctets:AVERAGE PRINT:ds:MIN:"%le" PRINT:ds:AVERAGE:"%le" PRINT:ds:MAX:"%le"
              at org.opennms.netmgt.rrd.rrdtool.AbstractJniRrdStrategy.createGraphReturnDetails(AbstractJniRrdStrategy.java:195) ~[opennms-rrdtool-api-2016.1.3.jar:?]
              at org.opennms.netmgt.rrd.QueuingRrdStrategy.createGraphReturnDetails(QueuingRrdStrategy.java:1298) ~[opennms-rrd-api-2016.1.3.jar:?]
              at org.opennms.netmgt.dao.support.DefaultRrdDao.getPrintValues(DefaultRrdDao.java:110) ~[opennms-dao-2016.1.3.jar:?]
              at org.opennms.web.svclayer.rrd.support.DefaultRrdSummaryService$1.getValues(DefaultRrdSummaryService.java:390) ~[opennms-webapp-2016.1.3.jar:?]
              at org.opennms.web.svclayer.rrd.support.DefaultRrdSummaryService$1.addAttributes(DefaultRrdSummaryService.java:376) ~[opennms-webapp-2016.1.3.jar:?]
              at org.opennms.web.svclayer.rrd.support.DefaultRrdSummaryService$1.addResource(DefaultRrdSummaryService.java:365) ~[opennms-webapp-2016.1.3.jar:?]
              at org.opennms.web.svclayer.rrd.support.DefaultRrdSummaryService$1.addResource(DefaultRrdSummaryService.java:358) ~[opennms-webapp-2016.1.3.jar:?]
              at org.opennms.web.svclayer.rrd.support.DefaultRrdSummaryService$1.visitNode(DefaultRrdSummaryService.java:313) ~[opennms-webapp-2016.1.3.jar:?]
              at org.opennms.netmgt.dao.support.FilterWalker.walk(FilterWalker.java:61) ~[opennms-dao-2016.1.3.jar:?]
              at org.opennms.web.svclayer.rrd.support.DefaultRrdSummaryService.getSummary(DefaultRrdSummaryService.java:397) ~[opennms-webapp-2016.1.3.jar:?]
              at org.opennms.web.svclayer.rrd.support.DefaultRrdSummaryService.getSummary(DefaultRrdSummaryService.java:462) ~[opennms-webapp-2016.1.3.jar:?]
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_92]
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_92]
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_92]
              at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_92]
              at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) ~[org.apache.servicemix.bundles.spring-aop-4.0.5.RELEASE_1.jar:?]
              at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190) ~[org.apache.servicemix.bundles.spring-aop-4.0.5.RELEASE_1.jar:?]
              at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[org.apache.servicemix.bundles.spring-aop-4.0.5.RELEASE_1.jar:?]
      
      ...
      
      Caused by: org.opennms.netmgt.rrd.RrdException: ERROR: undefined vname ds
      
              at org.opennms.netmgt.rrd.rrdtool.AbstractJniRrdStrategy.createGraphAsByteArray(AbstractJniRrdStrategy.java:95) ~[opennms-rrdtool-api-2016.1.3.jar:?]
              at org.opennms.netmgt.rrd.rrdtool.AbstractJniRrdStrategy.createGraph(AbstractJniRrdStrategy.java:68) ~[opennms-rrdtool-api-2016.1.3.jar:?]
              at org.opennms.netmgt.rrd.rrdtool.AbstractJniRrdStrategy.createGraphReturnDetails(AbstractJniRrdStrategy.java:165) ~[opennms-rrdtool-api-2016.1.3.jar:?]
              at org.opennms.netmgt.rrd.QueuingRrdStrategy.createGraphReturnDetails(QueuingRrdStrategy.java:1298) ~[opennms-rrd-api-2016.1.3.jar:?]
              at org.opennms.netmgt.dao.support.DefaultRrdDao.getPrintValues(DefaultRrdDao.java:110) ~[opennms-dao-2016.1.3.jar:?]
      

        Attachments

          Activity

            People

            • Assignee:
              agalue Alejandro Galue
              Reporter:
              agalue Alejandro Galue
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: