Ad Widget

Collapse

Not all graphs showing

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jclark
    Junior Member
    • Oct 2004
    • 2

    #1

    Not all graphs showing

    Before I spend the time digging into the code itself I figured I would ask here to see if this is a common problem and already known and solved. I just downloaded and installed version 1.0.

    Setup:

    Debian
    linux kernel 2.6.8
    php 4.1.2
    mysql 3.23.49
    apache 1.3.26

    The problem is that not all the images are created successfully. After testing a few things I find this.

    PHP pages that generate images:
    chart_diff.php
    trend.php
    chart3.php
    chart5.php

    PHP pages that fail to generate images:
    chart.php
    map.php
    chart2.php

    I am looking for the relationship between the stuff that fails.

    Since I have just installed there is always the strong possibility I have something configured incorrectly. Looking for suggestions.

    Jim
  • Alexei
    Founder, CEO
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Sep 2004
    • 5654

    #2
    I'm sure you have everything correctly configured.

    The problem is obviously related to wrong version of GD library compiled into PHP.

    Do the following in include/classes.inc.php:

    Uncomment this line:
    Code:
    //					 Header( "Content-type: text/html");
    and comment this one:
    Code:
    					 Header( "Content-type: image/png");
    Then try to view chart.php in a browser. You will see self explanatory error or warning messages.
    Alexei Vladishev
    Creator of Zabbix, Product manager
    New York | Tokyo | Riga
    My Twitter

    Comment

    • jclark
      Junior Member
      • Oct 2004
      • 2

      #3
      Thanks Alexei for the quick response. This project obviously has required lots of work and if I get things working the way I would like, it will save me huge amounts of time. I appreciate the effort.

      Originally posted by Alexei
      I'm sure you have everything correctly configured.

      The problem is obviously related to wrong version of GD library compiled into PHP.
      That would have been my first guess *if* the other images weren't created successfully. Output from phpinfo:

      GD Support enabled
      GD Version 1.6.2 or higher
      FreeType Support enabled
      FreeType Linkage with freetype
      T1Lib Support enabled
      JPG Support enabled
      PNG Support enabled
      WBMP Support enabled

      Do the following in include/classes.inc.php:

      Uncomment this line:
      Code:
      //					 Header( "Content-type: text/html");
      and comment this one:
      Code:
      					 Header( "Content-type: image/png");
      Then try to view chart.php in a browser. You will see self explanatory error or warning messages.
      Tried that. The only output generated is the header itself. Nothing else.

      I have a bit of php experience and may spend a little time playing over the weekend. I will let you know what I find.

      Thanks again.

      Jim

      Comment

      • Cirrus
        Junior Member
        • Oct 2004
        • 5

        #4
        Hi there.
        I had the same problem (or the same symptoms considering a different problem).
        Maybe this seems too obvious, and maybe you've already done that, but in my case it helped to go through the MySQL's Zabbix database and examine-fix all the tables (I did it with PHPMyAdmin and afterwards once again with "myisamchk").
        Well... maybe that's not the answer you were looking for, but it's an answer
        Bye

        Comment

        Working...