I haven't seen this discussed here, and am wondering if anyone has had buggy stuff that they can't explain. This might be a solution.
There is an Apache setting called open_basedir which limits where on a hard drive a particular domain is allowed to look for files to run. NOT included in the default open_basedir is /usr/local/bin or /usr/bin which is where some of the prerequesite files are found.
When I install Vshare (I believe it is just before getting to the screen asking for the paths) I get a whole bunch of path errors that look like this:
Code:
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/bin/ffmpeg) is not within the allowed path(s): (/home/something:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/something/public_html/something.com/install/index.php on line 129
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/bin/ffmpeg) is not within the allowed path(s): (/home/something:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/something/public_html/something.com/install/index.php on line 131
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/bin/mplayer) is not within the allowed path(s): (/home/something:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/something/public_html/something.com/install/index.php on line 142
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/bin/mplayer) is not within the allowed path(s): (/home/something:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/something/public_html/something.com/install/index.php on line 144
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/bin/mencoder) is not within the allowed path(s): (/home/something:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/something/public_html/something.com/install/index.php on line 154
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/bin/mencoder) is not within the allowed path(s): (/home/something:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/something/public_html/something.com/install/index.php on line 156
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/bin/flvtool2) is not within the allowed path(s): (/home/something:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/something/public_html/something.com/install/index.php on line 167
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/bin/flvtool2) is not within the allowed path(s): (/home/something:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/something/public_html/something.com/install/index.php on line 169
It still goes to the right screen after all the errors, and the installation still seems to move forward fine. So I have learnd to ignore them. But I learned something recently that made them go away.
By changing the open_basedir setting of a domain (in the httpd.conf file) I get fewer error messages on installation.
So I go to /etc/conf/httpd and edit (pico) the httpd.conf file. I hit ctrl-w to find out Where is "whatever.com" and each domain has it's own set of listings in the httpd.conf.
I look for any line that says "open_basedir" and usually there's six or so, three each in if/then statements to cover php4 and php5.
Here's what it looks like:
Code:
<IfModule concurrent_php.c>
php4_admin_value open_basedir "/home/thewall:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/lib/p$
php5_admin_value open_basedir "/home/thewall:/usr/lib/php:/usr/local/lib/php:/tmp"
</IfModule>
<IfModule !concurrent_php.c>
<IfModule mod_php4.c>
php_admin_value open_basedir "/home/thewall:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/li$
</IfModule>
<IfModule mod_php5.c>
php_admin_value open_basedir "/home/thewall:/usr/lib/php:/usr/local/lib/php:/tmp"
</IfModule>
<IfModule sapi_apache2.c>
php_admin_value open_basedir "/home/thewall:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/li$
</IfModule>
At any line that lists an open_basedir path, I add the following to the beginning of each line, inside the first quote:
/usr/local/bin:/usr/bin:
so the very last line of the code above (and EVERY one that has an open_basedir path listed):
Code:
open_basedir "/home/thewall:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/li$
I change to
Code:
open_basedir "/usr/local/bin:/usr/bin:/home/thewall:/usr/lib/php:/usr/php4/lib/php:/usr/local/lib/php:/usr/local/php4/li$
That adds those to paths, /usr/local/bin and /usr/bin to the places where the particular domain is allowed to look for files.
I've noticed one thing on a site I just set up using this method from the beginning - emails that I got from another of my vshare sites that are usually blank except for the subject line, are now coming through with actual stuff on it. I just presumed some of them were blank messages and the subject said it all (like "your video is now uploaded.") heh I was too lazy to look at the template, just assumed it was blank. Maybe this is what was the problem.
Anyway I offer it out in case anyone wants to play with it or discuss it more.
Bookmarks