Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Installation/Configuration

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #11  
Old 20th September 2011, 07:28
emanation emanation is offline
Junior Member
 
Join Date: Sep 2011
Posts: 15
Thanks: 3
Thanked 0 Times in 0 Posts
Default

I have related issue.

Joomla site gives error for some functionality. It's related with trying to open/read/close folder tree with PHP functions.

Warning: opendir(/var/www/clients/client0/web4/web): failed to open dir: Permission denied in /var/www/clients/client0/web4/web/components/com_component/elements/directories.php on line 102
Warning: readdir(): supplied argument is not a valid Directory resource in /var/www/clients/client0/web4/web/components/com_component/elements/directories.php on line 103
Warning: closedir(): supplied argument is not a valid Directory resource in /var/www/clients/client0/web4/web/components/com_component/elements/directories.php on line 129

if I set web folder 0755 it works without errors and problems
it's sad that IPSConfig changes all web folders to 0710.
What can I do?

BTW:
Code:
[root@server www]# selinuxenabled
[root@server www]# echo $?
1
[root@server www]# id apache
uid=48(apache) gid=48(apache) groups=48(apache),5004(ispconfig),5005(client0)
Reply With Quote
Sponsored Links
  #12  
Old 20th September 2011, 10:29
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 36,804
Thanks: 840
Thanked 5,613 Times in 4,424 Posts
Default

Which php mode do you use and do you have suexec enabled. Also post the ouput of:

ls -la /var/www/clients/client0/web4/web

Quote:
it's sad that IPSConfig changes all web folders to 0710.
The correct permissions are 710. This works on all joomla sites on my server.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #13  
Old 20th September 2011, 12:49
emanation emanation is offline
Junior Member
 
Join Date: Sep 2011
Posts: 15
Thanks: 3
Thanked 0 Times in 0 Posts
Default

Code:
total 116
drwx--x--- 19 web4 client0  4096 Sep 19 06:18 .
drwxr-x--x  6 web4 client0  4096 Sep 14 01:49 ..
drwxr-xr-x 11 web4 client0  4096 Aug 25 11:32 administrator
drwxr-xr-x 40 web4 client0  4096 Sep 15 05:15 cache
drwxr-xr-x 25 web4 client0  4096 Dec 13  2010 components
-rw-r--r--  1 web4 client0  1949 Sep 14 11:20 configuration.php
drwxr-xr-x  2 web4 client0  4096 Sep 14 01:49 error
drwxr-xr-x 14 web4 client0  4096 Apr 25 06:54 files
-r--r--r--  1 web4 client0  3755 Mar 21  2011 .htaccess
drwxr-xr-x 10 web4 client0  4096 May 26  2010 images
drwxr-xr-x  8 web4 client0  4096 May 28  2010 includes
-rw-r--r--  1 web4 client0   588 May 28  2010 index2.php
-rw-r--r--  1 web4 client0  2049 May 28  2010 index.php
drwxr-xr-x  4 web4 client0  4096 May 28  2010 language
drwxr-xr-x 16 web4 client0  4096 Dec 10  2010 libraries
drwxr-xr-x  2 web4 client0  4096 Jul  6  2009 logs
drwxr-xr-x  6 web4 client0  4096 Dec 10  2010 media
drwxr-xr-x 26 web4 client0  4096 Dec 10  2010 modules
drwxr-xr-x 16 web4 client0  4096 Dec 10  2010 plugins
-rw-r--r--  1 web4 client0   388 Jan 14  2010 robots.txt
-rw-r--r--  1 web4 client0 11417 Jun 25  2010 sitemap.xml
drwxr-xr-x  2 web4 client0  4096 Sep 15 00:31 stats
drwxr-xr-x  4 web4 client0  4096 Feb 10  2010 templates
drwxr-xr-x  2 web4 client0 12288 Dec 13  2010 tmp
drwxr-xr-x  4 web4 client0  4096 May 28  2010 xmlrpc
I use PHP-mod (PHP as Apache module) for all sites and suexec checkbox is not selected for each website.

BTW, if I set permission for web folder 750 it works without warnings. And It's obvious because
Code:
[root@server www]# id apache
uid=48(apache) gid=48(apache) groups=48(apache),5004(ispconfig),5005(client0)
I think that read for group must be, mustn't it?

Last edited by emanation; 20th September 2011 at 13:12.
Reply With Quote
  #14  
Old 20th September 2011, 13:19
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 36,804
Thanks: 840
Thanked 5,613 Times in 4,424 Posts
Default

Your problem is that you use the wrong php mode. For a website that run a cms system which accesses the filesystem you should always use php-fastcgi plus suexec and not mod-php, so that the php scripts run under the user of the website and not the apache user. Using mod-php with joomla is also a security risk, as its easy for a hacker to infect all your sites when one joomla system is hacked and all sites run under the apache user instead of the website user.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
The Following User Says Thank You to till For This Useful Post:
emanation (20th September 2011)
  #15  
Old 20th September 2011, 15:23
emanation emanation is offline
Junior Member
 
Join Date: Sep 2011
Posts: 15
Thanks: 3
Thanked 0 Times in 0 Posts
Default

Here I see that suPHP could be used also.
http://www.howtoforge.com/forums/showthread.php?t=33817
I've tested it and agree that with suPHP my problem is gone.
What do you suggest with it?
Reply With Quote
  #16  
Old 20th September 2011, 15:37
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 36,804
Thanks: 840
Thanked 5,613 Times in 4,424 Posts
 
Default

You should use php-fcgi and suexec. Of course you can use suphp too as it does basically the same, but suphp is a lot slower when used for larger cms systems like joomla or typo3.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
The Following User Says Thank You to till For This Useful Post:
emanation (20th September 2011)
Reply

Bookmarks

Tags
ispconfig 3 permissions

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
web folder privileges are getting reset by ISPConfig wpwood3 Installation/Configuration 3 29th March 2010 23:59
ispconfig wordpress and directory/file permissions willebanks Installation/Configuration 4 9th March 2010 22:52
Web Users and permissions vaio1 General 5 31st July 2008 09:31
How to make visible folder on the web? lano Server Operation 2 7th October 2007 20:52


All times are GMT +2. The time now is 02:18.


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