4.1 > 4.1.1 upgrade - odd behaviour

cmanns

Well-Known Member
#21
Could not duplicate the issue. sample code snippet is as follows:
Code:
<?php
include '../../test1/public_html/test1.php';
...
?>
open_basedir is empty.
We enabled WHM/cPanel open_basedir, one site already had issues with it.

A series of includes to take a site forums info and put it on the front page.

Includes like

include "forums/blah/bluuu.php" and required "conf_global.php; in the forums dir which the conf was also in that dir was now failing too. Code that worked for years.

I added a ./ infront of every include, switched require to include_once for some reason required "./blah" caused issues. On a few I did the full path of /home/username/public_html/path/to/php/include

Now it works fine.

pen_basedir no value no value
include_path .:/usr/lib/php:/usr/local/lib/php .:/usr/lib/php:/usr/local/lib/php

Yet phpinfo shows the above, so I ignored module they said here http://www.litespeedtech.com/support/forum/showthread.php?t=1033&page=2 and then the home made page went to wonk again


Coppermine gallery online users include script uses the below to include config, we got a unable to connect error
require ('include/config.inc.php');


The error we got in error_log

8-Jun-2011 00:10:41] PHP Warning: include_once() [<a href='function.include'>function.include</a>]: Failed opening '/home/boo/public_htmlrenders/include/config.inc.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/boo/public_html/renders/onlinestats_external.php on line 23

We ended up using


include_once $_SERVER['DOCUMENT_ROOT'] . '/renders/include/config.inc.php';

Is this similar to your problem?
 

webizen

Well-Known Member
#23
It is likely caused by concurrent_php module support in the new version (open_basedir is not empty). old version does not support that module and simply ignore the whole section (hence open_basedir becomes empty).

Code:
<IfModule concurrent_php.c>
        php4_admin_value open_basedir ".:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/$
        php5_admin_value open_basedir ".:/usr/lib/php:/usr/local/lib/php:/tmp"
    </IfModule>
    <IfModule !concurrent_php.c>
        <IfModule mod_php4.c>
            php_admin_value open_basedir ".:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/ph$
        </IfModule>
    </IfModule>
 
Top