chmod g+ Equivalent
hancock.robert at gmail.com
Tue Aug 14 14:24:11 CEST 2007
On Aug 13, 8:06 pm, Steve Holden <st... at holdenweb.com> wrote:
> milan_sanremo wrote:
> > I've read the documentation on os.chmod() and can implement all the
> > standard commands, but what is the syntax for the equivalent of chmod g
> > + to set the group id?
> I assume when you say "to set the group id" you actually mean "to assert
> the setgid bit"? I further presume that when you say "chmod g+" you
> actually mean "chmod g+s".
The g+s was an omission on my part. I can see how it would confuse
I'm not sure if I mean "to assert the setgid bit". My SUN docs refer
to it being 'on'.
> You can't have read the documentation very thoroughly. It says right at
> the top:
I did see this in the documentation:
Change the mode of path to the numeric mode. mode may take one of the
following values (as defined in the stat module) or bitwise or-ed
combinations of them:
Which refers to:
After which it was still unclear.
My question is in the command os.chmod(myDirectory, ?) what is the
value for ? to turn on the setgid bit.
Contrary to your presumption, I did read the documentation
thoroughly. It is inability to understand the concept which prompted
me to post the question here.
> Of course, your process needs to have root privilege in order to be able
> to do that.
> Steve Holden +1 571 484 6266 +1 800 494 3119
> Holden Web LLC/Ltd http://www.holdenweb.com
> Skype: holdenweb http://del.icio.us/steve.holden
> --------------- Asciimercial ------------------
> Get on the web: Blog, lens and tag the Internet
> Many services currently offer free registration
> ----------- Thank You for Reading -------------
More information about the Python-list