HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Installation/Configuration (http://www.howtoforge.com/forums/forumdisplay.php?f=16)
-   -   suPHP, Joomla! 1.5, file & diretory permissions (http://www.howtoforge.com/forums/showthread.php?t=20062)

pjdevries 2nd February 2008 14:37

suPHP, Joomla! 1.5, file & diretory permissions
 
Joomla! 1.5 is officially released, so I decide to use it for my next website. Unfortunately I ran into a file & directory permission problem I also ran into using Joomla! 1.0.13. The problem has to do with suPHP and the default file & directory creation permissions of Joomla! and it first appeared when I tried to get WYSIWYG editors to work. For Joomla! 1.x the problem could be solved by changing the default creation permissions in the "Global Configration - Server" section of the Joomla! administrator back-end (thanks to Hans for the tip). Changing the default directory permissions to 0775 instead of the default 755 (and applying them to existing directories) solved the problem.

In Joomla! 1.5 that administrator section doesn't exist anymore and so I'm stuck once again. Is there an alternative Apache and/or ISPConfig way of solving this problem? I don't know if Joomla! explicitly sets permissions or uses the system default umask. If it does use the system umask however, I would like to know how to change that for my Apache + suPHP setup. I would also like to know if it's possible to have a different umask for file and directory creation.

Hans 2nd February 2008 23:53

I think, on the moment there are 2 possibilities:

1) If you use php5 as a module, you can make use of the new FTP-layer function within Joomla 1.5.
When you add the FTP-account of your web in there, problems with permissions should be solved.
This is the case on a default ISPConfig server (without suPHP).

2) You can use Joomla 1.5 with php5-cgi+suPHP but then you have to make the right permissions manually. This is the case if you use ISPConfig with suPHP enabled.

By the way, it is possible to use php5 as a module as well on an ISPConfig server with php5-cgi+suPHP, so you can make use of the new FTP-layer feature in Joomla 1.5. (If you prefer this).
For this do the following:

On the Linux shell as root:

a2enmod php5

/etc/init.d/apache2 force-reload

Within the Apache directives field of the site within ISPConfig:

suPHP_Engine off
RemoveHandler .php
php_admin_flag engine on

pjdevries 7th February 2008 10:38

Thanks for the response Hans. For the time being, I don't see any other solution either. Disabling suPHP is not an option though, because it's exactly for sites like these, using a CSM like Joomla! or other PHP based sites, that I'm using suPHP.

Anyone else with clever alternatives?

pjdevries 21st February 2008 09:41

As could have been expected, the problem has nothing to do with Joomla! itself, but with suPHP. Changing the default umask of 0077 in /etc/suphp/suphp.conf to 0022 solved the problem.

Hans 29th February 2008 16:44

During an ISPConfig update (version 2.2.20 and up), the /etc/suphp.conf will be overwritten.

If the umask 0022 setting within /etc/suphp is important to you, you must change the umask setting from 0077 into 0022 manually after every ISPConfig update!

pjdevries 29th February 2008 16:53

Thanks you very much Hans. I'm going to update ISPConfig to the latest version this weekend, so your tip comes just in time.

I think it's rather careless though, that an update of ISPConfig overwrites these kind of system files, without checking, warning and/or asking for permission to do so. Without this helpful tip, I wouldn't have known this and woul probably pull out my hair out of pure agony and frustration, as soon as the permission problems started to manifest themselves once again.

brunus 13th March 2008 13:35

Hi Hans,
I've been encountering this same issue. I'm quite surprised that when you install Joomla 1.5 in ISPConfig everything is 777. Isn't it a security issue?

paolo

Hans 13th March 2008 14:18

@brunus,
Do you use php5-cgi+suPHP or php5mod on your ISPConfig server?

bluethunder82 15th June 2008 23:01

Hi Guys,
I'm experiencing the same problem with file/directory permissions with a Joomla 1.5 install.

I installed Joomla1.5 successful and I am able to log into the system. The problem starts when I try to add a template. I get the JFTP::write message. I have traced this to being a permission problem. Therefore I am not sure if I need to move to suphp or if I can stay with the default.

I am able to use the media manager and upload pictures and remove pictures, create articles, etc. The only thing I cannot seem to do at this time is upload a template form a zip file.

The tutorial posted for Joomla/ISPConfig is only for the first version. Any thoughts would be appreciated.

Hans 15th June 2008 23:27

Please have a look here for the solution: http://www.howtoforge.com/forums/showthread.php?t=23436

Hope that the new upcoming version of ISPConfig uses the right settings for suphp as described by Vogelor.


All times are GMT +2. The time now is 19:24.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.