halfcountplus has asked for the wisdom of the Perl Monks concerning the following question:
The uid changes, but the gid does not. The point with the open() is that it must write files as "apache.apache". But because the gid does not change, they end up "apache.root". Then if I try system("chown ...") it is, predictably, denied permission.#!/usr/bin/perl -w use strict; $>=$<=48; # uid $)=$(=48; # gid setpgrp $$,48; open(FH,">/tmp/new.txt"); close(FH);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: set gid
by bv (Friar) on Sep 08, 2009 at 21:32 UTC | |
by halfcountplus (Hermit) on Sep 08, 2009 at 21:49 UTC |