Jump to:

4872 Posts in 6961 Topics by 1470 members

Installing SilverStripe

SilverStripe Forums » Installing SilverStripe » Include Path Problem

Getting SilverStripe up and running on your computer and on your web server.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1 2 3
Go to End
Author Topic: 5640 Views
  • Seba
    Avatar
    Community Member
    2 Posts

    Include Path Problem Link to this post

    Hello

    I've a installation problem. I've search here in forum and have nothing found.
    After the click on install button ist installation running and stopt after "Building database schema..." with folowing error mesages.

    Warning: require_once(Zend/Log.php) [function.require-once]: failed to open stream: No such file or directory in /var/www/srv2/html/xxxx/sapphire/dev/Log.php on line 2

    Fatal error: require_once() [function.require]: Failed opening required 'Zend/Log.php' (include_path='.') in /var/www/srv2/html/xxxx/sapphire/dev/Log.php on line 2.

    My System is a debian 4 with PHP5 MySQL5.0.32 and Confixx.

    Does anybody what's wrong.

    Thank you very much.

    P.S.:
    Sorry, but my englisch isn't so good

  • Seba
    Avatar
    Community Member
    2 Posts

    Re: Include Path Problem Link to this post

    OK I’ve self found a answer on my problem. I had to add php_admin_value in my apache http config file with php_admin_value include_path "/var/www/srv2/html/nacktbilder/sapphire:/var/www/srv2/html/nacktbilder/sapphire/thirdparty:/var/www/srv2/html/nacktbilder/sapphire/parsers" and switch off open_basedir.
    Now works all fine.

  • MagicUK
    Avatar
    Community Member
    60 Posts

    Re: Include Path Problem Link to this post

    Sorry for being a total newbie but I would really appreciate if someone could explain this in laymons terms.

    I'm also getting the error:

    require_once() [function.require]: Failed opening required 'Zend/Log.php' (include_path='/usr/lib/php:/usr/local/lib/php:/usr/local/cpanel/3rdparty/lib/php:/tmp:/home:.:/home/issl/php') in /home/issl/public_html/sapphire/dev/Log.php on line 2

    when trying to install.

    I added the following line to my .htaccess file at the very end:

    php_value include_path "/home/issl/public_html/sapphire:/home/issl/public_html/sapphire/parsers:/home/issl/public_html/sapphire/thirdparty"

    But I'm still getting the error.

    And I don't know how to 'swtich off' open_basedir. Any help would make me a happy (and less stressed) bunny.

  • MagicUK
    Avatar
    Community Member
    60 Posts

    Re: Include Path Problem Link to this post

    Can no one help me. Am I missing something?

  • joelpittet
    Avatar
    Community Member
    4 Posts

    Re: Include Path Problem Link to this post

    I had the same problem, I am on a mac. Seems set_include_path wasn't working for me.
    Easy test, if it doesn't change...

    echo get_include_path();

    echo   set_include_path(str_replace('.' . PATH_SEPARATOR, '.' . PATH_SEPARATOR
          . BASE_PATH . '/sapphire' . PATH_SEPARATOR
          . BASE_PATH . '/sapphire/parsers' . PATH_SEPARATOR
          . BASE_PATH . '/sapphire/thirdparty' . PATH_SEPARATOR
          , get_include_path()));
          
    echo get_include_path();

    The problem was i didn't have .: in my include_path
    Which seemd to stop the set_include_path().

    Hope that helps some people. This could be avoided by just using some DOCROOT paths for the includes.

  • Sean
    Avatar
    Forum Moderator
    921 Posts

    Re: Include Path Problem Link to this post

    The way I see it is set_include_path() shouldn't always assume the PATH_SEPARATOR bit ":" is in the existing include path.

    I've filed a bug ticket here: http://open.silverstripe.org/ticket/6201

    If you've got any potential patches or any further comments to add, please update the ticket.

    Thanks!
    Sean

  • Sean
    Avatar
    Forum Moderator
    921 Posts

    Re: Include Path Problem Link to this post

    joelpittet: I've attached a patch to the ticket here: http://open.silverstripe.org/ticket/6201

    Could you apply the patch to your working copy and see if it fixes the problem?

    Thanks,
    Sean

  • Sean
    Avatar
    Forum Moderator
    921 Posts

    Re: Include Path Problem Link to this post

    I've committed a change to set_include_path() in Core.php.
    It's in branches/2.4 (the development 2.4 branch) for now, but it will appear in SilverStripe 2.4.4 which should be released shortly.

    This should fix the problems where environments have different values for the existing include path.

    Here's the changeset: http://open.silverstripe.org/changeset/113976

    Thanks for the feedback guys!

    Thanks,
    Sean

    5640 Views
Page: 1 2 3
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.