12-05-2007
Thanks for posting the solution you found. But I would like to point out that the directories have the SGID bit, not the sticky bit. Both bits are often used on directories and have different effects. I explain this in my article
Unix File Permissions.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi,
I want to know how the file permision should change to 755 automatically once the file is created. At the moment I do it explicitely by changing the permission mode to 755 using chmod command.
The default permission for a new file in my system is 644 (-rw-r--r--).
Thanks
Saumya (6 Replies)
Discussion started by: sommyp
6 Replies
2. UNIX for Dummies Questions & Answers
All,
I am having a directory as
drwxrwsr-x 3 intermec intermec 10240 Jan 8 09:07 intermec
inside the directory . the files are like
cd
-rw-r----- 1 intrmc01 intermec 5226 Dec 2 15:03 AST07356.txt
-rw-r----- 1 intrmc01 intermec 5025 Dec 2 12:51... (4 Replies)
Discussion started by: arunkumar_mca
4 Replies
3. SuSE
Hi All,
I used to have my suse linux(VM) server in graphic mode but not anymore since morning. I cant rolback since i loose somuch work. Any idea how to it back to normal. Thanks (6 Replies)
Discussion started by: s_linux
6 Replies
4. UNIX for Dummies Questions & Answers
Hello,
I have a program which at run time creates a shell script and tries to redirect the output of the same to another file. both of the files are created at run time with different names.
The problem is: the file it is redirecting to is being created as:
-rw-r--r-- 1 root tech 69... (1 Reply)
Discussion started by: chandan.sharma
1 Replies
5. UNIX and Linux Applications
i think it is the same in both... Iam i right? (1 Reply)
Discussion started by: sumaiya
1 Replies
6. UNIX for Advanced & Expert Users
Hi All,
Can please let me know what is the difference between the single line mode and multi line mode in regular expresions?
Thanks,
Chidhambaram B (3 Replies)
Discussion started by: chidhu.anu
3 Replies
7. UNIX for Dummies Questions & Answers
I hava a windows NTFS partition on fedora15. The partitions auto-mounts to /media/Data ever starting of KDE.
/dev/sda5 on /media/Data type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096)
But I cant change the file permission in this... (1 Reply)
Discussion started by: vistastar
1 Replies
8. Solaris
:confused:
when i tried to look the status of DNS-client, it is in maintenance mode.....
Please tell me how to bring it back to online mode...PLEASE TELL ME STEP BY STEP.... PLEASE...
:wall: (2 Replies)
Discussion started by: vamshigvk475
2 Replies
9. UNIX for Advanced & Expert Users
Hi,
How to change mode "drwxrwsr-x+" in directory.
I'm able to set drwxrwsr-x but "+" is difficult to set.
~ $ las -las | grep done1
4 drwxrwsr-x+ 3 root sfuser 4096 Nov 26 16:39 done1
~ $ getfacl done1
# file: done1
# owner: root
# group: sfuser
# flags: -s-
user::rwx... (4 Replies)
Discussion started by: justbow
4 Replies
10. HP-UX
is there a way for my C++ application to find out which mode the hpux OS is running in?
standard mode or trusted mode. (3 Replies)
Discussion started by: einsteinBrain
3 Replies
CHMOD(1) General Commands Manual CHMOD(1)
NAME
chmod - change mode
SYNOPSIS
chmod mode file ...
DESCRIPTION
The mode of each named file is changed according to mode, which may be absolute or symbolic. An absolute mode is an octal number con-
structed from the OR of the following modes:
4000 set user ID on execution
2000 set group ID on execution
1000 sticky bit, see chmod(2)
0400 read by owner
0200 write by owner
0100 execute (search in directory) by owner
0070 read, write, execute (search) by group
0007 read, write, execute (search) by others
A symbolic mode has the form:
[who] op permission [op permission] ...
The who part is a combination of the letters u (for user's permissions), g (group) and o (other). The letter a stands for ugo. If who is
omitted, the default is a but the setting of the file creation mask (see umask(2)) is taken into account.
Op can be + to add permission to the file's mode, - to take away permission and = to assign permission absolutely (all other bits will be
reset).
Permission is any combination of the letters r (read), w (write), x (execute), s (set owner or group id) and t (save text - sticky). Let-
ters u, g or o indicate that permission is to be taken from the current mode. Omitting permission is only useful with = to take away all
permissions.
The first example denies write permission to others, the second makes a file executable:
chmod o-w file
chmod +x file
Multiple symbolic modes separated by commas may be given. Operations are performed in the order specified. The letter s is only useful
with u or g.
Only the owner of a file (or the super-user) may change its mode.
SEE ALSO
ls(1), chmod(2), chown (1), stat(2), umask(2)
CHMOD(1)