Jonathan Angliss wrote:
Jonathan,Hello Daniel, On Friday, April 08, 2005, Daniel Watts wrote...
I know this was brought up for an IIS user but I'm having the
problem with apache.
Sqm: 1.4.4
PHP 4.3.10
Apache 2.0
Error:
Error creating directory /home/virtual/domain.com/var/www/squirrelmail-data/5.
Could not create hashed directory structure!
Please contact your system administrator and report this error.
This is the directory structure:
drwxr-xr-x 3 root root 4096 Apr 7 14:17 squirrelmail
drwxr-xr-x 2 apache apache 4096 Apr 6 19:00 squirrelmail-attachments
drwxr-xr-x 2 apache apache 4096 Apr 7 17:13 squirrelmail-data
As you can see apache owns and has full priviliges to squirrelmail-data
What else should i be checking here?
apache's access to the parent directory(ies)? that apache is the
correct username?
Paul - thanks for your help.
The path is /home/virtual/domain.com/var/www/squirrelmail-data
Anything at www or below is root owned:
drwxr-xr-x 9 root root 4096 Apr 7 14:16 www
Everything above is apache owned [see above]
Does the full path have to be owned by apache all the way down? I don't
think I can do this...
I'm not an linux expert but I'm sure that that does not need to be the
case...otherwise that means apache would have to own the root directory
as well =)
No, just has to be able to get in there, that can be done without owning the directories above, chmod o+rx <directory> should do it... I didn't see you confirm that the apache service is running as apache, try changing the permissions so world has read/write permissions (777) on the directory, and see if that helps?
Also, are you sure that apache isn't running in a chroot environment? If you have specified the full path in the configuration, and apache is chroot'd, it will cause issues there.
Many thanks for the follow up. Indeed the permissions are correct and apache is "apache". I tried with 777 as well.
I located the problem.
For your interest this is the situation. Quite interesting: I'm using openbase_dir for security.
/home/virtual/domain1 ==symbolic==> site1/fst/ /home/virtual/site1/fst/var/www/squirrelmail-data so therefore: /home/virtual/domain1/var/www/squirrelmail-data is the same directory.
In squirrelmail vlogin config: $data_dir = /home/virtual/###VIRTUALDOMAIN###/var/www/squirrelmail-data
In that domains apache's directives: php_admin_value open_basedir /home/virtual/domain1/var/www/squirrelmail-data
The above doesn't work because of the symbolic link. I read that all symbolic links are resolved before checking against the the allowed baserdir's.
So I change apache to:
php_admin_value open_basedir /home/virtual/site1/fst/var/www/squirrelmail-data
However this won't work either.
It appears I actually have to change the vlogin config as well to show the actual path.
$site = exec(sitelookup(###VIRTUALDOMAIN###)) $data_dir = /home/virtual/site/fst/var/www/squirrelmail-data
This then works.
Quite annoying because the sitelookup function takes quite a while to complete each time (with lots of sites on the box).
Any suggestions about the above? It might be helpful to have some sort of wiki about the above as I expect this type of virtual domaining happens on other boxes as well. (i am personally using Ensim).
Thanks,
Daniel
------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click -- squirrelmail-users mailing list Posting Guidelines: http://squirrelmail.org/wiki/wiki.php?MailingListPostingGuidelines List Address: [email protected] List Archives: http://news.gmane.org/thread.php?group=gmane.mail.squirrelmail.user List Archives: http://sourceforge.net/mailarchive/forum.php?forum_id=2995 List Info: https://lists.sourceforge.net/lists/listinfo/squirrelmail-users
