Koozali.org: home of the SME Server
Obsolete Releases => SME Server 8.x => Topic started by: Bud on July 19, 2011, 02:42:31 PM
-
guys hope you can help
installed silverstripe in /opt/silverstripe
everything works except for document " upload "
cannot upload any documents
i made sure about folder rights etc.
when i look at the sme 8 server logs this is what it says
=====================
PHP Warning: Unknown: open_basedir restriction in effect. File(/tmp) is not within the allowed path(s): (/opt/silverstripe) in Unknown on line 0
pHP Warning: File upload error - unable to create a temporary file in Unknown on line 0
=====================
i seem to have a " open_basedir " problem
any help greatly appreciated :-)
-
you could start searching the forums, wiki and FAQ, for example..
your question has been asked maaaaany times :-)
-
you could start searching the forums, wiki and FAQ, for example..
Yes, but we can also point OP to the proper page directly. :-D
http://wiki.contribs.org/PHP#Open_basedir_restriction
-
indeed cactus but I answered from my phone while driving :-)
-
indeed cactus but I answered from my phone while driving :-)
Ooh naughty naughty, that is not allowed where I live ;-)
-
thanks for trying to help guys
this is what i did
#db accounts getprop ibayname PHPBaseDir
Nothing Happened
Then i issued
#db accounts setprop Primary PHPBaseDir /home/e-smith/files/ibays/Primary/html/:/opt/silverstripe
#signal-event ibay-modify silverstripe
Restarted SME Server
Tried to Upload a File. CANNOT UPLOAD FILE
Looked at Logs and same problem
===================================
Unknown: open_basedir restriction in effect. File(/tmp) is not within the allowed path(s): (/opt/silverstripe) in Unknown on line 0
File upload error - unable to create a temporary file in Unknown on line 0
===================================
Please Guys I need to get this working
Any Help Greatly Appreciated :)
-
bud, please re-read the error message.. the answer to your question is there :-)
hint: /tmp
-
Stefano thanks for your support
so are you saying i should issue the command like this:
#db accounts setprop Primary PHPBaseDir /home/e-smith/files/ibays/Primary/html/:/opt/silverstripe/tmp
#signal-event ibay-modify silverstripe/tmp
or what ??
sorry for the noob question. i understand that the " tmp " is the problem but i am not sure what command to issue
thanks again :D
-
please verify in settings of Silverstripe where is tmp set
I suppose it is not good to use the system /tmp
look if you have one tmp in /opt/silverstripe
if not you should create give adequate rights/ownership and find adequate silverstripe setings to make adjustments to point on it
-
larieu thanks for your help
you asked: please verify in settings of Silverstripe where is tmp set
i have checked and rechecked that the tmp foler is in /opt/silverstripe/tmp and has FULL Rights
what i am trying to understand is what my server log file says
what does this mean? what tmp file and where? the server tmp file, the silverstripe tmp file or what?
===================================
Unknown: open_basedir restriction in effect. File(/tmp) is not within the allowed path(s): (/opt/silverstripe) in Unknown on line 0
File upload error - unable to create a temporary file in Unknown on line 0
===================================
not sure what else to look for. :?
-
to rule out the /tmp path try doing like this
db accounts setprop Primary PHPBaseDir /home/e-smith/files/ibays/Primary/html/:/opt/silverstripe/:/opt/silverstripe/tmp/:/tmp
signal-event ibay-modify silverstripe
or to be more sure
signal-event post-upgrade; signal-event reboot
-
larieu thanks for your support
did what you recommended
same problem, cannot upload any files :(
-
you mentioned that you installed silverstripe in /opt/silverstripe.
How did you create the httpd.conf entries for the new app?
On my systems, apps installed in /opt (as opposed to apps installed in ibays) require me to make modifications to custom template fragments -- usually in /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf (instead of using db commands)
Take a look in /etc/e-smith/templates-custom/httpd/conf/httpd.conf - if you find a custom template fragment that looks like it's related to silverstripe, add a line inside the <Directory>....</Directory> segment that says:
php_admin_value open_basedir /tmp
-
mmccarn thanks so much for POINTING me in the RIGHT DIRECTION
woohoo i got it sorted. it's working
i will make a how to showing what i did including the Solution for Feng Office Document Uploads
thanks again for your help, much appreciated
will compile my findings and get back to the sme team asap
long live sme server :D