Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Installing SilverStripe

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

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

Include Path Problem


Go to End
Reply

21 Posts   6078 Views

Avatar
Seba

11 May 2010 at 1:09am (Last edited: 11 May 2010 1:12am), Community Member, 2 Posts

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

Avatar
Seba

11 May 2010 at 10:35pm Community Member, 2 Posts

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.

Avatar
MagicUK

16 November 2010 at 9:39am Community Member, 60 Posts

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.

Avatar
MagicUK

17 November 2010 at 9:39am Community Member, 60 Posts

Can no one help me. Am I missing something?

Avatar
joelpittet

18 November 2010 at 11:36am Community Member, 4 Posts

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.

Avatar
Sean

18 November 2010 at 12:25pm (Last edited: 18 November 2010 12:27pm), Forum Moderator, 921 Posts

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

Avatar
Sean

18 November 2010 at 10:59pm (Last edited: 18 November 2010 11:00pm), Forum Moderator, 921 Posts

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

Avatar
Sean

22 November 2010 at 12:15pm (Last edited: 22 November 2010 12:16pm), Forum Moderator, 921 Posts

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

Go to Top