etkisi open_basedir kısıtlama.

4 Cevap php

Benim sitede bir avatar yükleme bu hatayı alıyorum. Ben daha önce kazanılmış hiç ettik ve bana bu hata alıyorum başlamak için hiçbir şey son zamanlarda değişti ...

Warning: is_writable() [function.is-writable]: 
open_basedir restriction in effect. 
File(/) is not within the allowed path(s):

4 Cevap

For me the problem was bad/missing config values for the Plesk server running the whole thing. I just followed the directions here: http://davidseah.com/blog/2007/04/separate-php-error-logs-for-multiple-domains-with-plesk/

You can configure PHP to have a separate error log file for each VirtualHost definition. The trick is knowing exactly how to set it up, because you can’t touch the configuration directly without breaking Plesk. Every domain name on your (dv) has its own directory in /var/www/vhosts. A typical directory has the following top level directories:

cgi-bin/
conf/
error_docs/
httpdocs/
httpsdocs/
...and so on

Sen aşağıdaki satırları ile etki dizinin conf / klasöründe bir Vhost.conf dosyası oluşturmak istersiniz:

php_value error_log /path/to/error_log
php_flag display_errors off
php_value error_reporting 6143
php_flag log_errors on

(I / tmp / phperrors.log kullanılır) gerçek kurulum maç için ilk değerini değiştirin. Eğer Vhost.conf dosyasını düzenleme yaptıktan sonra, birlikte konsoldan yapılandırmasını sınamak:

apachectl configtest
…or if you don’t have apachectl (as Plesk 8.6 doesn’t seem to)…

/etc/init.d/httpd configtest

Ve nihayet bu değişikliği yaptık Plesk söyle.

/usr/local/psa/admin/bin/websrvmng -a

Eğer atıfta konum yolu incorect ve çalışma alanınızdan directoryRoot withing değil. Mutlak bir yol Eğer şimdi muhtemelen göreli bir yol kullanarak erişmek, istediğiniz dosyayı bina deneyin ...

Eğer ispconfig3 ile sorun bu tür var ve böyle bir hata var ise

open_basedir restriction in effect. File(/var/www/clients/client7/web15) is not within the allowed path(s):.........

Bunu ispconfig3 ve sitenizin panelindeki suPHP'ye için (benim durumumda), sadece ayarlamak PHP çözmek için

Birine yardımcı olur umarım :)