I'm sending this question to the beginners perl list and the mod_perl
list as I'm not sure where it belongs.

In short: I'm trying to work out how to create a directory/file under
a specific user.

This is running on MP2 on Apache2 with suexec enabled. The vhost has:

        SuexecUserGroup myuser myuser

When trying to create the file I get a permissions error.

I'm trying to create folders and files in the public_html folder who's
perms are:
drwxr-x---  4 myuser  apache   512 Apr 29 11:31 public_html


The uid and gid for the folder:
public_html: uid = 1009, gid = 1003

the perl scripts (module that's a handler in fact) uid and gid:
Real: uid = 1004, gid = 1003 1003 1003 
Effective: uid = 1004, gid = 674124656 1003 1003 


The control Panel (Direct Admin) created the public_html folder under
group apache, so I assume all sites will be created with that folder
under group apache.

Other files/folders created via ftp/file upload are user and group myuser.

So I'd like to be able to create folders and files under user/group
myuser and not havae to create them under group apache. so that site's
don't have access to each others files.

So it seems my mod_perl modules are running under a different user
than the suexec setting in httpd.conf

Do I have to open up the permissions (ie make group apache writeable
for the folder) or is there some way I can temoprarily switch to uid
1009, make my files, and then switch back to 1004. Or would this be a
really bad (crossing the beams kind of bad).

TIA

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to