On Linux with coreutils 6.9, glibc 2.3.6, kernel 2.6.22.6, bash 3.2.35 I can do this:
#umask 0022 #mkdir testme #chmod 02700 testme #ls -ld testme drwx--S--- 2 root root 4096 Sep 5 16:21 testme #chmod 0700 testme #ls -ld testme drwx--S--- 2 root root 4096 Sep 5 16:21 testme I was under the impression 0700 was the octal code and would thus result in 0700 permissions, not leaving 2700 permissions. How can I use the octcal code to get 0700 permissions for a directory with 2700 permissions? I tried 00700 but that didn't matter. I know I can do 'chmod g-s testme' but since I can set the setgid flag with octal codes I would like to be able to unset the setgid flag with octal codes as well. I was able to achieve this in 2 steps with 'chmod 0 testme' followed by 'chmod 0700 testme'. Can it be done in 1 step using an octal number? JGH _______________________________________________ Bug-coreutils mailing list [email protected] http://lists.gnu.org/mailman/listinfo/bug-coreutils
