You are here: Re: open_basedir is commneted out in my php.ini file, yet I still get the error messages « PHP Programming Language « IT news, forums, messages
Re: open_basedir is commneted out in my php.ini file, yet I still get the error messages

Posted by lawrence k on 03/14/07 06:16

On Mar 13, 2:20 pm, luiheidsgoe...@hotmail.com wrote:
> Oh dear...GoogleGroups.... No newsserver in sight here...
>
> lawrence k schreef:
>
> > > e path: /home/httpd/vhosts/monkeyclaus.org/httpdocs/media/audio/
> > > AlexSchein/SpeedofLight/TheWhiteFlag.mp3
>
> httpdocs....
>
>
>
> > > Warning: file_exists(): open_basedir restriction in effect. File(/home/
> > > httpd/vhosts/monkeyclaus.org/httpdocs/media/audio/AlexSchein/
> > > SpeedofLight/TheWhiteFlag.mp3) is not within the allowed path(s): (/
> > > home/httpd/vhosts/monkeyclaus.org/httpsdocs:/tmp) in /home/httpd/
> > > vhosts/monkeyclaus.org/httpsdocs/site_specific_files/makePurchase.php
>
> httpSdocs
>
> > I discovered that if the server uses Plesk, you have to edit the
> > vhost.conf file for the domain. I edited the file, and added the
> > php_admin_value line that you can see here:
>
> > <Directory /home/httpd/vhosts/monkeyclaus.org/httpdocs>
>
> Which won't do you any good, as you're not in that directory....
> You're in httpSdocs


I'm not sure I understand you. I have a script in the httpsdocs folder
that is trying to use file_exists() on files in the httpdocs folder. I
can't do that right now because of the open_basedir restrictions. That
is why I have been trying to turn off open_basedir. Apparently the
problem I face has something to do with the way that Plesk overwrites
the default config info.

I'm working on a server running Enterprise Redhat 3.

I am have been researching this issue all day, and changing different
aspects of my server, but so far nothing has worked.

Here is what I've done so far.

In the php.ini file I put this line:

; open_basedir, if set, limits all file operations to the defined
directory
; and below. This directive makes most sense if used in a per-
directory
; or per-virtualhost web server configuration file. This directive is
; *NOT* affected by whether Safe Mode is turned On or Off.
open_basedir = none


In the httpd.conf file I put this:

php_admin_value open_basedir none


In the vhost.conf file I put this:

<Directory /home/httpd/vhosts/monkeyclaus.org/httpdocs>
RewriteEngine On
AllowOverride All
php_admin_value open_basedir none
</Directory>

<Directory /home/httpd/vhosts/monkeyclaus.org/httpsdocs>
RewriteEngine On
AllowOverride All
php_admin_value open_basedir none
</Directory>


and in the vhost_ssl.conf file I put this:

<Directory /home/httpd/vhosts/monkeyclaus.org/httpsdocs>
php_admin_value open_basedir none
</Directory>


I've stopped and restarted the server several times at this point.

I'm still getting the same error.

"Warning: main(): open_basedir restriction in effect. File(/home/httpd/
vhosts/monkeyclaus.org/httpdocs/media/audio/site_specific_files/
config.php) is not within the allowed path(s): (/home/httpd/vhosts/
monkeyclaus.org/httpsdocs:/tmp) in /home/httpd/vhosts/monkeyclaus.org/
httpsdocs/buy.php on line 1"


What do I have to do to turn off open_basedir and override Plesk?

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация