Apache UID , GUID problem

Yolte

Verified User
Joined
Oct 10, 2006
Messages
36
Hello,

When we compile php as CLI mode, we have some problems about UID and GUID owners.

Folder permissions are being apache:apache

An example code;

PHP:
<?php

$folder_name = "folder";

if(file_exists($folder))
{
echo "folder already here!";
exit();//Stop
}

$make= mkdir($folder_name, 0700);

if($make)
{
echo "Folder created.";
}
else
{
echo "Folder not created!";
}

?>

This code creates folder but making UID,GUID as apache:apache.

Thereis no problem wiht suPHP, but we dont want to use suPHP.

Also this is making big problems on Joomla components.

Is there anyway to fix this problem?

Regards
 
Maybe we cant create folder with username:username permission.

But we can restore permissions after create folder?
 
If you don't want to run suPHP, then you should create a cronjob to run as root which will change the ownerships every X minutes. You choose how many minutes.

Jeff
 
Back
Top