'The PHP temporary directory is not set' - why am I seeing this message?

3,107 views
Skip to first unread message

David Roth

unread,
Feb 11, 2012, 11:45:05 PM2/11/12
to joomla-dev-general
I installed Joomla 2.5.1. I saw this message on 1.7 too:

"The PHP temporary directory is not set
The PHP temporary directory is the directory that PHP uses to store an
uploaded file before Joomla! can access this file. Whilst the
directory not being set isn't always a problem, if you are having
issues with manifest files not being detected or uploaded files not
being detected, setting this in your php.ini file might fix the
issue."

I'm root on my CentOS server, everything in the Joomla directory that
this installation of 2.5.1 resides has it's chown and chgrp to apache.
The tmp directory is 0755, there are two files in that directory with
a permission of 644. Everything belongs to apache.

I'm not having any issues that I know of, but it's hard to show off
your new Joomla installation and see a warning. ;-)

I looked in the php.ini and did a grep for tmp and see this:
;upload_tmp_dir =

Should this be set to something? Does changing this to upload_tmp_dir
=/tmp the right thing to do? Would the rest of PHP use this then?
Should it just be set in the .htaccess file?

Thanks!

David Roth

Russ Winter

unread,
Feb 12, 2012, 2:44:03 AM2/12/12
to joomla-de...@googlegroups.com
You need to talk to your host about setting that correctly. And I would suggest getting them to set the server up better also so you have your own user and group against your folders and files.  The Apache owner and group setting is why you are not having any immediate issues, but is not correctly configured for a good server.

To not display PHP messages, set the Joomla! Eror Reporting setting to "none" in the global configuration, if that doesn't work then contact your host to, again, correctly configure PHP to not display messages and warnings on production sites.

If you had searched the forums, ( http://forum.joomla.org ) you would have found this question has been answered many many times, instead of asking on a "Developer" mail-list which is not intended for general support.










David Roth

--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To post to this group, send an email to joomla-de...@googlegroups.com.
To unsubscribe from this group, send email to joomla-dev-gene...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/joomla-dev-general?hl=en-GB.


Sam Moffatt

unread,
Feb 12, 2012, 3:32:58 AM2/12/12
to joomla-de...@googlegroups.com
@Russ: The particular message he's describing is in the warnings tab
of the installer and isn't a PHP error message.

It's there as an indicator warning in case something doesn't work more
than anything. If you aren't seeing the symptoms then there isn't
something to worry about. It is there as a diagnostic for when
something is going wrong. In some situations the temp directory not
being set can lead to the symptoms described and it can be frustrating
to work out. Hence why I added a check for that particular situation
so next time I ran into something exhibiting those behaviours I had a
prompt to get the situation fixed. Given the behaviour of PHP it is
hard to detect when these situations actually cause an issue and when
they don't, hence a warnings tab.

If you're worried about the warning, setting the temp directory should
remove the warning. But if you're not having any issues I'd personally
not worry (my local install has a similar warning).

Cheers,

Sam Moffatt
http://pasamio.id.au

Russ Winter

unread,
Feb 12, 2012, 3:35:40 AM2/12/12
to joomla-de...@googlegroups.com
stand-corrected, my apologies...

(hope life is good over there Sam)

David Roth

unread,
Feb 12, 2012, 6:11:17 PM2/12/12
to joomla-de...@googlegroups.com
Hi Sam.

Thanks for the reply and explanation.

When I click on "External Manager: Warnings" my expectation is to see
messages of what is wrong and what needs my action to take care of
them. "The PHP temporary directory is not set" doesn't sound like it
falls into that category of warnings. I don't know what the alert
looks like for a serious problem from "External Manager: Warnings",
but since I don't have any, it makes "The PHP temporary directory is
not set" appear much more serious than it is, since I wasn't having a
problem at all.

I have a suggestion that may help make this more clear. Maybe if
messages like "The PHP temporary directory is not set" were added
under a heading of "External Manager: Trouble Shooting", its meaning
would be there for reference if this Joomla installation is having a
problem. It may cut down on support questions or concerns from admin
users.

Best regards,

David Roth

David Roth

unread,
Feb 12, 2012, 11:47:55 PM2/12/12
to joomla-de...@googlegroups.com
Correction: /External/Extension/
Reply all
Reply to author
Forward
0 new messages