sticky bit in chmod

Hello

  The command "chmod 1777 filename" is a user sticky bit which allows only the user to have write access.       
  In the same way there are 1 to 7 sticky bit values in which the bits 1777, 3777, 5777 , 7777 allow only the owner to have all the permissions where as the even numbered sticky bits\(2777, 4777, 6777\) allow all\(owner, group, others\) to have write access.
  Can anyone please help me how the group and other sticky bits work correctly.....

Thanks
Lavanya

You should probably read some basic UNIX tutorials as well as the chmod manual page as you've got the understanding of the sticky bit a little skewed :wink:

The sticky bit is set by either chmod'ing 1xxx (where x are your other permission bits), or by using chmod +t

The first octet in chmod is used to set either Set UID, Set GID or Sticky bit, or a combination of some or all of these "special" permissions. Set UID allows an executable to be run with the privilages of the executables owner, Set GID allows an executable to run with the privilages of the group that owns the executable, and traditionally the sticky bit was used to keep an executables image in memory. Nowadays memory is cheap, and the sticky bit only really makes sense when set on a directory (such as /tmp) - this ensures that only the user who creates a file can delete that file.

This is a bit of a brief overview so make sure you read the chmod man page for full details.

Cheers
ZB