apache user/group won't create directory

Discussion in 'Installation/Configuration' started by weedguy, Aug 4, 2005.

  1. weedguy

    weedguy New Member

    I installed ISPConfig on a Fedora Core 4 box. I followed all of the Fedora Core 4 installation instructions except that I installed all of the available packages. Everything is working great! However, I cannot get my PHP scripts to create a directory so that I can upload an image.

    My PHP script attempts to make a recursive directory based on the date. First, the script creates a directory based on the year. This works correctly. The directory listing for the created directory shows:

    [root@ddnsserver1 servadmin]# ls -Fl /home/www/web11/web/website/media/image
    total 76
    drwxrwxrwx 2 apache apache 4096 Aug 4 07:16 2005/

    Next, the PHP script attempts to create a directory that is based on the name of the month inside of the directory that is created based on the year. Even though the permission bits show it has write set, I cannot get the script to create the directory.

    These scripts have worked correctly on many different services. Furthermore, I have checked, using the Fedora Core 4 security panel, to make sure that SELinux and the firewall are off. The only firewall is the firewall that was installed with ISPConfig.

    Can anyone offer some advice/help?
     
  2. falko

    falko Super Moderator ISPConfig Developer

    Do you get any errors from your script?
    Maybe you can change your script so that it shows what it's doing and output the values of some variables?
     
  3. weedguy

    weedguy New Member

    The error log says...

    mkdir() [<a href='function.mkdir'>function.mkdir</a>]: SAFE MODE Restriction in effect. The script whose uid is 10011 is not allowed to access /home/www/web11/web/website/media/image/2005 owned by uid 48 in /home/www/web11/web/phplib/class/media.php on line 182, referer: http://womcaterers.hopto.org/website/webpage/admin_add_image.php

    I checked the /etc/php.ini config file and it says:

    safe_mode = Off

    My limited understanding says that if safe_mode = Off then I should not be having a SAFE MODE issue. Is this the case?
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Have you checked the "PHP safemode" checkbox in the options for this site in the controlpanel?
     
  5. weedguy

    weedguy New Member

    Problem solved!

    That was the problem. I had PHP Safe Mode checked in the control panel. I unchecked it and the scripts worked perfectly. Thanks to all.
     
  6. matehortua

    matehortua New Member

    sorry but what CONTROL PANEL???
    where is the control panel...

    i have the same error




    I have ISPconfig 2.0.9 on a suse 9.2 installed with the Falko guide
     
  7. falko

    falko Super Moderator ISPConfig Developer

    ISPConfig! ISPConfig is the control panel. :D
     

Share This Page