[BlueOnyx:03244] Re: php error

Stephanie Sullivan ses at aviaweb.com
Tue Jan 5 11:48:20 -05 2010


<previous responses removed for clarity>
> The question I am asking about now is this:
> 
> I have a site (not multiple sites, in this situation, just one) that
> runs
> Joomla.  A helper script that Joomla executes resizes article images
> and
> puts them into a separate directory for viewing by the site's users.
> On
> Blue Quartz, the Joomla script operated under apache.siteX ownership.
> Under
> Blue Onyx, the Joomla script runs as apache.apache.
> 
> If I turn on SafeMode or SafeModeGid, the script will not produce
> resized
> images, instead it produces an error about SafeMode.
> 
> What I am asking is whether or not I can get this site to be able to
> enable
> SafeMode, or whether or not it is outside of the scope of Blue Onyx
> for
> Apache to peacefully co-exist unless SafeMode is disabled.
> 
> So, if the site is owned by user siteX, group siteX, and scripts
> running as
> Apache are creating files/directories owned by user apache, group
> apache,
> how does SafeMode need to be configured to operate peacefully?

Darrell,

When I do a install of wordpress on BQ or BX using the web based setup I get
files owned by apache.apache. This is because the preserve the ownership in
the archive when it's expanded. OK.

So, I go and chgrp -R the files to sitexx so they can work in safe mode gid.
Sounds good so far, but wait, there's more.

By default the directories in a BQ/BX site folder have the chmod g+S bit
set. This forces files within those directories to have the same group as
the directory UNLESS the group ownership is explicitly set, like extracting
a tar archive. Like when wordpress (or joomla) do their initial setup.

Where are we left? The solution may be to chgrp -R your affected files. And
chmod g+S all the directories in the Joomla install. This should keep the
proper group ownership for uploaded files in php safe mode. It should also
(if applied to the scripts for resizing you mention) enable them to operate.

To be clear, I've worked with wordpress and drupal sites with safe mode on.
This approach worked for each. I don't have direct experience with joomla.

Hope this helps.

	-Stephanie




More information about the Blueonyx mailing list