Error load the Graph library and link proble

BASE-user
sgruttmann
2007-11-19
2013-06-03
  • sgruttmann
    sgruttmann
    2007-11-19

    Hi,

    I have installed BASE V1.3.8 and  can not load Graph Alert Data.
    Error Message as following:
    Error loading the Graphing library:

    Check your Pear::Image_Graph installation!

    Following pear packges are installed:

    Installed packages, channel pear.php.net:

    Package          Version State
    Archive_Tar      1.3.2   stable
    Console_Getopt   1.2.3   stable
    Image_Canvas     0.3.1   alpha
    Image_Color      1.0.2   stable
    Image_Graph      0.7.2   alpha
    Log              1.9.11  stable
    MDB2             2.4.1   stable
    Numbers_Roman    1.0.2   stable
    Numbers_Words    0.15.0  beta
    PEAR             1.6.2   stable
    Structures_Graph 1.0.2   stable
    XML_RPC          1.5.1   stabl

    Do I need to to further configurations? I `d searched in Forum and User list without sucess.
    Further the links to other pages do not working properly.
    For example if I go to "Administration" I get the message "Object not found"  link is as following http://localhost/base/base/admin/index.php but it must be

    http://localhost/base/admin/index.php

    I have the same problem with V1.3.5

    I´m not very familar with php and would be thankful about any help.

    thanks and regards
    Susanne

     
    • sgruttmann
      sgruttmann
      2007-11-19

      Following Error messages appearing in appache error.log

      File does not exist: /srv/www/htdocs/images, referer: http://localhost/base/admin/base_roleadmin.php?action=list
      File does not exist: /srv/www/htdocs/styles, referer: http://dehanlx05/base/admin/base_roleadmin.php?action=list

      PHP Notice:  Undefined index:  archive in /srv/www/htdocs/base/base_main.php on line 77
      PHP Notice:  Undefined index:  archive in /srv/www/htdocs/base/base_main.php on line 83
      PHP Notice:  Undefined index:  archive in /srv/www/htdocs/base/base_main.php on line 114
      PHP Notice:  Undefined index:  archive in /srv/www/htdocs/base/base_main.php on line 302
      PHP Notice:  Undefined index:  archive in /srv/www/htdocs/base/base_main.php on line 94
      PHP Notice:  Undefined index:  archive in /srv/www/htdocs/base/base_main.php on line 94

      File does not exist: /srv/www/htdocs/styles, referer: http://localhost/base/base_graph_main.php

       
      • Kevin Johnson
        Kevin Johnson
        2007-11-19

        Two things I noticed here.  One, your error reporting level is way to high in your php.ini.  The README has the way it is supposed to be set.  Second, it appears that either you have not installed all of the pieces, permissions are set up wrong or you have not configured base_conf.php correctly.  This is because of the error that is logging the "File does not exist".

        How did you install BASE?

        Kevin

         
        • sgruttmann
          sgruttmann
          2007-11-19

          I´ve installed base with the "Snort, MySQL 5, Apache, and BASE for Gentoo Linux" howto by Chris Vespermann which I found on snort.org

          I found one error in configuration

          $BASE_urlpath = 'dehanlxxx/base';

          I changed to $BASE_urlpath = 'http://dehanlxxx/base';
          Now the links are working :-))

          That´s what the howto said:
          $BASE_urlpath = "mybox.mydomain.com/base";

          But still have the problem with the Graph_Library

          Only what I did there was installing the pear packages and set permissions (for a try) of the  /etc/pear directory to wwwrun:www

          Susanne

           
          • Kevin Johnson
            Kevin Johnson
            2007-11-19

            I think the best thing would be to follow Patrick Harper's Guide since Suse is a bit closer to Redhat then Gentoo.  I also have never reviewed the guide you mentioned so am not sure what it has you do.

            Kevin

             
    • Kevin Johnson
      Kevin Johnson
      2007-11-19

      Could you please provide some information about your install?  What OS and version of PHP are you running?

      Thanks
      Kevin

       
      • sgruttmann
        sgruttmann
        2007-11-19

        Hi Kevin,

        thanks for your fast reply.

        We are running SUSE 9.3 and PHP 5.1.6

        regards
        Susanne

         
    • sgruttmann
      sgruttmann
      2007-11-23

      Hi,
      really need somebodys help........

      still have the problem to load the Graph library.
      I read some threads where people asked same question. Does nobody know where the problem is?

      i did following without success:

      - installed required pear packages ( see my first thread)
      - changed user permission to wwwrun
      - changed the path in the base_graph_common.php, now no error message but a blanc page

      Now I have no idea anymore

      I run
      Suse9.3
      Apache2
      PHP5.1.6

      I would be really happy if somebody can bring me on the right path :-)

      Susanne

       
      • Kevin Johnson
        Kevin Johnson
        2007-11-24

        Could you check your logs and see if there are any errors reported?  If not, please up the error level and try again.

        Kevin

         
    • sgruttmann
      sgruttmann
      2007-11-26

      Hi Kevin,

      I´ve checked error_reporting in php.ini and it´s set to 2047. Is this what you mean?
      I can´t see any error in my loggings ( access.log and error.log).

      I´m not very familiar with php but for my understandig this is already the highest log level isn`t it?

      thanks and regards
      Susanne

       
      • Hello,

        have you tried the test files included
        in Image_Graph-0.7.2.tgz?

        For example by copying Image_Graph-0.7.2/tests/axis/category.php
        into the DocumentRoot directory of your apache and then loading http://localhost/category.php

        This might get you closer to what the problem exactly is. Do not expect BASE to draw the graphics unless those test files work properly.

        And if they don't:
        - Is /usr/share/pear/Structures/Graph.php
        or wherever Graph.php is located
        on your computer readable by everyone?
        - Is the location of that file in line
        with what "pear config-show" puts out?
        - Do you run AppArmor? Is perhaps this
        preventing apache from loading Graph.php? (Suse does not use selinux,
        does it?)

        Bye, bye,

        Juergen

         
    • sgruttmann
      sgruttmann
      2007-12-03

      Hi Juergen,

      many thanks for your answer and sorry for my late response.

      I did the tests you`ve suggested but I`m beeing still in the dark.

      - If I loading http://localhost/category.php I have a blank page
      - I did chmod 777 for pear directory
      - follwowing error I have

      PHP Warning:  require_once(Image/Graph/Axis.php) [<a href='function.require-once'>function.require-once</a>]: failed to open stream: No such file or directory in /srv/www/htdocs/Category.php on line 34

      PHP Fatal error:  require_once() [<a href='function.require'>function.require</a>]: Failed opening required 'Image/Graph/Axis.php' (include_path='.:/php/includes:/usr/share/php:/usr/local/lib/php/JpGraph:/usr/local/lib/php/Smarty:/usr/share/pear/Image/Graph.php') in /srv/www/htdocs/Category.php on line 34

      That´s what the "pear config-show" says:
      Configuration (channel pear.php.net):
      =====================================
      Auto-discover new Channels     auto_discover    <not set>
      Default Channel                default_channel  pear.php.net
      HTTP Proxy Server Address      http_proxy       <not set>
      PEAR server [DEPRECATED]       master_server    pear.php.net
      Default Channel Mirror         preferred_mirror pear.php.net
      Remote Configuration File      remote_config    <not set>
      PEAR executables directory     bin_dir          /usr/bin
      PEAR documentation directory   doc_dir          /usr/share/pear/docs
      PHP extension directory        ext_dir          /usr/lib/php5/extensions
      PEAR directory                 php_dir          /usr/share/pear
      PEAR Installer cache directory cache_dir        /tmp/pear/cache
      PEAR data directory            data_dir         /usr/share/pear/data
      PEAR Installer download        download_dir     /usr/temp/download
      directory
      PHP CLI/CGI binary             php_bin          /usr/bin/php5
      php.ini location               php_ini          <not set>
      PEAR Installer temp directory  temp_dir         /usr/temp
      PEAR test directory            test_dir         /usr/share/pear/tests
      Cache TimeToLive               cache_ttl        3600
      Preferred Package State        preferred_state  stable
      Unix file mask                 umask            22
      Debug Log Level                verbose          1
      PEAR password (for             password         <not set>
      maintainers)
      Signature Handling Program     sig_bin          /usr/bin/gpg
      Signature Key Directory        sig_keydir       /etc/php5/cli/pearkeys
      Signature Key Id               sig_keyid        <not set>
      Package Signature Type         sig_type         gpg
      PEAR username (for             username         <not set>
      maintainers)
      User Configuration File        Filename         /root/.pearrc
      System Configuration File      Filename         /etc/php5/cli/pear.conf

      - No there´s no AppArmor running on the server

      I hope you can light me a little bit up on this :-)

      many thanks and kind regards
      Susanne

       
      • Hello,

        the include_path used by php is not correct:

        >(include_path='.:/php/includes:/usr/share/php:/usr/local/lib/php/JpGraph:/usr/local/lib/php/Smarty:/usr/share/pear/Image/Graph.php')

        whereas PEAR has installed almost everything under /usr/share/pear:

        > PEAR directory  php_dir /usr/share/pear

        Moreover /usr/share/pear/Image/Graph.php
        is actually not correct, either. This way
        php does find Graph.php, but nothing
        else.

        The include path should at least contain:

                .:/usr/share/pear:/usr/share/php

        Add this to your /etc/php.ini (or whereever that
        file is located) (look for the line "include_path").
        Maybe apache needs a restart after that.
        Rebooting,however, should not be required.

        If all of this fails, have a look at what
        phpinfo() says, for example by writing the
        following file to the DocumentRoot
        (presumably /srv/www/htdocs/ on your server):

        show_me_config.php:

                <?php
                phpinfo();
                ?>

        And then

                http://localhost/show_me_config.php

        It starts with "PHP version..."
        and MUST present a line like

        include_path    .:/usr/share/pear:/usr/share/php        .:/usr/share/pear:/usr/share/php

        (and additionally including all the extra stuff you have
        configured - but only paths, not files).

        Bye, bye

        Juergen

         
    • sgruttmann
      sgruttmann
      2007-12-06

      Hurray it´s working now.

      Thank you soo much for spending time on this.

      Would be great if somebody can add this to official documentation for BASE install.This would be easier for newbies like me without programming experiences.

      Thank you very much Juergen

      kind regards
      Susanne :-))))